CN105955823A - Method and system for determining operation frequency of computing resource - Google Patents

Method and system for determining operation frequency of computing resource Download PDF

Info

Publication number
CN105955823A
CN105955823A CN201610255067.9A CN201610255067A CN105955823A CN 105955823 A CN105955823 A CN 105955823A CN 201610255067 A CN201610255067 A CN 201610255067A CN 105955823 A CN105955823 A CN 105955823A
Authority
CN
China
Prior art keywords
operation frequency
thread
time period
sampling
historical record
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
Application number
CN201610255067.9A
Other languages
Chinese (zh)
Other versions
CN105955823B (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.)
Oneplus Technology Shenzhen Co Ltd
Original Assignee
Oneplus Technology Shenzhen 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 Oneplus Technology Shenzhen Co Ltd filed Critical Oneplus Technology Shenzhen Co Ltd
Priority to CN201610255067.9A priority Critical patent/CN105955823B/en
Publication of CN105955823A publication Critical patent/CN105955823A/en
Application granted granted Critical
Publication of CN105955823B publication Critical patent/CN105955823B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements 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/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals

Abstract

The invention provides a method and a system for determining operation frequency of computing resources. The method comprises: in a sampling time period, obtaining operating time of at least a thread on at least a computing resource, and operation frequency corresponding to each operating time period; according to the operating time period and the corresponding operation frequency, calculating to obtain effective sampling operation frequency of at least a thread in the sampling time period; out of the sampling time period, according to the effective sampling operation frequency, determining the operation frequency of operating the computing resource of at least a thread. According to the operating time period of each thread on each computing resource, and corresponding computing resources, the effective sampling operation frequency of each thread in the sampling time period is calculated. Compared with using a certain operation frequency as the basis of thread performance requirement in a conventional method, the method uses the operating time period and the corresponding operation frequency as basis to evaluate performance of each thread, and the method is more accurate and reliable, and accurately gives out performance evaluation of each thread.

Description

Determine the method and system of the operation frequency of calculation resources
Technical field
The present invention relates to Computer Applied Technology field, particularly relate to a kind of computing frequency determining calculation resources The method and system of rate.
Background technology
In some fields, such as in mobile intelligent terminal, in the upper operation of a calculation resources (such as CPU) Thread in, have the thread of high-effect demand simultaneously and need not the thread of how much usefulness.Computing is being provided When thread on source carries out measures of effectiveness, it is usually directly using the current operation frequency of calculation resources as thread The reference of required usefulness, or with in the most several time periods, needed for certain operation frequency once is as thread The foundation of usefulness, the performance requirements so evaluated or too high or too low, it is impossible to evaluate exactly The performance requirements of each thread.
Summary of the invention
In consideration of it, be necessary can not evaluate exactly the asking of performance requirements of each thread for conventional art Topic, it is provided that the operation frequency of a kind of determination calculation resources that can give the correct measures of effectiveness of each thread Method and system.
For reaching goal of the invention, it is provided that a kind of method of operation frequency determining calculation resources, described method bag Include:
In a sampling time section, obtain the operation that at least one thread runs at least one calculation resources Time period and each run operation frequency corresponding to time period;
It is calculated in described sampling time section according to the described described operation frequency running time period and correspondence The efficiently sampling operation frequency of at least one thread described;
Outside described sampling time section, determine described in operation at least one according to described efficiently sampling operation frequency The operation frequency of the calculation resources of individual thread.
Wherein in an embodiment, described method also includes:
It is calculated in described sampling time section according to the described described operation frequency running time period and correspondence The average sample operation frequency of all described threads;
The historical record operation frequency in the historical record time period before obtaining described sampling time section and described The time factor that historical record operation frequency is corresponding;
Calculate according to described average sample operation frequency, described historical record operation frequency and described time factor Obtain the overall effectively operation frequency of all described thread in described sampling time section.
Wherein in an embodiment, described according to described average sample operation frequency, described historical record fortune Being integrated with of all described thread that calculation frequency and described time factor are calculated in described sampling time section After the step of effect operation frequency, also include:
Record the effective operation frequency of described entirety;
Using effective for described entirety operation frequency as historical record operation frequency corresponding to subsequent sampling times section.
Wherein in an embodiment, the described historical record time period is the closer to described sampling time section, described Proportion shared by described time factor corresponding to historical record time period is the biggest.
Wherein in an embodiment, described according to described operation time period and the described operation frequency meter of correspondence Calculate and obtain the step bag of the efficiently sampling operation frequency of at least one thread described in described sampling time section Include:
Calculate the described operation time period of each described thread and the product of corresponding operation frequency, and by each The described product summation of described thread, obtains the sum of products of each described thread;
In calculating described sampling time section all described threads run the time period time and;
By described sum of products divided by the described time and, obtain the described efficiently sampling computing frequency of each described thread Rate.
The present invention also provides for the system of a kind of operation frequency determining calculation resources, and described system includes:
First acquisition module, in a sampling time section, obtains at least one thread and transports at least one Calculate the operation time period of operation in resource and the operation frequency that each operation time period is corresponding;
First computing module, for being calculated according to the described described operation frequency running time period and correspondence The efficiently sampling operation frequency of at least one thread described in described sampling time section;
Determine module, for outside described sampling time section, determine according to described efficiently sampling operation frequency Run the operation frequency of the calculation resources of at least one thread described.
Wherein in an embodiment, described system also includes:
Second computing module, for being calculated according to the described described operation frequency running time period and correspondence The average sample operation frequency of all described threads in described sampling time section;
Second acquisition module, for obtaining the history in the historical record time period before described sampling time section Record operation frequency and time factor corresponding to described historical record operation frequency;
3rd computing module, for according to described average sample operation frequency, described historical record operation frequency And described time factor is calculated the overall significance arithmetic of all described thread in described sampling time section Frequency.
Wherein in an embodiment, also include:
Logging modle, is used for recording the effective operation frequency of described entirety, and by effective for described entirety operation frequency As the historical record operation frequency that subsequent sampling times section is corresponding.
Wherein in an embodiment, the described historical record time period is the closer to described sampling time section, described Proportion shared by described time factor corresponding to historical record time period is the biggest.
Wherein in an embodiment, described first computing module includes:
First computing unit, for calculating described operation time period and the corresponding computing frequency of each described thread The product of rate, and the described product of each described thread is sued for peace, obtain the sum of products of each described thread;
Second computing unit, the operation time period of all described threads in calculating described sampling time section Time and;
Efficiently sampling operation frequency obtains module, for by described sum of products divided by the described time and, obtain each The efficiently sampling operation frequency of individual described thread.
The beneficial effect comprise that
The method and system of the above-mentioned operation frequency determining calculation resources, according to each line in each calculation resources In the operation time period of journey and corresponding calculation resources calculated sampling time section, each thread effectively adopts Sample operation frequency, compares traditional only using certain operation frequency once as the foundation of thread performance requirements, with Run the operation frequency of time period and correspondence thereof be according to the measures of effectiveness of each thread the most accurately and Reliably, it is possible to provide the measures of effectiveness of each thread exactly.
Accompanying drawing explanation
Fig. 1 is the schematic flow sheet of the method for the operation frequency of the determination calculation resources in an embodiment;
Fig. 2 is the record effect figure of the operation frequency running time period and correspondence of the thread in an embodiment;
Fig. 3 is the schematic flow sheet of the method for the operation frequency of the determination calculation resources in another embodiment;
Fig. 4 is the structural representation of the system of the operation frequency of the determination calculation resources in an embodiment.
Detailed description of the invention
In order to make the purpose of the present invention, technical scheme and advantage clearer, below in conjunction with accompanying drawing and reality The method and system executing the example operation frequency to present invention determine that calculation resources are further elaborated.Should Working as understanding, specific embodiment described herein only in order to explain the present invention, is not intended to limit the present invention.
In one embodiment, as shown in Figure 1, it is provided that the side of a kind of operation frequency determining calculation resources Method, the method comprises the following steps:
S100, in a sampling time section, obtains at least one thread and runs at least one calculation resources Run the time period and each runs operation frequency corresponding to time period.
S200, is calculated institute in sampling time section according to the described operation frequency running time period and correspondence State the efficiently sampling operation frequency of at least one thread.
According to described efficiently sampling operation frequency, S300, outside described sampling time section, determines that operation is described The operation frequency of the calculation resources of at least one thread.
In the present embodiment, in acquisition sampling time section, each thread is in the operation of one or more calculation resources Time period and each run operation frequency corresponding to time period, and by operation time period of each thread and operation Operation frequency corresponding to time period is recorded, finally according in each calculation resources during the operation of each thread Between the efficiently sampling computing frequency of each thread in section and corresponding calculation resources calculated sampling time section Rate.Efficiently sampling operation frequency according to each thread calculated can be good at reflecting each thread Performance requirements, compares traditional only using certain operation frequency once as the foundation of thread performance requirements, this reality It is the most accurate and reliable to the measures of effectiveness of each thread to execute in example, it is possible to provide each thread exactly Measures of effectiveness.Hereafter, operation at least one thread described is determined according to described efficiently sampling operation frequency The operation frequency of calculation resources so that calculation resources is provided that the usefulness being just met for described thread.
Wherein, the efficiently sampling operation frequency of each thread refers to just to meet the required effect of each thread The operation frequency of energy.Calculation resources include CPU (Central Processing Unit, CPU), GPU (Graphics Processing Unit, Graphics Processing Unit) and VPU (Video Processing Unit, Video processing unit).
It should be noted that each calculation resources can have more than one operation frequency, assume do not have in ideal In the case of loss, the output of the operation frequency the highest usefulness that it is provided is the best, but simultaneously required for power consumption The biggest.Thread is the ultimate unit taking calculation resources, can interrupt at any time and continue from the point of interruption Continuous execution, it is also possible to move freely in calculation resources, but the same time can only hold in a calculation resources OK, meanwhile, the same time, calculation resources also can only be run a worker thread.
Such as, as in figure 2 it is shown, obtaining the operation time period of each thread in sampling time section calculation resources And after the operation frequency of correspondence, by operation time period and the operation frequency record of correspondence thereof of each thread Get off.Specifically, in first 4 milliseconds shown in Fig. 2, the operation frequency of a calculation resources is 1500MHz, After its thread A has run 3 unit interval, switch to thread B and run, when thread B has run 1 After unit interval, operation frequency switches to 900MHz.In shown in Fig. 2 latter 8 milliseconds, thread B exists again Having run 3 unit interval under the operation frequency of 900MHz, switchback thread A has run 5 lists the most again Bit time.Detailed records the usefulness that each thread operates in each moment and used, it is simple to intuitively to often Individual thread is at measures of effectiveness sometime.It should be understood that when needed, it is also possible to record thread is at it Operation time period in his calculation resources and the operation frequency of correspondence thereof.Such as, latter 8 milliseconds in fig. 2 Afterwards, thread A moves to another calculation resources and runs, then continue according to the mode call wire shown in Fig. 2 Journey A runs time period and the operation frequency of correspondence thereof what this another calculation resources was run.
In conjunction with the example shown in Fig. 2, step S100 is described in detail: in a sampling time section, obtain Take operation time period and each operation time period pair that at least one thread runs at least one calculation resources The operation frequency answered specifically includes: obtain sampling time section, such as, shown 0~12 millisecond in Fig. 2 Sampling time section.In sampling time section, obtain at least one thread run at least one calculation resources The operation time period.Such as, in the sampling time section of shown in fig. 2 0~12 millisecond, obtain thread A The operation time period be 0~3 millisecond and 7~12 milliseconds, the operation time period of thread B be 3~4 milliseconds and 4~ 7 milliseconds.Obtain each and run operation frequency corresponding to time period.Such as, 0~3 shown in Fig. 2 millisecond Operation frequency corresponding to time period that run be 1500MHz, 3~4 milliseconds run computing corresponding to time period Frequency is 1500MHz, and the operation frequency corresponding to time period that run of 4~7 milliseconds is 900MHz, 7~12 The operation frequency that the operation time period of millisecond is corresponding is 900MHz.May be appreciated, it is also possible to obtain thread and exist Operation time period in other calculation resources and the operation frequency of correspondence thereof.Such as, in rear 7 shown in Fig. 2 After Hao Miao, thread A moves to another calculation resources and runs, then obtain thread A and provide in another computing That runs on source runs time period and the operation frequency of correspondence thereof.
Preferably, in one embodiment, step S200 includes:
S210, calculates the product running time period and corresponding operation frequency of each thread, and by each line The product summation of journey, obtains the sum of products of each thread.
S220, calculate all threads in sampling time section the time running the time period and.
S230, by sum of products divided by the time and, obtain the efficiently sampling operation frequency E of each thread.
By foregoing description, the efficiently sampling operation frequency of each thread is the operation time of each thread The sum of products that section and the summation of the product of corresponding operation frequency obtain is divided by the operation of threads all in sampling time section The time of time period and, the efficiently sampling operation frequency E of the most each thread can pass through formula
E = m T 1 × n T 1 + m T 2 × n T 2 + ... m T i × n T i m 1 + m 2 + ... m j
Obtain, wherein mTiRepresent that thread T operates in operation frequency nTiUnder the operation time, nTiExist for thread T mTiOperation frequency on this time period, mT1×nT1+mT2×nT2+…mTi×nTiRepresent that thread T is when sampling Between the sum of products running time period and corresponding operation frequency in section, m1+m2+…mjRepresent sampling time section In all threads the time running the time period and, wherein i≤j, i=1,2,3 ..., j=1,2,3 .... In this embodiment, the performance requirements of each thread is according to running time period and corresponding two parameters of operation frequency Obtain, compare traditional only using certain operation frequency once as the reference of thread measures of effectiveness, it is clear that More accurately with reliable, the performance requirements of each thread the most more can be reflected.
With the example shown in Fig. 2, above-described embodiment is described in detail: front 3ms is that thread A operates in Operation time period m under 1500MHzA1, this operation time period mA1Size is 3ms, this line of its correspondence The operation frequency n of journeyA1For 1500MHz;Rear 5ms is the operation time that thread A runs at 900 mhz Section mA2, this operation time period mA2Size be 5ms, the operation frequency n of this thread of its correspondenceA2For 900MHz.Computational threads A efficiently sampling operation frequency E=(1500 in sampling time section 0~12ms × 3+900 × 5)/(3+1+3+5)=750MHz.I.e. represent within these 12 unit interval, if computing In resource, only thread A runs, and it is required, i.e. that the operation frequency of calculation resources only needs 750MHz to meet Now the operation frequency 750MHz of calculation resources just disclosure satisfy that the usefulness needed for thread A, that is, After determining the efficiently sampling operation frequency of thread A, determine operation according to described efficiently sampling operation frequency The operation frequency of the calculation resources of thread A so that calculation resources is provided that the effect being just met for described thread A Energy.Hereafter, i.e. outside sampling time section, when thread A moves to run in other operation resources or continue When continuing operation in the calculation resources of its original, also determine active thread A according to above-mentioned efficiently sampling operation frequency The operation frequency of calculation resources, now, run if only having thread A in this calculation resources, then can be by it Operation frequency is set to 750MHz;When also having other threads to run, it is also necessary to take into account that the effective of other threads Sampled operational frequency, such as, when also thread B runs, then " according to described efficiently sampling operation frequency Determine the operation frequency of the calculation resources running described thread " the efficiently sampling operation frequency of thread A and B can be referred to Sum determines the operation frequency of calculation resources.
In one embodiment, seeing Fig. 3, the method also includes:
S400, is calculated in sampling time section institute according to the operation frequency running time period and correspondence wired The average sample operation frequency V of journey.
Wherein, the computing formula of average sample operation frequency is
Wherein, mjRepresenting that certain thread operates in operation frequency is njUnder the operation time period, njDuring for running Between section mjCorresponding operation frequency.
S500, obtains the historical record operation frequency H in the historical record time period before sampling time sectionNote And time factor D that historical record operation frequency is corresponding.
Historical record operation frequency is calculated within the historical record time period, is preserved note after obtaining Record, during acquisition, directly reads the most available from the memorizer preserving historical record operation frequency.Time because of Sub-D is that system automatically sets according to the degree remote of historical record time period, and certainly, time factor D is also Can be manually set.
What deserves to be explained is, time factor D is along with the historical record time period to the passage of sampling time section gradually Increase.I.e. the closer to the historical record time period of sampling time section, the proportion shared by the time factor of its correspondence Relative the biggest, further away from the historical record time period of sampling time section, shared by the time factor of its correspondence Proportion is the least, at this moment because the time period is the biggest closer to its performance requirements impact each other, in order to Can preferably assess the overall efficiency demand in sampling time section, introduce the history before this sampling time section Historical record operation frequency H in recording periodNoteAs foundation.
S600, according to average sample operation frequency V, historical record operation frequency HNoteAnd time factor D meter Calculate the overall effectively operation frequency H of all threads obtained in sampling time sectionAdopt
Wherein, in sampling time section, the computing formula of the overall effectively operation frequency of all threads is:
Hk+1=Vk+1*Dk+1+Dk*Hk+Dk-1*Hk-1+…+D1*H1
Wherein, Hk+1Overall effectively operation frequency H for all threads in sampling time sectionAdopt, for the ease of representing, It is denoted as H in this formulak+1, Vk+1Represent the average sample operation frequency V in sampling time section, for the ease of Represent, in this formula, be denoted as Vk+1。HkFor the 1st the historical record time period pair before sampling time section The historical record operation frequency answered, Hk-1Corresponding for the 2nd the historical record time period before sampling time section Historical record operation frequency ..., H1Corresponding for the kth historical record time period before sampling time section Historical record operation frequency, DkFor the 1st the historical record time period before sampling time section corresponding time Between the factor, Dk-1For the 2nd time factor that the historical record time period is corresponding before sampling time section ..., D1For the time factor that the kth historical record time period before sampling time section is corresponding.Dk+1For being more than In 0.5 numerical value less than or equal to 1, it can do corresponding variation according to the actual requirements, i.e. in sampling time section Weight shared by the time factor that average sample operation frequency is corresponding is maximum, overall in being because sampling time section Significance arithmetic frequency HAdoptIt is mainly with average sample operation frequency V as foundation.D1To DkAnd be less than In 0.5 more than or equal to 0, and the magnitude relationship between them is 1 >=Dk> Dk-1> ... > D1>=0, i.e. distance The time of sampling time section is the most remote, its interior historical record operation frequency HNoteIt is integrated with in sampling time section Effect operation frequency HAdoptImpact the least.Wherein, D1To Dk+1And be 1.
Preferably, in one embodiment, for easy computing, overall effectively operation frequency HAdoptCalculating public Formula can be reduced to HAdopt=V* (1-D)+D*H wherein, 1 >=D >=0.I.e. only with sampling time section it Before time factor corresponding to the most nearest historical record time period and historical record operation frequency calculate Overall effectively operation frequency HAdopt, when need not the performance requirements of thread is done exactly accurate assessment, above-mentioned Formula can meet the overall efficiency need assessment of thread in sampling time section.
In one embodiment, after step S600, also include:
S700, the overall effectively operation frequency H of recordk+1, during using effective for entirety operation frequency as subsequent sampling Between historical record operation frequency corresponding to section.
Overall effectively operation frequency H in calculating next sampling time sectionk+2Time, note can be directly read Overall effectively operation frequency in the present sample time period of record, meets in next sampling time section with this The overall efficiency need assessment of thread.
One of ordinary skill in the art will appreciate that all or part of flow process realizing in above-described embodiment method, Can be by computer program and complete to instruct relevant hardware, described program can be stored in a calculating In machine read/write memory medium, this program is upon execution, it may include such as the flow process of the embodiment of above-mentioned each method. Wherein, described storage medium can be magnetic disc, CD, read-only store-memory body (Read-Only Memory, Or random store-memory body (Random Access Memory, RAM) etc. ROM).
In one embodiment, as shown in Figure 4, a kind of operation frequency determining calculation resources is additionally provided System, this system includes: the first acquisition module 100, in a sampling time section, obtains at least one Thread run at least one calculation resources run the time period and each run the time period corresponding computing frequency Rate.First computing module 200, for being calculated according to the described operation frequency running time period and correspondence The efficiently sampling operation frequency of at least one thread described in sampling time section.Determine module 300, in institute State outside sampling time section, determine according to described efficiently sampling operation frequency and run at least one thread described The operation frequency of calculation resources.
In the present embodiment, provide according to operation time period and the corresponding computing of each thread in each calculation resources The efficiently sampling operation frequency of each thread in source calculated sampling time section, compares traditional only with certain Operation frequency once is as the foundation of thread performance requirements, to run the operation frequency of time period and correspondence thereof The most accurate and reliable to the measures of effectiveness of each thread for foundation, it is possible to provide each thread exactly Measures of effectiveness.Hereafter, operation at least one thread described is determined according to described efficiently sampling operation frequency The operation frequency of calculation resources so that calculation resources is provided that the usefulness being just met for described thread, computing provides The usefulness output in source both will not be too high, also will not be too low.
In one embodiment, this system also includes: the second computing module 400, for according to running the time period And the operation frequency of correspondence is calculated the average sample operation frequency of all threads in sampling time section.The Two acquisition modules 500, for obtaining the historical record computing in the historical record time period before sampling time section Frequency and time factor corresponding to described historical record operation frequency.3rd computing module 600, for according to flat The institute that all sampled operational frequency, historical record operation frequency and time factor are calculated in sampling time section There is the overall effectively operation frequency of thread.
In one embodiment, also include: logging modle 700, be used for recording overall effectively operation frequency, and Using effective for entirety operation frequency as historical record operation frequency corresponding to subsequent sampling times section.
In one embodiment, the described historical record time period is the closer to described sampling time section, described history Proportion shared by described time factor corresponding to recording period is the biggest.
In one embodiment, the first computing module 200 includes: the first computing unit 210, is used for calculating respectively The described operation time period of individual thread and the product of corresponding operation frequency, and by described in each described thread Product is sued for peace, and obtains the sum of products of each described thread.Second computing unit 220, is used for calculating the sampling time Section in all threads run the time period time and.Efficiently sampling operation frequency obtains module 230, and being used for will Sum of products divided by the time and, obtain the efficiently sampling operation frequency of each thread.
The principle of problem and the method phase of aforementioned a kind of operation frequency determining calculation resources is solved due to this system Seemingly, therefore the enforcement of this system may refer to the enforcement of preceding method, repeats no more in place of repetition.
Each technical characteristic of embodiment described above can combine arbitrarily, for making description succinct, the most right The all possible combination of each technical characteristic in above-described embodiment is all described, but, if these skills There is not contradiction in the combination of art feature, is all considered to be the scope that this specification is recorded.
Embodiment described above only have expressed the several embodiments of the present invention, and it describes more concrete and detailed, But can not therefore be construed as limiting the scope of the patent.It should be pointed out that, for this area For those of ordinary skill, without departing from the inventive concept of the premise, it is also possible to make some deformation and change Entering, these broadly fall into protection scope of the present invention.Therefore, the protection domain of patent of the present invention should be with appended power Profit requires to be as the criterion.

Claims (10)

1. the method for the operation frequency determining calculation resources, it is characterised in that described method includes:
In a sampling time section, obtain the operation that at least one thread runs at least one calculation resources Time period and each run operation frequency corresponding to time period;
It is calculated in described sampling time section according to the described described operation frequency running time period and correspondence The efficiently sampling operation frequency of at least one thread described;
Outside described sampling time section, determine described in operation at least one according to described efficiently sampling operation frequency The operation frequency of the calculation resources of individual thread.
The method of the operation frequency determining calculation resources the most according to claim 1, it is characterised in that Described method also includes:
It is calculated in described sampling time section according to the described described operation frequency running time period and correspondence The average sample operation frequency of all described threads;
The historical record operation frequency in the historical record time period before obtaining described sampling time section and described The time factor that historical record operation frequency is corresponding;
Calculate according to described average sample operation frequency, described historical record operation frequency and described time factor Obtain the overall effectively operation frequency of all described thread in described sampling time section.
The method of the operation frequency determining calculation resources the most according to claim 2, it is characterised in that Described calculate according to described average sample operation frequency, described historical record operation frequency and described time factor After obtaining the step of overall effectively operation frequency of all described thread in described sampling time section, also Including:
Record the effective operation frequency of described entirety;
Using effective for described entirety operation frequency as historical record operation frequency corresponding to subsequent sampling times section.
The method of the operation frequency determining calculation resources the most according to claim 2, it is characterised in that The described historical record time period the closer to described sampling time section, corresponding described of described historical record time period Proportion shared by time factor is the biggest.
5. according to the method for the operation frequency of the determination calculation resources described in any one of Claims 1-4, its Being characterised by, described being calculated according to the described described operation frequency running time period and correspondence is adopted described In the sample time period, the step of the efficiently sampling operation frequency of at least one thread described includes:
Calculate the described operation time period of each described thread and the product of corresponding operation frequency, and by each The described product summation of described thread, obtains the sum of products of each described thread;
In calculating described sampling time section all described threads run the time period time and;
By described sum of products divided by the described time and, obtain the described efficiently sampling computing frequency of each described thread Rate.
6. the system of the operation frequency determining calculation resources, it is characterised in that described system includes:
First acquisition module, in a sampling time section, obtains at least one thread and transports at least one Calculate the operation time period of operation in resource and the operation frequency that each operation time period is corresponding;
First computing module, for being calculated according to the described described operation frequency running time period and correspondence The efficiently sampling operation frequency of at least one thread described in described sampling time section;
Determine module, for outside described sampling time section, determine according to described efficiently sampling operation frequency Run the operation frequency of the calculation resources of at least one thread described.
The system of the operation frequency determining calculation resources the most according to claim 6, it is characterised in that Described system also includes:
Second computing module, for being calculated according to the described described operation frequency running time period and correspondence The average sample operation frequency of all described threads in described sampling time section;
Second acquisition module, for obtaining the history in the historical record time period before described sampling time section Record operation frequency and time factor corresponding to described historical record operation frequency;
3rd computing module, for according to described average sample operation frequency, described historical record operation frequency And described time factor is calculated the overall significance arithmetic of all described thread in described sampling time section Frequency.
The system of the operation frequency determining calculation resources the most according to claim 7, it is characterised in that Also include:
Logging modle, is used for recording the effective operation frequency of described entirety, and by effective for described entirety operation frequency As the historical record operation frequency that subsequent sampling times section is corresponding.
The system of the operation frequency determining calculation resources the most according to claim 7, it is characterised in that The described historical record time period the closer to described sampling time section, corresponding described of described historical record time period Proportion shared by time factor is the biggest.
10. according to the system of the operation frequency of the determination calculation resources described in any one of claim 6 to 9, It is characterized in that, described first computing module includes:
First computing unit, for calculating described operation time period and the corresponding computing frequency of each described thread The product of rate, and the described product of each described thread is sued for peace, obtain the sum of products of each described thread;
Second computing unit, the operation time period of all described threads in calculating described sampling time section Time and;
Efficiently sampling operation frequency obtains module, for by described sum of products divided by the described time and, obtain each The efficiently sampling operation frequency of individual described thread.
CN201610255067.9A 2016-04-21 2016-04-21 Method and system for determining operation frequency of operation resource Active CN105955823B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610255067.9A CN105955823B (en) 2016-04-21 2016-04-21 Method and system for determining operation frequency of operation resource

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610255067.9A CN105955823B (en) 2016-04-21 2016-04-21 Method and system for determining operation frequency of operation resource

Publications (2)

Publication Number Publication Date
CN105955823A true CN105955823A (en) 2016-09-21
CN105955823B CN105955823B (en) 2020-02-11

Family

ID=56914888

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610255067.9A Active CN105955823B (en) 2016-04-21 2016-04-21 Method and system for determining operation frequency of operation resource

Country Status (1)

Country Link
CN (1) CN105955823B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108153584A (en) * 2016-12-02 2018-06-12 百度在线网络技术(北京)有限公司 A kind of method and apparatus for being used to determine the Thread Count that destination network device need to distribute
WO2020211719A1 (en) * 2019-04-16 2020-10-22 阿里巴巴集团控股有限公司 Data acquisition method, apparatus and device

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1991687A (en) * 2005-12-29 2007-07-04 联想(北京)有限公司 Method for saving power consumption of processing unit
CN101466039A (en) * 2008-12-31 2009-06-24 中国科学院计算技术研究所 Device and method for decoding video
CN101699368A (en) * 2009-11-02 2010-04-28 中兴通讯股份有限公司 Method and device for adaptive dynamic frequency or voltage adjustment of CPU
CN101853066A (en) * 2009-02-11 2010-10-06 上海芯豪微电子有限公司 Method and device for automatically adjusting clock frequency of system in real time
CN101893927A (en) * 2009-05-22 2010-11-24 中兴通讯股份有限公司 Hand-held device power consumption management method
US20110047401A1 (en) * 2009-08-24 2011-02-24 Werner James B Providing Adaptive Frequency Control For A Processor
CN102915107A (en) * 2011-08-04 2013-02-06 联芯科技有限公司 Regulating method of power consumption of terminal as well as terminal
CN103019367A (en) * 2012-12-03 2013-04-03 福州瑞芯微电子有限公司 Embedded type GPU (Graphic Processing Unit) dynamic frequency modulating method and device based on Android system
CN105022686A (en) * 2015-07-17 2015-11-04 广州华多网络科技有限公司 Method and apparatus for determining CPU occupancy rate of process on android platform
CN105045369A (en) * 2015-06-19 2015-11-11 北京大学深圳研究生院 Dynamic CPU frequency adjustment method based on historical user-interaction information

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1991687A (en) * 2005-12-29 2007-07-04 联想(北京)有限公司 Method for saving power consumption of processing unit
CN101466039A (en) * 2008-12-31 2009-06-24 中国科学院计算技术研究所 Device and method for decoding video
CN101853066A (en) * 2009-02-11 2010-10-06 上海芯豪微电子有限公司 Method and device for automatically adjusting clock frequency of system in real time
CN101893927A (en) * 2009-05-22 2010-11-24 中兴通讯股份有限公司 Hand-held device power consumption management method
US20110047401A1 (en) * 2009-08-24 2011-02-24 Werner James B Providing Adaptive Frequency Control For A Processor
CN101699368A (en) * 2009-11-02 2010-04-28 中兴通讯股份有限公司 Method and device for adaptive dynamic frequency or voltage adjustment of CPU
CN102915107A (en) * 2011-08-04 2013-02-06 联芯科技有限公司 Regulating method of power consumption of terminal as well as terminal
CN103019367A (en) * 2012-12-03 2013-04-03 福州瑞芯微电子有限公司 Embedded type GPU (Graphic Processing Unit) dynamic frequency modulating method and device based on Android system
CN105045369A (en) * 2015-06-19 2015-11-11 北京大学深圳研究生院 Dynamic CPU frequency adjustment method based on historical user-interaction information
CN105022686A (en) * 2015-07-17 2015-11-04 广州华多网络科技有限公司 Method and apparatus for determining CPU occupancy rate of process on android platform

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108153584A (en) * 2016-12-02 2018-06-12 百度在线网络技术(北京)有限公司 A kind of method and apparatus for being used to determine the Thread Count that destination network device need to distribute
CN108153584B (en) * 2016-12-02 2021-11-09 百度在线网络技术(北京)有限公司 Method and equipment for determining number of threads to be allocated to target network equipment
WO2020211719A1 (en) * 2019-04-16 2020-10-22 阿里巴巴集团控股有限公司 Data acquisition method, apparatus and device

Also Published As

Publication number Publication date
CN105955823B (en) 2020-02-11

Similar Documents

Publication Publication Date Title
US10846521B2 (en) Gesture recognition system and gesture recognition method thereof
EP3703054B1 (en) Target voice detection method and apparatus
Chen et al. Embedded system real-time vehicle detection based on improved YOLO network
Hjort et al. Tests for constancy of model parameters over time
CN106933649B (en) Virtual machine load prediction method and system based on moving average and neural network
CN110047095A (en) Tracking, device and terminal device based on target detection
CN102853836B (en) Feedback weight fusion method based on track quality
US20220253214A1 (en) Data processing method, apparatus, device, and readable storage medium
CN105955823A (en) Method and system for determining operation frequency of computing resource
CN102247170B (en) Doppler imaging automatic optimization method
CN111191671A (en) Electrical appliance waveform detection method and system, electronic equipment and storage medium
CN109327334A (en) A kind of alarm method being directed to equipment performance, device and equipment
CN102546052B (en) Self-adaptive threshold controlling and parameter calculating and measuring technology and method
CN114742237A (en) Federal learning model aggregation method and device, electronic equipment and readable storage medium
JPH08171509A (en) Method and device for monitoring buffer
US20230350714A1 (en) Priority determination system, priority determination method, and recording medium
CN102034022B (en) Signal processing method and system based on frequency multiplication analysis
CN109003686A (en) Localization method, device, computer equipment and the storage medium of nuclear power station loosening part
CN112541464A (en) Method and device for determining associated road object, road side equipment and cloud control platform
CN106126841B (en) A kind of method and apparatus based on hardware frequency conversion
CN113743580A (en) Immunity detector training method
EP3992878B1 (en) Method and apparatus for processing wafer inspection task, system, and storage medium
CN112749013B (en) Thread load detection method and device, electronic equipment and storage medium
CN112751634B (en) Predictive burst signal monitoring frequency-cutting method and system
WO2021164028A1 (en) Method and apparatus for filling missing industrial longitudinal data

Legal Events

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