CN108804231A - A kind of Memory Optimize Method, device, readable storage medium storing program for executing and mobile terminal - Google Patents
A kind of Memory Optimize Method, device, readable storage medium storing program for executing and mobile terminal Download PDFInfo
- Publication number
- CN108804231A CN108804231A CN201810610159.3A CN201810610159A CN108804231A CN 108804231 A CN108804231 A CN 108804231A CN 201810610159 A CN201810610159 A CN 201810610159A CN 108804231 A CN108804231 A CN 108804231A
- Authority
- CN
- China
- Prior art keywords
- memory
- application program
- average
- program
- run
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5011—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
- G06F9/5016—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5011—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
- G06F9/5022—Mechanisms to release resources
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Telephone Function (AREA)
- Stored Programmes (AREA)
- Techniques For Improving Reliability Of Storages (AREA)
Abstract
The present invention relates to a kind of Memory Optimize Method, device, readable storage medium storing program for executing and mobile terminals, and described method includes following steps:After receiving a system boot signal, the corresponding program operation information of each application program that use state is in each unit time-count cycle is obtained;According to the number of run of acquisition, average operation duration and average EMS memory occupation value, the corresponding weighted value of each application program is calculated;When determining system spare memory less than default memory, then according to multiple weighted values, corresponding application program is removed according to predetermined order rule, to ensure that system spare memory is not less than default memory.Memory Optimize Method proposed by the present invention, it can be achieved that the running memory to mobile terminal device automatic cleaning, improve user experience.
Description
Technical field
The present invention relates to field of computer technology, more particularly to a kind of Memory Optimize Method, device, readable storage medium storing program for executing and
Mobile terminal.
Background technology
It with economic growing and sci-tech product continuous renewal and popularizes, mobile terminal has become people
Most commonly seen electronic equipment in daily life provides a great convenience for the work and life of people.
Currently, application of all kinds of intelligent operating systems on such as mobile phone, tablet computer, car-mounted terminal so that mobile whole
End group is also more and more abundant in the function of types of applications program, and the thing followed is to propose higher want to running memory demand
It asks.In recent years, it is had become for a kind of main trend for the hardware handles chip of mobile terminal configuration higher memory.In addition, in order to protect
Demonstrate,prove mobile terminal at runtime, the fluency of application program operation, and the memory of mobile terminal is efficiently used, often need to movement
Terminal carries out internal memory optimization setting.
However, existing partial movement end product cannot achieve memory and clear up automatically when running memory occupancy is excessive
Function, affect product practical application experience.
Invention content
Based on this, the purpose of the present invention is to solve in the prior art, partial movement end product cannot achieve memory
The problem of automatic cleaning.
The present invention proposes a kind of Memory Optimize Method, wherein described method includes following steps:
After receiving a system boot signal, obtains in each unit time-count cycle and answered in each of use state
With the corresponding program operation information of program, described program operation information includes at least number of run, average operation duration and puts down
Equal EMS memory occupation value;
According to the number of run of acquisition, the average operation duration and the average EMS memory occupation value, calculate
To the corresponding weighted value of each application program;
When determining system spare memory less than default memory, then according to multiple weighted values, according to predetermined order
Rule removes the corresponding application program, to ensure that the system spare memory is not less than the default memory.
Running of mobile terminal process is divided into multiple unit time-count cycles by Memory Optimize Method proposed by the present invention, when
Each application program at runtime, system can automatically record the corresponding number of run of each application program, average operation duration and
Average EMS memory occupation value is directly accounted for memory due to above-mentioned number of run, average operation duration and average EMS memory occupation value
With correlation, therefore the corresponding weighted value of application program is calculated based on three above-mentioned calculating elements, when in the residue of system
When depositing less than default memory, illustrate that memory overloads, it at this time can be right according to predetermined order rule according to the weighted value of each application program
Corresponding application program is cleared up, so that system spare memory is more than default memory, to ensure the normal of mobile terminal
Operation.Memory Optimize Method proposed by the present invention, it can be achieved that the running memory to mobile terminal device automatic cleaning, improve
User experience.
The Memory Optimize Method, wherein described program operation information further include application name, using packet title,
Single operation duration and single EMS memory occupation value, wherein the determination method of the single operation duration includes the following steps:
Obtain the application program being waken up time point and called out with described within any unit time-count cycle
Wake up time point it is adjacent be released time point, wherein described when to be waken up time point be corresponding when the application program is activated
Between, it is described that be released time point be the application program corresponding time when being closed;
According to it is described be waken up time point and it is described be released time point, the single operation duration is calculated.
The Memory Optimize Method, wherein the computational methods of the average operation duration include the following steps:
Multiple single operation durations in the wherein one unit time-count cycle are added up, to obtain a unit
Total operation duration;
The total operation duration of the unit divided by the number of run in the unit time-count cycle is described flat to obtain
Equal operation duration.
The Memory Optimize Method, wherein the method that the corresponding weighted value of each application program is calculated
Include the following steps:
Corresponding unit weighted value in each unit time-count cycle is added up to obtain the weighted value, wherein
The unit weighted value is the memory contribution proportion of the single application program run within each unit time-count cycle.
The Memory Optimize Method, wherein the computational methods of the unit weighted value include the following steps:
At the end of monitoring each unit time-count cycle, by active cell time-count cycle and an adjacent upper list
The number of run, the average operation duration and the average EMS memory occupation value in first time-count cycle are made respectively
Difference, to respectively obtain number of run difference, average operation duration difference and average EMS memory occupation difference;
According to the number of run difference, the average operation duration difference and the average EMS memory occupation mathematic interpolation
To obtain the unit weighted value.
The Memory Optimize Method, wherein the side that the corresponding application program is removed according to predetermined order rule
Method includes the following steps:
By each corresponding weighted value of the application program, arranged according to the ascending mode of the weighted value
Row are to obtain a application list;
In described the application list, eliminated according to the ascending mode of the weighted value corresponding described using journey
Sequence.
The Memory Optimize Method, wherein the computational methods of the average EMS memory occupation value include the following steps:
Multiple single EMS memory occupation values in the wherein one unit time-count cycle are added up, it is single to obtain one
First EMS memory occupation total value;
It is described to obtain that the element memory is occupied into total value divided by the number of run in the unit time-count cycle
Average EMS memory occupation value.
The present invention proposes a kind of internal memory optimization device, wherein described device includes:
Operational monitoring module, for after receiving a system boot signal, obtaining place in each unit time-count cycle
In the corresponding program operation information of each application program of use state, described program operation information include at least number of run,
Average operation duration and average EMS memory occupation value;
Weight computation module, for according to the number of run of acquisition, the average operation duration and described average
The corresponding weighted value of each application program is calculated in EMS memory occupation value;
Internal memory optimization module, for when determining system spare memory and being less than default memory, then according to multiple power
Weight values remove the corresponding application program according to predetermined order rule, to ensure the system spare memory not less than described
Default memory.
The present invention also proposes a kind of readable storage medium storing program for executing, is stored thereon with computer program, wherein described program is handled
Device realizes Memory Optimize Method as described above when executing.
The present invention also proposes a kind of mobile terminal, including memory, processor and storage on a memory and can located
The computer program run on reason device, wherein the processor realizes internal memory optimization side as described above when executing described program
Method.
Other feature and advantage of the disclosure will illustrate in the following description, alternatively, Partial Feature and advantage can be with
Deduce from specification or unambiguously determine, or by implement the disclosure above-mentioned technology it can be learnt that.
To enable the above objects, features and advantages of the present invention to be clearer and more comprehensible, preferred embodiment cited below particularly, and coordinate
Appended attached drawing, is described in detail below.
Description of the drawings
It, below will be to specific in order to illustrate more clearly of the specific embodiment of the invention or technical solution in the prior art
Embodiment or attached drawing needed to be used in the description of the prior art are briefly described, it should be apparent that, in being described below
Attached drawing is some embodiments of the present invention, for those of ordinary skill in the art, before not making the creative labor
It puts, other drawings may also be obtained based on these drawings.
Fig. 1 is the flow chart for the Memory Optimize Method that first embodiment of the invention proposes;
Fig. 2 is the flow chart for the Memory Optimize Method that second embodiment of the invention proposes;
Fig. 3 is the structural schematic diagram for the internal memory optimization device that third embodiment of the invention proposes.
Specific implementation mode
To facilitate the understanding of the present invention, below with reference to relevant drawings to invention is more fully described.In attached drawing
Give the preferred embodiment of the present invention.But the present invention can realize in many different forms, however it is not limited to this paper institutes
The embodiment of description.On the contrary, purpose of providing these embodiments is make it is more thorough and comprehensive to the disclosure.
Unless otherwise defined, all of technologies and scientific terms used here by the article and belong to the technical field of the present invention
The normally understood meaning of technical staff is identical.Used term is intended merely to description tool in the description of the invention herein
The purpose of the embodiment of body, it is not intended that in the limitation present invention.Term " and or " used herein includes one or more phases
Any and all combinations of the Listed Items of pass.
Existing partial movement end product cannot achieve the work(that memory is cleared up automatically when running memory occupancy is excessive
Can, affect the practical application experience of product.
In order to solve this technical problem, the present invention proposes a kind of Memory Optimize Method, referring to Fig. 1, for the present invention
The Memory Optimize Method that first embodiment proposes, this method comprises the following steps:
S101 is obtained after receiving a system boot signal and is in use state in each unit time-count cycle
The corresponding program operation information of each application program, described program operation information include at least number of run, average operation duration
And average EMS memory occupation value.
The present embodiment is illustrated by taking mobile phone as an example, and after mobile phone power-on is run, cell phone system is immediately to being in fortune
The application program of row state is monitored.In the present embodiment, monitoring process is divided into what multiple unit time-count cycles carried out.With
It is illustrated for application program X, the application program X monitored, in unit T time-count cycle0Interior program operation letter
Breath includes:Apply Names AppName, using packet name Package Nname, cycle T0Interior average operation duration T0L, cycle T0
Interior average EMS memory occupation value M0And the number of run N of application program X0.Herein it should be added that, in each unit
In time-count cycle, it is understood that there may be the case where multiple application programs are run simultaneously, cell phone system similarly monitor other in operation
The program operation information of the application program of state.
S102, according to the number of run of acquisition, the average operation duration and the average EMS memory occupation value, meter
Calculation obtains the corresponding weighted value of each application program.
Application program X is obtained in unit T time-count cycle in monitoring0Interior number of run N0, average operation duration T0L with
And average EMS memory occupation value M0Later, if mobile phone continues to run with, cell phone system will continue to monitor next unit timing week
Phase T1It is interior, the relative program operation information of application program X.
For example, in unit T time-count cycle1Interior, the program operation information of the application program X monitored is:Number of run
N1, average operation duration T1L and average EMS memory occupation value M1.If cell phone system continues to run with, in unit T time-count cycle2
Interior, the program operation information of the application program X monitored is:Number of run N2, average operation duration T2L and average memory
Occupation value M2.Similarly, n-th unit T time-count cycle can be pushed into classN, the program operation information of the application program X monitored
For:Number of run NN, average operation duration TNL and average EMS memory occupation value MN。
After monitoring the program operation information of application program X, it is calculated according to the above- mentioned information monitored each
The corresponding weighted value of application program.Specifically, in unit T time-count cycle1At the end of timing, the number of run of application program X becomes
Change, average operation duration variation and average EMS memory occupation value variation are respectively:
Number of run changes NC1=N1-N0
Average operation duration changes TLC1=T1L-T0L
Average EMS memory occupation value changes MC1=M1-M0
Therefore at the end of unit T1 time-count cycle timing, the corresponding unit weighted values of application program X are:
WX1=NC1*X+TCL1*Y+MC1*Z
Wherein, above-mentioned X, Y and Z are coefficient.
It should be noted that for subsequent multiple unit time-count cycles, above-mentioned method can be used and be calculated
The unit weighted value WX within follow-up multiple unit time-count cycles of application program X2、WX3......WXN.It will finally calculate
To multiple unit time-count cycles carry out the cumulative total weighted value for just obtaining application program X.In this respect it is to be noted that using
Total weighted value of other application program can be calculated in above-mentioned same method.
S103, when determining system spare memory less than default memory, then according to multiple weighted values, according to default
Ordering rule removes the corresponding application program, to ensure that the system spare memory is not less than the default memory.
When mobile phone is run, if cell phone system determines system spare memory and is less than default memory, need at this time
Mobile phone Installed System Memory is cleared up, to ensure the fluency of mobile phone operation.It is respectively answered as noted previously, as having calculated
With total weighted value of program corresponding EMS memory occupation at runtime, therefore application program can be carried out according to predetermined order rule clear
Reason.In the present embodiment, each application program is cleared up in such a way that total weighted value of each application program is sequentially reduced, directly
It is not less than default memory to system spare memory, namely can guarantee the normal operation of cell phone system.
Running of mobile terminal process is divided into multiple unit time-count cycles by Memory Optimize Method proposed by the present invention, when
Each application program at runtime, system can automatically record the corresponding number of run of each application program, average operation duration and
Average EMS memory occupation value is directly accounted for memory due to above-mentioned number of run, average operation duration and average EMS memory occupation value
With correlation, therefore the corresponding weighted value of application program is calculated based on three above-mentioned calculating elements, when in the residue of system
When depositing less than default memory, illustrate that memory overloads, it at this time can be right according to predetermined order rule according to the weighted value of each application program
Corresponding application program is cleared up, so that system spare memory is more than default memory, to ensure the normal of mobile terminal
Operation.Memory Optimize Method proposed by the present invention, it can be achieved that the running memory to mobile terminal device automatic cleaning, improve
User experience.
Technical scheme of the present invention is illustrated in further detail with a specific example below.Referring to Fig. 2, right
In the Memory Optimize Method that second embodiment of the invention proposes, specific implementation mode is as described below:
S201 receives system boot signal.
The present embodiment is illustrated by taking a portable flat panel as an example.User after pressing power button booting, just open by Intelligent flat
Begin to run various application programs.
S202, monitoring program operation information, including number of run, single operation duration and single EMS memory occupation value.
When Intelligent flat is run, flat-panel systems can monitor the operation information of the application program of operation.Wherein, monitoring process
It is divided into what multiple unit time-count cycles carried out.
(1) in unit T time-count cycle0It is interior, system monitoring to the program operation information of application program X include:
Apply Names:AppName
Using packet name:PackageNname
Each time point that application program X is waken up:T0S0、T0S1、T0S2、T0S3......T0SN
Each time point that application program X is released:T0E0、T0E1、T0E2、T0E3......T0EN
Application program X single operation durations:T0L0、T0L1、T0L2、T0L3......T0LN
The number of run of application program X:N0
EMS memory occupation value when application program X singles are run:M00、M01、M02、M03......M0N
In unit T time-count cycle0Interior, the program operation information of above application program X is recorded in file A.
In first above-mentioned unit T time-count cycle0After, that is, start second unit T time-count cycle1.Flat-panel systems
The following information of application program X can be equally recorded in file A:
(2) in unit T time-count cycle1It is interior, system monitoring to the program operation information of application program X include:
Apply Names:AppName
Using packet name:PackageNname
Each time point that application program X is waken up:T1S0、T1S1、T1S2、T1S3......T1SN
Each time point that application program X is released:T1E0、T1E1、T1E2、T1E3......T1EN
Application program X single operation durations:T1L0、T1L1、T1L2、T1L3......T1LN
The number of run of application program X:N1
EMS memory occupation value when application program X singles are run:M10、M11、M12、M13......M1N
In second above-mentioned unit T time-count cycle1After, that is, start third unit T time-count cycle2.Flat-panel systems
The following information of application program X can be equally recorded in file A:
(3) in unit T time-count cycle2It is interior, system monitoring to the program operation information of application program X include:
Apply Names:AppName
Using packet name:PackageNname
Each time point that application program X is waken up:T2S0、T2S1、T2S2、T2S3......T2SN
Each time point that application program X is released:T2E0、T2E1、T2E2、T2E3......T2EN
Application program X single operation durations:T2L0、T2L1、T2L2、T2L3......T2LN
The number of run of application program X:N2
EMS memory occupation value when application program X singles are run:M20、M21、M22、M23......M2N
(4) in unit T time-count cycleNIt is interior, system monitoring to the program operation information of application program X include:
Apply Names:AppName
Using packet name:PackageNname
Each time point that application program X is waken up:TNS0、TNS1、TNS2、TNS3......TNSN
Each time point that application program X is released:TNE0、TNE1、TNE2、TNE3......TNEN
Application program X single operation durations:TNL0、TNL1、TNL2、TNL3......TNLN
The number of run of application program X:NN
EMS memory occupation value when application program X singles are run:MN0、MN1、MN2、MN3......MNN
Average operation duration and average EMS memory occupation value is calculated in S203.
(1) in unit T time-count cycle0It is interior:
The average operation duration of application program X:T0L=(T0L0+T0L1+T0L2+T0L3......+T0LN)/N0
The average EMS memory occupation value of application program X:M0=(M00+M01+M02+M03...M0N)/N0
(2) in unit T time-count cycle1It is interior:
The average operation duration of application program X:T1L=(T1L0+T1L1+T1L2+T1L3......T1LN)/N1
The average EMS memory occupation value of application program X:M1=(M10+M11+M12+M13...M1N)/N1
(3) in unit T time-count cycle2It is interior:
The average operation duration of application program X:T2L=(T2L0+T2L1+T2L2+T2L3......T2LN)/N2
The average EMS memory occupation value of application program X:M2=(M20+M21+M22+M23...M2N)/N2
(4) in unit T time-count cycleNIt is interior:
The average operation duration of application program X:TNL=(TNL0+TNL1+TNL2+TNL3......TNLN)/NN
The average EMS memory occupation value of application program X:MN=(MN0+MN1+MN2+MN3...MNN)/NN
The weighted value of each application program is calculated in S204.
In unit T time-count cycle1At the end of, by unit T time-count cycle1With unit T time-count cycle0Between, corresponding application
The number difference of program X, average operation duration difference, average EMS memory occupation difference are recorded in file B.
Specifically, working as unit T time-count cycle1At the end of, the related operating parameter difference of application program X is as follows:
Number difference NC1=N1-N0
Average operation duration difference TLC1=T1L-T0L
Average EMS memory occupation difference MC1=M1-M0
As unit T time-count cycle2At the end of, the related operating parameter difference of application program X is as follows:
Number difference NC2=N2-N1
Average operation duration difference TLC2=T2L-T1L
Average EMS memory occupation difference MC2=M2-M1
As unit T time-count cycleNAt the end of, the related operating parameter difference of application program X is as follows:
Number difference NCN=NN-NN-1
Average operation duration difference TLCN=TNL-TN-1L
Average EMS memory occupation difference MCN=MN-MN-1
In unit T time-count cycle1At the end of, the corresponding unit weighted values of application program X are:
WX1=NC1*X+TCL1*Y+MC1*Z
In unit T time-count cycle2At the end of, the corresponding unit weighted values of application program X are:
WX2=NC2*X+TCL2*Y+MC2*Z
In unit T time-count cycle3At the end of, the corresponding unit weighted values of application program X are:
WX3=NC3*X+TCL3*Y+MC3*Z
In unit T time-count cycleNAt the end of, the corresponding unit weighted values of application program X are:
WXN=NCN*X+TCLN*Y+MCN*Z
Wherein, above-mentioned X, Y and Z are coefficient.
Application program X is being calculated within each unit time-count cycle after corresponding unit weighted value, it will be multiple
Unit weighted value is added up to obtain total weighted value, and corresponding expression formula is:
WX=WX1+WX2+WX3......+WXN
It should be noted that method as described above, which can be used, is calculated any application journey in operating status
Total weighted value of sequence.
Whether S205, system spare memory are less than default memory.
During Intelligent flat is run, if flat-panel systems determine system spare memory and are less than default memory, this
When need to the flat-panel systems carry out memory cleaning, with ensure flat-panel systems operation when fluency.It should be understood that working as system
Free memory is more than default memory, then need not also carry out memory cleaning at this time.
S206 clears up corresponding application program automatically.
When carrying out memory cleaning, pressed according to the size of the corresponding total weighted value of each application program in the present embodiment
It is arranged according to the mode of descending, is cleared up successively.For example, arranged according to the descending sequence of total weighted value,
It is followed successively by:" wechat ", corresponding total weighted value are 16%;" Alipay ", corresponding total weighted value are 10%;" Amap ",
Corresponding total weighted value is 8%;" mobile phone Taobao ", corresponding total weighted value are 7%;" taking journey travelling ", corresponding total weighted value
It is 5%, then is carried out according to the sequence of " wechat ", " Alipay ", " Amap ", " mobile phone Taobao " and " taking journey travelling " clear
Reason.
Supplementary explanation is also needed to herein, and the embedded memory cleaning software of flat-panel systems itself is not cleaned, is not belonging to
It is cleaned in list.At the same time, user can also according to itself application demand, each application program of manual setting by automatic clear
Permission is managed, for partly needing the application program of real time execution, is then excluded outside cleaning list.
Referring to Fig. 3, the internal memory optimization device proposed for third embodiment of the invention comprising sequentially connected operation
Monitoring modular 11, weight computation module 12 and internal memory optimization module 13;
Wherein the operational monitoring module 11 is specifically used for:
After receiving a system boot signal, obtains in each unit time-count cycle and answered in each of use state
With the corresponding program operation information of program, described program operation information includes at least number of run, average operation duration and puts down
Equal EMS memory occupation value;
The weight computation module 12 is specifically used for:
According to the number of run of acquisition, the average operation duration and the average EMS memory occupation value, calculate
To the corresponding weighted value of each application program;
The internal memory optimization module 13 is specifically used for:
When determining system spare memory less than default memory, then according to multiple weighted values, according to predetermined order
Rule removes the corresponding application program, to ensure that the system spare memory is not less than the default memory.
The present invention also proposes a kind of readable storage medium storing program for executing, is stored thereon with computer program, wherein described program is handled
Device realizes Memory Optimize Method as described above when executing.
The present invention also proposes a kind of mobile terminal, including memory, processor and storage on a memory and can located
The computer program run on reason device, wherein the processor realizes internal memory optimization side as described above when executing described program
Method.
One of ordinary skill in the art will appreciate that implement the method for the above embodiments be can be with
Relevant hardware is instructed to complete by program.The program can be stored in a computer read/write memory medium.
The program when being executed, including the step described in the above method.The storage medium, including:ROM/RAM, magnetic disc, CD
Deng.
Finally it should be noted that:Embodiment described above, only specific implementation mode of the invention, to illustrate the present invention
Technical solution, rather than its limitations, scope of protection of the present invention is not limited thereto, although with reference to the foregoing embodiments to this hair
It is bright to be described in detail, it will be understood by those of ordinary skill in the art that:Any one skilled in the art
In the technical scope disclosed by the present invention, it can still modify to the technical solution recorded in previous embodiment or can be light
It is readily conceivable that variation or equivalent replacement of some of the technical features;And these modifications, variation or replacement, do not make
The essence of corresponding technical solution is detached from the spirit and scope of technical solution of the embodiment of the present invention, should all cover the protection in the present invention
Within the scope of.Therefore, protection scope of the present invention should be based on the protection scope of the described claims.
Claims (10)
1. a kind of Memory Optimize Method, which is characterized in that described method includes following steps:
After receiving a system boot signal, obtains in each unit time-count cycle and apply journey in each of use state
The corresponding program operation information of sequence, described program operation information include at least number of run, the operation duration that is averaged and are averaged interior
Deposit occupation value;
According to the number of run of acquisition, the average operation duration and the average EMS memory occupation value, it is calculated every
The corresponding weighted value of a application program;
When determining system spare memory less than default memory, then according to multiple weighted values, according to predetermined order rule
The corresponding application program is removed, to ensure that the system spare memory is not less than the default memory.
2. Memory Optimize Method according to claim 1, which is characterized in that described program operation information further includes applying journey
Sequence title, using packet title, single operation duration and single EMS memory occupation value, wherein the determination side of the single operation duration
Method includes the following steps:
It obtains the application program and is waken up time point and when with described being waken up within any unit time-count cycle
Between put it is adjacent be released time point, wherein described, to be waken up time point be the corresponding time when application program is activated,
It is described that be released time point be the application program corresponding time when being closed;
According to it is described be waken up time point and it is described be released time point, the single operation duration is calculated.
3. Memory Optimize Method according to claim 2, which is characterized in that the computational methods packet of the average operation duration
Include following steps:
Multiple single operation durations in the wherein one unit time-count cycle are added up, are always transported with obtaining a unit
Row duration;
By the total operation duration of the unit divided by the number of run in the unit time-count cycle to obtain the average fortune
Row duration.
4. Memory Optimize Method according to claim 2, which is characterized in that described that each application program is calculated
The method of corresponding weighted value includes the following steps:
Corresponding unit weighted value in each unit time-count cycle is added up to obtain the weighted value, wherein described
Unit weighted value is the memory contribution proportion of the single application program run within each unit time-count cycle.
5. Memory Optimize Method according to claim 4, which is characterized in that the computational methods of the unit weighted value include
Following steps:
At the end of monitoring each unit time-count cycle, by active cell time-count cycle and an adjacent upper unit meter
When the period in the number of run, the average operation duration and the average EMS memory occupation value carry out making respectively it is poor, with
Respectively obtain number of run difference, average operation duration difference and average EMS memory occupation difference;
According to the number of run difference, the average operation duration difference and the average EMS memory occupation mathematic interpolation to obtain
To the unit weighted value.
6. Memory Optimize Method according to claim 4, which is characterized in that described removed according to predetermined order rule corresponds to
The method of the application program include the following steps:
Will the corresponding weighted value of each application program, according to the ascending mode of the weighted value arranged with
Obtain a application list;
In described the application list, the corresponding application program is eliminated according to the ascending mode of the weighted value.
7. Memory Optimize Method according to claim 2, which is characterized in that the computational methods of the average EMS memory occupation value
Include the following steps:
Multiple single EMS memory occupation values in the wherein one unit time-count cycle are added up, to obtain in a unit
Deposit occupancy total value;
The element memory is occupied into total value divided by the number of run in the unit time-count cycle is described average to obtain
EMS memory occupation value.
8. a kind of internal memory optimization device, which is characterized in that described device includes:
Operational monitoring module makes for after receiving a system boot signal, obtaining to be in each unit time-count cycle
With the corresponding program operation information of each application program of state, described program operation information includes at least number of run, is averaged
Operation duration and average EMS memory occupation value;
Weight computation module, for according to the number of run of acquisition, the average operation duration and the average memory
The corresponding weighted value of each application program is calculated in occupation value;
Internal memory optimization module, for when determining system spare memory and being less than default memory, then according to multiple weighted values,
The corresponding application program is removed according to predetermined order rule, to ensure that the system spare memory is default interior not less than described
It deposits.
9. a kind of readable storage medium storing program for executing, is stored thereon with computer program, which is characterized in that when described program is executed by processor
Realize the Memory Optimize Method described in 1 to 7 any one of the claims.
10. a kind of mobile terminal, including memory, processor and storage are on a memory and the meter that can run on a processor
Calculation machine program, which is characterized in that the processor is realized when executing described program as described in claim 1 to 7 any one
Memory Optimize Method.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810610159.3A CN108804231B (en) | 2018-06-13 | 2018-06-13 | Memory optimization method and device, readable storage medium and mobile terminal |
PCT/CN2019/087751 WO2019237891A1 (en) | 2018-06-13 | 2019-05-21 | Memory optimization method and apparatus, and readable storage medium and mobile terminal |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810610159.3A CN108804231B (en) | 2018-06-13 | 2018-06-13 | Memory optimization method and device, readable storage medium and mobile terminal |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108804231A true CN108804231A (en) | 2018-11-13 |
CN108804231B CN108804231B (en) | 2020-10-30 |
Family
ID=64085928
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810610159.3A Active CN108804231B (en) | 2018-06-13 | 2018-06-13 | Memory optimization method and device, readable storage medium and mobile terminal |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN108804231B (en) |
WO (1) | WO2019237891A1 (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109753316A (en) * | 2018-11-22 | 2019-05-14 | 惠州Tcl移动通信有限公司 | Intelligent terminal and its control method, the device with store function |
CN110321224A (en) * | 2019-07-04 | 2019-10-11 | 深圳市康冠技术有限公司 | Terminal memory method for cleaning, device and computer readable storage medium |
WO2019237891A1 (en) * | 2018-06-13 | 2019-12-19 | 奇酷互联网络科技(深圳)有限公司 | Memory optimization method and apparatus, and readable storage medium and mobile terminal |
CN110737523A (en) * | 2019-10-18 | 2020-01-31 | 湖南快乐阳光互动娱乐传媒有限公司 | method and terminal for improving application starting speed through memory cleaning |
CN111078407A (en) * | 2019-12-10 | 2020-04-28 | Oppo(重庆)智能科技有限公司 | Memory management method and device, storage medium and electronic equipment |
CN111104180A (en) * | 2019-12-11 | 2020-05-05 | 惠州Tcl移动通信有限公司 | Application program optimization method and device, storage medium and electronic equipment |
CN111666153A (en) * | 2020-05-25 | 2020-09-15 | 深圳Tcl新技术有限公司 | Cache task management method, terminal device and storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103324575A (en) * | 2012-03-23 | 2013-09-25 | 腾讯科技(深圳)有限公司 | Memory clearing method and mobile terminal |
CN103927230A (en) * | 2014-03-25 | 2014-07-16 | 优视科技有限公司 | Memory usage feedback method and device |
CN105354093A (en) * | 2015-12-09 | 2016-02-24 | 广东欧珀移动通信有限公司 | Memory management method and mobile terminal |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108804231B (en) * | 2018-06-13 | 2020-10-30 | 奇酷互联网络科技(深圳)有限公司 | Memory optimization method and device, readable storage medium and mobile terminal |
-
2018
- 2018-06-13 CN CN201810610159.3A patent/CN108804231B/en active Active
-
2019
- 2019-05-21 WO PCT/CN2019/087751 patent/WO2019237891A1/en active Application Filing
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103324575A (en) * | 2012-03-23 | 2013-09-25 | 腾讯科技(深圳)有限公司 | Memory clearing method and mobile terminal |
CN103927230A (en) * | 2014-03-25 | 2014-07-16 | 优视科技有限公司 | Memory usage feedback method and device |
CN105354093A (en) * | 2015-12-09 | 2016-02-24 | 广东欧珀移动通信有限公司 | Memory management method and mobile terminal |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2019237891A1 (en) * | 2018-06-13 | 2019-12-19 | 奇酷互联网络科技(深圳)有限公司 | Memory optimization method and apparatus, and readable storage medium and mobile terminal |
CN109753316A (en) * | 2018-11-22 | 2019-05-14 | 惠州Tcl移动通信有限公司 | Intelligent terminal and its control method, the device with store function |
CN110321224A (en) * | 2019-07-04 | 2019-10-11 | 深圳市康冠技术有限公司 | Terminal memory method for cleaning, device and computer readable storage medium |
CN110737523A (en) * | 2019-10-18 | 2020-01-31 | 湖南快乐阳光互动娱乐传媒有限公司 | method and terminal for improving application starting speed through memory cleaning |
CN111078407A (en) * | 2019-12-10 | 2020-04-28 | Oppo(重庆)智能科技有限公司 | Memory management method and device, storage medium and electronic equipment |
CN111104180A (en) * | 2019-12-11 | 2020-05-05 | 惠州Tcl移动通信有限公司 | Application program optimization method and device, storage medium and electronic equipment |
CN111104180B (en) * | 2019-12-11 | 2021-08-03 | 惠州Tcl移动通信有限公司 | Application program optimization method and device, storage medium and electronic equipment |
CN111666153A (en) * | 2020-05-25 | 2020-09-15 | 深圳Tcl新技术有限公司 | Cache task management method, terminal device and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN108804231B (en) | 2020-10-30 |
WO2019237891A1 (en) | 2019-12-19 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108804231A (en) | A kind of Memory Optimize Method, device, readable storage medium storing program for executing and mobile terminal | |
US8959509B1 (en) | Techniques for virtual machine backup scheduling | |
CN103365710B (en) | Real-time task scheduling device and method and computer system | |
CN107231264A (en) | For the method and apparatus for the capacity for managing Cloud Server | |
CN109558234A (en) | A kind of timed task dispatching method and device | |
JP2012506597A5 (en) | ||
CN105786552B (en) | A kind of memory method for cleaning and electronic equipment | |
CN106897795A (en) | A kind of inventory forecast method and device | |
CN105388991A (en) | Timing wake-up processing system and method | |
CN103677976A (en) | Event handling method and device based on time wheel timer | |
CN106959892A (en) | Process handling method, device and electronic equipment | |
CN103543901B (en) | The method and apparatus generating menu | |
CN108255595A (en) | A kind of dispatching method of data task, device, equipment and readable storage medium storing program for executing | |
CN107491331A (en) | A kind of application upgrade method and terminal device | |
CN106503543A (en) | A kind of method and apparatus of management application program | |
CN112328289B (en) | Firmware upgrading method, device, equipment and storage medium | |
CN110162563A (en) | A kind of data storage method, system and electronic equipment and storage medium | |
CN108881630A (en) | reverse charging management method, device and terminal | |
CN103118156B (en) | Alarm clock setting method and related equipment | |
CN112416596A (en) | Node scheduling method, device and equipment | |
CN104036132B (en) | A kind of user behavior analysis method and apparatus | |
CN110979084A (en) | Charging control method, system and device for electric vehicle charging station | |
CN106020333A (en) | Multi-core timer implementation method and multi-core system | |
JP6012869B2 (en) | Information management system, information management apparatus, information management method, and program | |
CN110515771A (en) | A kind of object storage device setting method, system, equipment and computer media |
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 |