CN111858395B - Data management method and device - Google Patents

Data management method and device Download PDF

Info

Publication number
CN111858395B
CN111858395B CN202010616451.3A CN202010616451A CN111858395B CN 111858395 B CN111858395 B CN 111858395B CN 202010616451 A CN202010616451 A CN 202010616451A CN 111858395 B CN111858395 B CN 111858395B
Authority
CN
China
Prior art keywords
application program
type
page address
data
mapping table
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010616451.3A
Other languages
Chinese (zh)
Other versions
CN111858395A (en
Inventor
陈国栋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN202010616451.3A priority Critical patent/CN111858395B/en
Publication of CN111858395A publication Critical patent/CN111858395A/en
Application granted granted Critical
Publication of CN111858395B publication Critical patent/CN111858395B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/10Address translation
    • G06F12/1009Address translation using page tables, e.g. page table structures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/06Addressing a physical block of locations, e.g. base addressing, module addressing, memory dedication
    • G06F12/0615Address space extension
    • G06F12/0623Address space extension for memory modules

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

The application discloses a data management method and a device, which belong to the technical field of communication, wherein the method comprises the following steps: determining the type of the application program based on preset parameters; if the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; and adding the corresponding relation between the logical page address and the physical page address of the application program data into a block mapping table under the condition that the type is the second type. According to the data management method disclosed by the application, the response speed of the read-write request of the first type application program can be ensured without expanding the memory space, and the smoothness of the first type application program in use is ensured. The memory space is not required to be enlarged, so that the cost and the design difficulty of the electronic equipment are not increased additionally.

Description

Data management method and device
Technical Field
The embodiment of the invention relates to the technical field of communication, in particular to a data management method and device.
Background
With the rapid development of electronic device technology, the variety of applications that can be installed in electronic devices is increasing. A user may chat in voice, watch videos, take images, navigate route planning, etc. through an electronic device. The data generated in the installation package or the running process of each application program installed in the electronic device occupies the memory of the electronic device, so as the number of application programs installed on the electronic device increases, the memory space of the electronic device also decreases. The most intuitive embodiment of the insufficient memory space is that the application program is seriously jammed in the running process, and the use experience of a user is seriously affected.
At present, in order to solve the problem of insufficient memory space of electronic equipment, the memory space of the electronic equipment is mainly enlarged, and the method not only increases the cost of the electronic equipment, but also improves the design difficulty of the electronic equipment.
Disclosure of Invention
The embodiment of the application aims to provide a data management method which can solve the problems of high cost and high design difficulty in expanding the memory space of electronic equipment in the prior art.
In order to solve the technical problems, the invention is realized as follows:
in a first aspect, an embodiment of the present application provides a data management method, where the method includes: determining the type of the application program based on preset parameters, wherein the preset parameters comprise at least one of the following: the user presets information, the use frequency of the application program and the user characteristic analysis result; if the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; and adding the corresponding relation between the logical page address and the physical page address of the application program data into a block mapping table under the condition that the type is the second type.
In a second aspect, an embodiment of the present application provides a data management apparatus, where the apparatus includes: the first determining module is used for determining the type of the application program based on preset parameters, wherein the preset parameters comprise at least one of the following: the user presets information, the use frequency of the application program and the user characteristic analysis result; the first adding module is used for adding the corresponding relation between the logical page address and the physical page address of the application program data into the page mapping table under the condition that the type is a first type; and the second adding module is used for adding the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table under the condition that the type is the second type.
In a third aspect, embodiments of the present application provide an electronic device comprising a processor, a memory and a program or instruction stored on the memory and executable on the processor, the program or instruction implementing the steps of the method according to the first aspect when executed by the processor.
In a fourth aspect, embodiments of the present application provide a readable storage medium having stored thereon a program or instructions which when executed by a processor implement the steps of the method according to the first aspect.
In a fifth aspect, embodiments of the present application provide a chip, where the chip includes a processor and a communication interface, where the communication interface is coupled to the processor, and where the processor is configured to execute a program or instructions to implement a method according to the first aspect.
In the embodiment of the application, the type of the application program is determined based on preset parameters; under the condition that the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; and in the case that the type is the second type, adding the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table. According to the data management method provided by the embodiment of the application program, the types of the application programs installed in the electronic equipment can be divided, the first type of application program data is stored in a page mapping mode, and the second type of application program data is stored in a conventional block mapping mode. The storage mode of the block mapping can save occupied memory space, the storage mode of the page mapping can improve response speed of read-write requests of the application programs, in the embodiment of the application, the data of each installed application program is stored by combining the page mapping mode and the block mapping mode, the response speed of the read-write requests of the first type application program can be ensured without expanding the memory space, and smoothness of the first type application program in use is ensured. The memory space is not required to be enlarged, so that the cost and the design difficulty of the electronic equipment are not increased additionally.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the description of the embodiments of the present invention will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart showing the steps of a data management method according to an embodiment of the present application;
FIG. 2 is a flow chart showing the steps of a method for determining an application type according to an embodiment of the present application;
fig. 3 is a block diagram showing a structure of a data management apparatus according to an embodiment of the present application;
FIG. 4 is a block diagram illustrating the structure of an electronic device according to an embodiment of the present application;
fig. 5 is a schematic diagram showing a hardware structure of an electronic device according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all, of the embodiments of the present application. All other embodiments, which can be made by one of ordinary skill in the art based on the embodiments herein without making any inventive effort, are intended to be within the scope of the present application.
The terms first, second and the like in the description and in the claims, are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged, as appropriate, such that embodiments of the present application may be implemented in sequences other than those illustrated or described herein, and that the objects identified by "first," "second," etc. are generally of a type and not limited to the number of objects, e.g., the first object may be one or more. Furthermore, in the description and claims, "and/or" means at least one of the connected objects, and the character "/", generally means that the associated object is an "or" relationship.
The data management method provided by the embodiment of the application is described in detail below through specific embodiments and application scenes thereof with reference to the accompanying drawings.
Referring to fig. 1, a flowchart of steps of a data management method according to an embodiment of the present application is shown.
The data management method of the embodiment of the application comprises the following steps:
step 101: and determining the type of the application program based on the preset parameters.
Wherein the preset parameters include at least one of the following: the method comprises the steps of presetting information by a user, using frequency of an application program and analyzing results of characteristics of the user.
The data management method shown in the embodiment of the application manages data of each application program installed in the electronic device. In the embodiment of the present application, the management of data of one application is taken as an example, and in a specific implementation process, the data management device refers to a data management flow shown in the embodiment of the present application to manage data of each application installed in the electronic device.
The types to which the application belongs may include: a first type and a second type. The first type may be an application program with a use frequency higher than a preset frequency in a preset time period, that is, an application program commonly used by a user, and the second type may be an application program with a use frequency lower than or equal to the preset frequency in the preset time period, that is, an application program not commonly used by the user.
Step 102: and adding the corresponding relation between the logical page address and the physical page address of the application program data into the page mapping table under the condition that the type is the first type.
And adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table, namely managing the application program data of the first type in a page mapping mode. The application program data is managed in a page mapping mode, so that the address conversion efficiency is higher, and the address allocation is more flexible.
For the second type of application, the data is managed in a block mapping manner.
Step 103: and in the case that the type is the second type, adding the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table.
And adding the corresponding relation between the logical page address and the physical page address of the application program data into a block mapping table, namely managing the data by adopting a block mapping mode. The block mapping mode is a conventional data address mapping mode in the prior art. The data of the second type application program is managed in a block mapping mode, so that occupation of memory space of the storage device can be reduced, and the response speed of the application program for reading and writing requests can be sacrificed because the second type application program is an application program which is not commonly used by users.
At present, the address mapping mode of the flash memory storage device in the electronic device is relatively fixed, the address conversion time cost is high, and further, the read-write request response delay of the application program is caused, so that a user feels the phenomenon of blocking the application program. In order to solve the problem, in the method, when the data of the first type application program installed in the electronic equipment is managed, a page mapping mode with higher address conversion efficiency and more flexible address allocation is adopted, and because the memory space for storing the address conversion page table is limited, the block mapping mode which saves more memory space is adopted for the data of the second type application program installed in the electronic equipment, so that the problem of blocking in the running process of the first type application program can be prevented while the limited memory space is fully utilized.
In addition, in the use process of the electronic equipment, the use habit changing condition of the user on each application program can be continuously learned, the type of each application program in the electronic equipment is adaptively adjusted based on the learned use habit changing condition, and correspondingly, when the type of the application program is changed, the management mode of the data of the application program is adaptively changed. For example: when an application program is changed from a first type to a second type, the data management mode of the application program is changed from page mapping to block mapping; for another example: when an application program changes from the second type to the first type, the data management mode of the application program changes from block mapping to page mapping. The technical means of self-adaptively adjusting the management mode of the application program data according to the use habit change of the user on each application program can effectively prevent the response delay problem of the application program commonly used by the user due to the address mapping overhead while fully utilizing the limited memory space of the memory.
According to the data management method provided by the embodiment of the application, the type of the application program is determined based on the preset parameters; under the condition that the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; and in the case that the type is the second type, adding the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table. According to the data management method provided by the embodiment of the application program, the types of the application programs installed in the electronic equipment can be divided, the data of the first type of the application programs are stored in a page mapping mode, and the data of the other types of the application programs are stored in a conventional block mapping mode. The storage mode of the block mapping can save occupied memory space, the storage mode of the page mapping can improve response speed of read-write requests of the application programs, in the embodiment of the application, the data of each installed application program is stored by combining the page mapping mode and the block mapping mode, the response speed of the read-write requests of the first type application program can be ensured without expanding the memory space, and smoothness of the first type application program in use is ensured. The memory space is not required to be enlarged, so that the cost and the design difficulty of the electronic equipment are not increased additionally.
In an alternative embodiment, when determining the type of the application program based on the preset parameters, the method may be implemented by an application program type determining method shown in fig. 2, and specifically includes the following steps:
step 201: and acquiring user preset information input by a user in advance.
Wherein the user preset information includes at least one of: sex information, preference information.
The user can show different tendencies in daily habits, the characteristics of the user can be defined when the user uses the electronic equipment for the first time, and the application programs which are used more frequently by the user can be primarily judged according to the characteristics of the user. The user preset information may be used as a dimension to determine the user's trait. In the specific implementation process, a guiding interface can be displayed when the user uses the electronic equipment for the first time, and the user is prompted to input gender information, hobby information and the like so as to acquire preset information of the user.
User preferences may include, but are not limited to: games, chasing plays, chats, and delicacies. In inputting the preference information, the user may input one or more preference information. For example, if the user input preference information is a game, the user may be determined to be "game control" preliminarily, and if the user input preference information is a chasing, the user may be determined to be "video control" preliminarily.
Step 202: a frequency of use ranking of the applications is determined based on historical operational data for each of the installed applications.
The frequency of use of each application installed in the electronic device is ranked periodically during the use of the electronic device by the user. The higher the frequency of use ranking of an application, the more often the user will use the application. The usage frequency ranking of each application is also used as a dimension that characterizes the user's features.
Step 203: and analyzing the managed preset type data to obtain a user characteristic analysis result.
The preset type data is data in a low risk application program, for example: the short message is analyzed to obtain information such as user hobbies, living habits and the like by means of keyword extraction, matching and the like on the preset type data, and the information is used as a user characteristic analysis result.
Step 204: and determining the type of the application program according to the user preset information, the use frequency ranking and the user characteristic analysis result.
After obtaining the information of three dimensions characterizing the characteristics of the user through steps 201 to 204, determining the type of each application program installed in the electronic device based on the information of the three dimensions.
For example: the information in three dimensions may be weighted to derive a ranking for each application installed in the electronic device. And setting a threshold T, determining the application programs ranked in the top T% as the first type application programs, and determining the rest application programs as the second type application programs.
It should be noted that, steps 201 to 203 are not limited to the above-described sequence, and the three steps may be executed in parallel without any restriction on the sequence of execution among the three steps. In the specific implementation process, the method is not limited to determining the type of the application program through three pieces of three-dimensional information, and the type of each application program installed in the electronic device can be determined based on any one or two pieces of the three pieces of dimensional information.
The manner in which the type of application is optionally determined as shown in steps 201-204 is more accurate and reliable.
In an alternative embodiment, after adding the correspondence between the logical page address and the physical page address of the application program data to the page mapping table, the following procedure is further included:
under the condition that a data request of an application program is received, determining a target logical page address corresponding to the data request; and searching the target physical page address corresponding to each target logical page address according to the mapping relation between each logical page address and the physical page address managed in the page mapping table.
Under the condition that a data request of the first type application program is received, the page mapping table is used for directly positioning a physical storage address corresponding to the request, and accessing the address, so that the response time of the data request can be shortened, and smooth operation of the application program is ensured.
In an alternative embodiment, after the correspondence between the logical page address and the physical page address of the application program data is added to the page mapping table, the following application program data management flow may be further included:
firstly, updating the type of an application program according to a preset parameter corresponding to the application program;
the update of the type of the application program can be performed at intervals of a preset time, or can be performed when the electronic device is in an idle state.
When the type of the application program is updated according to the preset parameters corresponding to the application program, the type of each application program installed in the electronic equipment is redetermined based on the mode shown in fig. 2, and the redetermined type is compared with the type recorded in the system for each application program, and if the comparison result is that the type is unchanged, the type of the application program is not changed; if the comparison result shows that the type is changed, the type recorded in the system is replaced by the redetermined type so as to complete the updating of the type to which the application program belongs.
And secondly, when the type of the application program is changed from the first type to the second type, the corresponding relation between the logical page address and the physical page address of the application program data is transferred from the page mapping table to the block mapping table.
For example: if the application rank is changed from the top T% to the bottom (100-T)%, the type of the application is changed from the first type to the second type, and the management mode of the application data from page mapping is changed to the management mode of block mapping.
The physical addresses of data in the block mapping mode should be continuous, so if the data of a certain application program is converted from page mapping to block mapping, the data of the original page mapping needs to be migrated, the data are stored in a storage unit with continuous addresses in a concentrated way, and after the data are migrated, a block mapping table is built for the migrated data again.
The method can update the application program type optionally, and can effectively utilize the memory space of the memory of the electronic equipment by adopting the technical means of adaptively adjusting the application program data management mode according to the type.
In an alternative embodiment, after adding the correspondence between the logical page address and the physical page address of the application program data to the block mapping table in the case that the type to which the application program belongs is the second type, the following application program data management flow may be further included:
Firstly, updating the type of an application program according to a preset parameter corresponding to the application program;
the specific manner of updating the type of the application program according to the preset parameters corresponding to the application program is just referred to the above related description, and will not be described herein.
And secondly, when the type of the application program is changed from the second type to the first type, the corresponding relation between the logical page address and the physical page address of the application program data is transferred from the block mapping table to the page mapping table.
For example: if the application rank is changed from the back (100-T)% to the front T%, the type of the application is considered to be changed from the second type to the first type, and the management mode of the application data from the block mapping is changed to the page mapping management mode.
The address mapping unit of the page mapping mode is a page, so after the data of the application program is converted from block mapping to page mapping, a corresponding page table item needs to be established for each page in the block so as to realize quick indexing of the data of the application program.
The method can be used for selectively updating the application program types, and the technical means of the application program data management mode can be adjusted according to the type adaptability, so that the response speed of the first type application program read-write request can be ensured, the first type application program can be smoothly operated, and the use experience of a user is improved.
It should be noted that, in the data management method provided in the embodiment of the present application, the execution subject may be a data management device, and a control module for executing the data management method in the data management device. In the embodiment of the present application, a data management device is described by taking a data management method performed by the data management device as an example.
Fig. 3 is a block diagram of a data management device implementing an embodiment of the present application. The data management apparatus shown in fig. 3 is used to implement the data management method shown in fig. 1 to 2.
The data management apparatus 300 of the embodiment of the present application includes:
a first determining module 301, configured to determine a type to which the application program belongs based on preset parameters, where the preset parameters include at least one of the following: the user presets information, the use frequency of the application program and the user characteristic analysis result;
a first adding module 302, configured to add, in a case where the type is a first type, a correspondence between a logical page address and a physical page address of the application data to a page mapping table;
and the second adding module is used for adding the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table under the condition that the type is the second type.
Optionally, the first determining module includes: the acquisition sub-module is used for acquiring user preset information input by a user in advance, wherein the preset information comprises at least one of the following: sex information, preference information; a ranking determination sub-module for determining a frequency of use ranking of the application programs based on historical operational data for each installed application program; the analysis sub-module is used for obtaining a user characteristic analysis result by analyzing the managed preset type data; and the type determining submodule is used for determining the type of the application program according to the user preset information, the use frequency ranking and the user characteristic analysis result.
Optionally, the apparatus further includes: the second determining module is used for determining a target logical page address corresponding to the data request under the condition that the data request of the application program is received after the first adding module adds the corresponding relation between the logical page address and the physical page address of the application program data into the page mapping table; and the searching module is used for searching the target physical page address corresponding to each target logical page address according to the mapping relation between each logical page address and the physical page address managed in the page mapping table.
Optionally, the apparatus further includes: the first updating module is used for updating the type of the application program according to the preset parameter corresponding to the application program after the first adding module adds the corresponding relation between the logical page address and the physical page address of the application program data into the page mapping table; and the first transfer module is used for transferring the corresponding relation between the logical page address and the physical page address of the application program data from the page mapping table to the block mapping table under the condition that the type of the application program is changed from the first type to the second type.
Optionally, the apparatus further includes: the second updating module is used for updating the type of the application program according to the preset parameter corresponding to the application program after the second adding module adds the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table; and the second transfer module is used for transferring the corresponding relation between the logical page address and the physical page address of the application program data from the block mapping table to the page mapping table under the condition that the type of the application program is changed from the second type to the first type.
The data management device provided by the embodiment of the application determines the type of the application program based on the preset parameters; under the condition that the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; in the case that the type is the second type, the correspondence between the logical page address and the physical page address of the application program data is added to the block mapping table, and the data management device provided in the embodiment of the present application may divide types of applications installed in the electronic device, store each application program data of the first type in a page mapping manner, and store each application program data of the second type in a conventional block mapping manner. The storage mode of the block mapping can save occupied memory space, the storage mode of the page mapping can improve response speed of read-write requests of the application programs, and the data management device in the embodiment of the application can store the data of each installed application program by combining the mode of the page mapping and the block mapping, so that the response speed of the read-write requests of the first type application program can be ensured without expanding the memory space, and smoothness of the first type application program in use is ensured. The memory space is not required to be enlarged, so that the cost and the design difficulty of the electronic equipment are not increased additionally.
The data management device shown in fig. 3 in this embodiment of the present application may be a device, or may be a component, an integrated circuit, or a chip in a terminal. The device may be a mobile electronic device or a non-mobile electronic device. By way of example, the mobile electronic device may be a cell phone, tablet computer, notebook computer, palm computer, vehicle-mounted electronic device, wearable device, ultra-mobile personal computer (ultra-mobile personal computer, UMPC), netbook or personal digital assistant (personal digital assistant, PDA), etc., and the non-mobile electronic device may be a server, network attached storage (Network Attached Storage, NAS), personal computer (personal computer, PC), television (TV), teller machine or self-service machine, etc., and the embodiments of the present application are not limited in particular.
The data management device shown in fig. 3 in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiments of the present application.
The data management device shown in fig. 3 provided in this embodiment of the present application can implement each process implemented by the method embodiments in fig. 1 to fig. 2, and in order to avoid repetition, a description is omitted here.
Optionally, as shown in fig. 4, an embodiment of the present application further provides an electronic device 400 including: the processor 401, the memory 402, and the program or the instruction stored in the memory 402 and capable of running on the processor 401 implement the processes of the above-mentioned embodiments of the data management method when the program or the instruction is executed by the processor 401, and the same technical effects can be achieved, so that repetition is avoided and no description is repeated here.
It should be noted that, the electronic device in the embodiment of the present application includes the mobile electronic device and the non-mobile electronic device described above.
Fig. 5 is a schematic hardware structure of an electronic device implementing an embodiment of the present application.
The electronic device 500 includes, but is not limited to: radio frequency unit 501, network module 502, audio output unit 503, input unit 504, sensor 505, display unit 506, user input unit 507, interface unit 508, memory 509, and processor 510.
Those skilled in the art will appreciate that the electronic device 500 may further include a power source (e.g., a battery) for powering the various components, and that the power source may be logically coupled to the processor 510 via a power management system to perform functions such as managing charging, discharging, and power consumption via the power management system. The electronic device structure shown in fig. 5 does not constitute a limitation of the electronic device, and the electronic device may include more or less components than shown, or may combine certain components, or may be arranged in different components, which are not described in detail herein.
The processor 510 is configured to determine a type to which the application program belongs based on preset parameters, where the preset parameters include at least one of the following: the user presets information, the use frequency of the application program and the user characteristic analysis result; if the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; and adding the corresponding relation between the logical page address and the physical page address of the application program data into a block mapping table under the condition that the type is the second type.
The electronic device provided by the embodiment of the application determines the type of the application program based on the preset parameters; under the condition that the type is the first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table; and in the case that the type is the second type, adding the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table. According to the electronic device provided by the embodiment of the application program, the installed application programs can be classified, the application program data of the first type is stored in a page mapping mode, and the application program data of other types is stored in a conventional block mapping mode. The storage mode of the block mapping can save occupied memory space, the storage mode of the page mapping can improve response speed of read-write requests of the application program, and in the embodiment of the application, the electronic equipment stores the data of each installed application program by combining the page mapping mode and the block mapping mode, so that the response speed of the read-write requests of the first type application program can be ensured without expanding the memory space, and smoothness of the first type application program in use is ensured. The memory space is not required to be enlarged, so that the cost and the design difficulty of the electronic equipment are not increased additionally.
Optionally, when the processor 510 determines the type of the application program based on the preset parameter, the method is specifically used for: acquiring user preset information input by a user in advance, wherein the preset information comprises at least one of the following: sex information, preference information; determining a frequency of use ranking for each installed application based on historical operational data for the application; analyzing the managed preset type data to obtain a user characteristic analysis result; and determining the type of the application program according to the user preset information, the use frequency ranking and the user trait analysis result.
Optionally, the processor 510 is further configured to: after the corresponding relation between the logical page address and the physical page address of the application program data is added into a page mapping table, determining a target logical page address corresponding to the data request under the condition that the data request of the application program is received; and searching a target physical page address corresponding to each target logical page address according to the mapping relation between each logical page address and the physical page address managed in the page mapping table.
Optionally, the processor 510 is further configured to: after the corresponding relation between the logical page address and the physical page address of the application program data is added into a page mapping table, updating the type of the application program according to the preset parameters corresponding to the application program; and when the type of the application program is changed from the first type to the second type, the corresponding relation between the logical page address and the physical page address of the application program data is restored from the page mapping table to the block mapping table.
Optionally, the processor 510 is further configured to update the type of the application program according to the preset parameter corresponding to the application program after adding the correspondence between the logical page address and the physical page address of the application program data to the block mapping table; and when the type of the application program is changed from the second type to the first type, the corresponding relation between the logical page address and the physical page address of the application program data is restored from the block mapping table to the page mapping table.
It should be appreciated that in embodiments of the present application, the input unit 504 may include a graphics processor (Graphics Processing Unit, GPU) 5041 and a microphone 5042, with the graphics processor 5041 processing image data of still pictures or video obtained by an image capturing device (e.g., a camera) in a video capturing mode or an image capturing mode. The display unit 506 may include a display panel 5061, and the display panel 5061 may be configured in the form of a liquid crystal display, an organic light emitting diode, or the like. The user input unit 507 includes a touch panel 5071 and other input devices 5072. Touch panel 5071, also referred to as a touch screen. Touch panel 5071 may include two parts, a touch detection device and a touch controller. Other input devices 5072 may include, but are not limited to, a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and so forth, which are not described in detail herein. The memory 509 may be used to store software programs as well as various data including, but not limited to, application programs and an operating system. Processor 510 may integrate an application processor that primarily handles operating systems, user interfaces, applications, etc., with a modem processor that primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 510.
The embodiment of the present application further provides a readable storage medium, where a program or an instruction is stored, and when the program or the instruction is executed by a processor, the program or the instruction implements each process of the embodiment of the data management method, and the same technical effects can be achieved, so that repetition is avoided, and no further description is given here.
Wherein the processor is a processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium such as a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and the like.
The embodiment of the application further provides a chip, the chip includes a processor and a communication interface, the communication interface is coupled with the processor, and the processor is used for running a program or an instruction, so as to implement each process of the embodiment of the data management method, and achieve the same technical effect, so that repetition is avoided, and no redundant description is provided here.
It should be understood that the chips referred to in the embodiments of the present application may also be referred to as system-on-chip chips, chip systems, or system-on-chip chips, etc.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element. Furthermore, it should be noted that the scope of the methods and apparatus in the embodiments of the present application is not limited to performing the functions in the order shown or discussed, but may also include performing the functions in a substantially simultaneous manner or in an opposite order depending on the functions involved, e.g., the described methods may be performed in an order different from that described, and various steps may also be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk), including several instructions for causing a terminal (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to perform the method described in the embodiments of the present application.
The embodiments of the present application have been described above with reference to the accompanying drawings, but the present application is not limited to the above-described embodiments, which are merely illustrative and not restrictive, and many forms may be made by those of ordinary skill in the art without departing from the spirit of the present application and the scope of the claims, which are also within the protection of the present application.

Claims (8)

1. A method of data management, the method comprising:
determining the type of the application program based on preset parameters, wherein the preset parameters comprise at least one of the following: the user presets information, the use frequency of the application program and the user characteristic analysis result;
when the type of the application program is a first type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a page mapping table, and managing the application program data of the first type in a page mapping mode; under the condition that a data request of the first type application program is received, directly positioning to a physical storage address corresponding to the data request through the page mapping table, and accessing the physical storage address;
when the type of the application program is a second type, adding the corresponding relation between the logical page address and the physical page address of the application program data into a block mapping table, and managing the application program data of the second type in a block mapping mode;
the first type is a type to which an application program with a use frequency higher than a preset frequency in a preset time period belongs, and the second type is a type to which an application program with a use frequency lower than or equal to the preset frequency in the preset time period belongs;
After the step of adding the correspondence of the logical page address and the physical page address of the application data to the page mapping table, the method further comprises:
updating the type of the application program according to the preset parameters corresponding to the application program, wherein the updating comprises the following steps: updating the type of the application program at intervals of preset time intervals, or updating the electronic equipment when the electronic equipment is in an idle state;
when the type of the application program is changed from the first type to the second type, the corresponding relation between the logical page address and the physical page address of the application program data is restored from the page mapping table to the block mapping table;
and under the condition that the type of the application program is changed from the second type to the first type, changing the management mode of the application program data from the block mapping to the management mode of the page mapping, and establishing page table entries for each page in the block corresponding to the application program data so as to realize the indexing of the application program.
2. The method according to claim 1, wherein the step of determining the type of the application program based on the preset parameters comprises:
acquiring user preset information input by a user in advance, wherein the user preset information comprises at least one of the following: sex information, preference information;
Determining a frequency of use ranking for each installed application based on historical operational data for the application;
analyzing the preset type data managed by the application program to obtain a user characteristic analysis result;
and determining the type of the application program according to the user preset information, the use frequency ranking and the user trait analysis result.
3. The method of claim 1, wherein after the step of adding the correspondence of the logical page address and the physical page address of the application data to the page mapping table, the method further comprises:
under the condition that a data request of the application program is received, determining a target logical page address corresponding to the data request;
and searching a target physical page address corresponding to each target logical page address according to the mapping relation between each logical page address and the physical page address managed in the page mapping table.
4. The method of claim 1, wherein after the step of adding the correspondence of the logical page address and the physical page address of the application data to the block mapping table, the method further comprises:
updating the type of the application program according to the preset parameters corresponding to the application program;
And when the type of the application program is changed from the second type to the first type, the corresponding relation between the logical page address and the physical page address of the application program data is restored from the block mapping table to the page mapping table.
5. A data management apparatus, the apparatus comprising:
the first determining module is used for determining the type of the application program based on preset parameters, wherein the preset parameters comprise at least one of the following: the user presets information, the use frequency of the application program and the user characteristic analysis result;
the first adding module is used for adding the corresponding relation between the logical page address and the physical page address of the application program data to the page mapping table and managing the application program data of the first type in a page mapping mode under the condition that the type of the application program is the first type; under the condition that a data request of the first type application program is received, directly positioning to a physical storage address corresponding to the data request through the page mapping table, and accessing the physical storage address;
the second adding module is configured to add, in the case where the type to which the application program belongs is a second type, a correspondence between a logical page address and a physical page address of the application program data to a block mapping table, and manage the application program data of the second type in a block mapping manner, where the first type is a type to which an application program whose use frequency is higher than a preset frequency in a preset duration belongs, and the second type is a type to which an application program whose use frequency is lower than or equal to the preset frequency in the preset duration belongs;
The apparatus further comprises:
the first updating module is configured to update, after the first adding module adds the correspondence between the logical page address and the physical page address of the application program data to the page mapping table, the type to which the application program belongs according to the preset parameter corresponding to the application program, where the updating module includes: updating the type of the application program at intervals of preset time intervals, or updating the electronic equipment when the electronic equipment is in an idle state;
the first transfer module is used for transferring the corresponding relation between the logical page address and the physical page address of the application program data from the page mapping table to the block mapping table under the condition that the type of the application program is changed from the first type to the second type; and under the condition that the type of the application program is changed from the second type to the first type, changing the management mode of the application program data from the block mapping to the management mode of the page mapping, and establishing page table entries for each page in the block corresponding to the application program data so as to realize the indexing of the application program.
6. The apparatus of claim 5, wherein the first determining module comprises:
The acquisition sub-module is used for acquiring user preset information input by a user in advance, wherein the user preset information comprises at least one of the following steps: sex information, preference information;
a ranking determination sub-module for determining a frequency of use ranking of the application programs based on historical operational data for each installed application program;
the analysis sub-module is used for analyzing the preset type data managed by the application program to obtain a user characteristic analysis result; and the type determining submodule is used for determining the type of the application program according to the user preset information, the use frequency ranking and the user characteristic analysis result.
7. The apparatus of claim 5, wherein the apparatus further comprises:
the second determining module is used for determining a target logical page address corresponding to the data request under the condition that the data request of the application program is received after the first adding module adds the corresponding relation between the logical page address and the physical page address of the application program data into the page mapping table;
and the searching module is used for searching the target physical page address corresponding to each target logical page address according to the mapping relation between each logical page address and the physical page address managed in the page mapping table.
8. The apparatus of claim 5, wherein the apparatus further comprises:
the second updating module is used for updating the type of the application program according to the preset parameter corresponding to the application program after the second adding module adds the corresponding relation between the logical page address and the physical page address of the application program data into the block mapping table;
and the second transfer module is used for transferring the corresponding relation between the logical page address and the physical page address of the application program data from the block mapping table to the page mapping table under the condition that the type of the application program is changed from the second type to the first type.
CN202010616451.3A 2020-06-30 2020-06-30 Data management method and device Active CN111858395B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010616451.3A CN111858395B (en) 2020-06-30 2020-06-30 Data management method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010616451.3A CN111858395B (en) 2020-06-30 2020-06-30 Data management method and device

Publications (2)

Publication Number Publication Date
CN111858395A CN111858395A (en) 2020-10-30
CN111858395B true CN111858395B (en) 2024-03-19

Family

ID=72988990

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010616451.3A Active CN111858395B (en) 2020-06-30 2020-06-30 Data management method and device

Country Status (1)

Country Link
CN (1) CN111858395B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014157817A1 (en) * 2013-03-25 2014-10-02 아주대학교산학협력단 Method for mapping page address based on flash memory and system therefor
CN105224240A (en) * 2014-05-30 2016-01-06 北京忆恒创源科技有限公司 By the method for data write storage device, device and memory device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102218712B1 (en) * 2014-02-11 2021-02-22 삼성전자주식회사 Method of mapping address in storage device and method of reading data from storage device

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014157817A1 (en) * 2013-03-25 2014-10-02 아주대학교산학협력단 Method for mapping page address based on flash memory and system therefor
CN105224240A (en) * 2014-05-30 2016-01-06 北京忆恒创源科技有限公司 By the method for data write storage device, device and memory device

Also Published As

Publication number Publication date
CN111858395A (en) 2020-10-30

Similar Documents

Publication Publication Date Title
WO2022156368A1 (en) Recommended information display method and apparatus
CN108121803B (en) Method and server for determining page layout
CN108984064B (en) Split screen display method and device, storage medium and electronic equipment
CN115167725A (en) Method for providing operation guidance information of terminal and terminal equipment
CN111831182B (en) Application icon control method and device and electronic equipment
CN108287743B (en) Page jump method, terminal and storage medium in application program
CN113190741B (en) Search method, search device, electronic equipment and storage medium
CN110196833B (en) Application searching method, device, terminal and storage medium
CN112416201B (en) Application cache cleaning method and device, electronic equipment and medium
CN112148165A (en) Display method and device and electronic equipment
CN112052420A (en) Page sharing picture generation method and device and page sharing method and device
US9959010B1 (en) Method for displaying information, and terminal equipment
CN113311973A (en) Recommendation method and device
CN107632985B (en) Webpage preloading method and device
CN110333815B (en) Touch event processing method and device
CN111858395B (en) Data management method and device
CN113805997B (en) Information display method, information display device, electronic equipment and storage medium
CN114374663B (en) Message processing method and message processing device
CN114638742A (en) Scene picture processing method and electronic equipment
CN115379113A (en) Shooting processing method, device, equipment and storage medium
CN114089885A (en) Application icon management method and device, electronic equipment and readable storage medium
CN113032290A (en) Flash memory configuration method and device, electronic equipment and storage medium
CN108897774B (en) Method, device and storage medium for acquiring news hotspots
CN113282830A (en) Display method and display device
CN112099682A (en) Icon display method and device and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant