CN101697140A - Optimized dispatching method of operating system - Google Patents
Optimized dispatching method of operating system Download PDFInfo
- Publication number
- CN101697140A CN101697140A CN200910186336A CN200910186336A CN101697140A CN 101697140 A CN101697140 A CN 101697140A CN 200910186336 A CN200910186336 A CN 200910186336A CN 200910186336 A CN200910186336 A CN 200910186336A CN 101697140 A CN101697140 A CN 101697140A
- Authority
- CN
- China
- Prior art keywords
- cpu usage
- operating system
- timeslice
- increment
- cpu
- 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.)
- Pending
Links
Images
Landscapes
- Debugging And Monitoring (AREA)
Abstract
The invention discloses an optimized dispatching method of an operating system, which comprises the following steps: running an application program or software and dividing the application program or software into a plurality of execution units; distributing a plurality of running time slices to each execution unit by the operating system; detecting the occupancy rate of a CPU in real time and computing the occupancy rate increments of the CPU in various time ranges defined by the invention and rational function values which take the increments as independent variables; setting a threshold value; and by comparing the rational function values of the occupancy rate increments of the CPU in a time period with the threshold value, distributing follow-up running time slices to each running unit according to a certain regulation by the operating system. The invention adopts the CPU occupancy rate as a perceive parameter to more directly and quickly reflect the thermal failure degree of a CPU chip; in addition, the invention has shorter delay or reaction time and more stable temperature fluctuation and fully considers the function, the speed, the efficiency, the temperature and the reliability of a computer.
Description
Technical field
The present invention relates to the Optimization Dispatching method of operating system.
Background technology
Along with the application of computer technology is constantly expanded, the issue of ASIC thermal failure of microprocessor CPU chip highlights day by day, mainly contains two kinds of solution routes at present.A kind of is heat-sinking capability and the effect that improves chip from external hardware.Another kind is with software and hardware combining, mainly is that (sacrificing computer run speed and efficient is cost for DynamicalThermal Management, DTM) technology, and it is not overheated to exchange cpu chip for by dynamic thermal management.
That the heat dissipation technology of hardware view comprises is air-cooled, water-cooled, encapsulation, heat pipe, microchannel, conductor refrigeration, thermion refrigeration, and the chip carrier socket design or the like.The advantage of this approach is an instant effect, but is subjected to the restriction of production cost, noise and additional power consumption, and technical development near limit.The dynamic heat management techniques of DTM mainly refers to according to the cpu chip temperature value, take corresponding frequency reducing, step-down, clock gate, switching working mode, cut-out or some parts of dormancy, close measure such as some function, and get and refer to and carry out technology such as bandwidth valve, instruction delay groove.The advantage of this approach is that cost is low, and shortcoming is to take effect slow and cause computer function to reduce.
Afterwards, at the deficiency of DTM technology, a kind of approach of optimized distribution chip dissipated power of pure in house software is opened up out gradually.Wherein, up-to-date technology is the operating system multithread scheduling strategy of a class based on cpu chip temperature/power, promptly relies on operating system optimization to divide the dissipated power of distribution chip.Operating system is as the main effector of cpu resource, its process scheduling strategy directly determines CPU handling capacity and loading condition, and the dissipated power of optimized distribution chip, it is exactly the operation period by rational management and each thread of distribution, make CPU under the nondecreasing prerequisite of total efficiency, the dissipated power minimum of generation.
Temperature/power-aware strategy with the cpu chip temperature as perception amount, i.e. control variable.But temperature only is the indirect reflection amount of cpu chip thermal failure degree, is that the quality of the scheduling strategy of perception amount obviously is defective with it, on the one hand the reaction time long, the temperature fluctuation amplitude is bigger when regulating on the other hand.
Summary of the invention
The technical problem to be solved in the present invention is: provide a kind of ratio more direct and do not have an operating system optimization dispatching method of time lag as the perception amount with temperature/power, more direct, react the thermal failure degree of cpu chip more quickly, delay or reaction time are shorter, temperature fluctuation is more steady, reaches comprehensively the taking into account of function, speed, efficient and temperature, reliability of computing machine.
Technical scheme of the present invention is: a kind of Optimization Dispatching method of operating system comprises the steps:
Step 1: move an application program or software, this application program or software are divided into several operation unit, establishing x unit is Px, 1≤x≤N wherein, and N is a positive integer;
Step 2: the timeslice of operating system is designated as t successively
1, t
2, t
3..., t
n, with t
iAnd t
jTime span between the timeslice is called the time period, and is designated as t
Ij, special, time period t
IjBe timeslice t
iTime span, 1≤i wherein, j≤n, n are positive integer;
Step 3: detect CPU usage in real time and calculate each timeslice interior CPU usage increment and time period t
IjThe CPU usage increment, and these increments are handled;
Step 4: computing method and disposal route according to the CPU usage increment of setting preestablish the threshold value Th of the positive number of a correspondence as the CPU usage increment processing costs of certain length time period;
Step 5: if the processing costs that detects sometime the CPU usage increment in the section is during greater than threshold value, the unit Px of new operation in this time period is carried out mark, and execution in step 6; If do not surpass threshold value, then do not do subsequent step, get back to step 3;
Step 6: operating system surpasses the degree of threshold value according to CPU usage increment processing costs, redistributes the quantity of follow-up working time of sheet in the operation unit each, gets back to step 3 then and continues to carry out.
More detailed technical scheme of the present invention is:
Described operation unit can be thread, process or a program segment.
Described timeslice t
iThe computing method of interior CPU usage increment are t
iThe CPU usage of the finish time and t
iThe difference of the CPU usage of the zero hour.
Described time period t
IjThe computing method of interior CPU usage increment are following any or wherein combination of some kinds:
1) is t
jThe CPU usage of the finish time and t
iThe difference of the CPU usage of the zero hour;
2) be t
iAnd t
jBetween the arithmetic mean of CPU usage increment of some or all of timeslice;
3) be t
iAnd t
jBetween the root-mean-square value of CPU usage increment of some or all of timeslice;
4) be t
iAnd t
jBetween the variance of CPU usage increment of some or all of timeslice;
5) be t
iAnd t
jBetween the standard deviation of CPU usage increment of some or all of timeslice;
The disposal route of in the step 3 described CPU usage increment being handled is: with the CPU usage increment of part or all of timeslice, and/or the CPU usage increment in the time period carries out continuous or discrete rational function computing as independent variable.
The computing method of selected CPU usage increment are different with disposal route in the step 3, the value difference that the threshold value in the step 4 is also set thereupon.
Described operating system redistributes the timeslice quantity of follow-up operation for each in the operation unit, should follow following principle: the follow-up operation timeslice that the unit of the new operation that is labeled is assigned with reduces
Advantage of the present invention is:
1. reflection cpu chip thermal failure degree is more direct, quicker;
2. postpone or the reaction time shorter, instant effect;
3. temperature value is more steady, and the temperature fluctuation amplitude is littler, and temperature shock is littler;
4. reach comprehensively the taking into account of function, speed, efficient and temperature, reliability of computing machine;
5. cost is low.
Description of drawings
Below in conjunction with drawings and Examples the present invention is further described:
Fig. 1 is the temperature-time chart of cpu chip work.
Wherein: 1 does not adopt the temperature-time curve of cpu chip of the dispatching method of present embodiment; Temperature-the time curve of the cpu chip behind the dispatching method of 2 employing present embodiments.
Embodiment
Embodiment: present embodiment adopts the perception amount of the CPU usage (CPUusage rate) of reflection cpu chip crash rate degree as dispatching method of the present invention.
The Optimization Dispatching method of the operating system of present embodiment comprises the steps:
(1) application program of operation or software are divided into several operation unit with this application program or software, and each unit can be a thread, a process or a program segment, and establishing x unit is Px, 1≤x≤N wherein, and N is a positive integer.
(2) timeslice of operating system is designated as t successively
1, t
2, t
3..., t
n, with t
iAnd t
jTime span between the timeslice is called the time period, and is designated as t
Ij, special, time period t
IjBe timeslice t
iTime span, 1≤i wherein, j≤n, n are positive integer.
(3) detect CPU usage and calculate CPU usage increment and time period t in each timeslice in real time
IjThe CPU usage increment, and the increment of resulting multiple CPU usage handled computing.
Wherein, timeslice t
iThe computing method of interior CPU usage increment are t
iThe CPU usage of the finish time and t
iThe difference of the CPU usage of the zero hour.
Time period t
IjThe computing method of interior CPU usage increment are following any or wherein combination of some kinds:
1) is t
jThe CPU usage of the finish time and t
iThe difference of the CPU usage of the zero hour;
2) be t
iAnd t
jBetween the arithmetic mean of CPU usage increment of some or all of timeslice;
3) be t
iAnd t
jBetween the root-mean-square value of CPU usage increment of some or all of timeslice;
4) be t
iAnd t
jBetween the variance of CPU usage increment of some or all of timeslice;
5) be t
iAnd t
jBetween the standard deviation of CPU usage increment of some or all of timeslice;
The disposal route that the increment of described multiple CPU usage is handled is: with the CPU usage increment is independent variable, carries out continuous or discrete rational function computing.Here the CPU usage increment as independent variable is meant the CPU usage increment of part or all of timeslice or the CPU usage increment in the time period, or the combination of the CPU usage increment of part or all of timeslice and the CPU usage increment in the time period.
(4) according to the computing method of the CPU usage increment of setting, preestablish the threshold value Th of the positive number of a correspondence as the CPU usage increment processing costs of certain length time period.The computing method of selected CPU usage increment are different with disposal route in the step (3), and threshold value is also set different values thereupon.
Threshold value generally can be drawn by analysis by a large amount of experiments.The length of the time period of detecting and the selection of threshold size are determined according to experiment experience.If CPU usage increment processing costs is less than or equal to threshold value in the time period, illustrate that CPU usage does not increase or recruitment does not transfinite, operating system does not need to adjust; If when CPU usage increment processing costs is greater than threshold value in the time period, illustrate that the recruitment of CPU usage is excessive, the temperature of the cpu chip that can cause is too high, power or heat are excessive, and operating system need adjust.
(5) if detect when section interior CPU usage increment processing costs is greater than threshold value sometime, the new unit Px that moves in this time period is carried out mark, and continue the following step of execution; If do not surpass threshold value, then do not carry out subsequent step, get back to step (3) and continue to detect in real time.
(6) operating system surpasses the degree of threshold value according to CPU usage increment size processing costs, redistribute the quantity of follow-up working time of sheet for each unit, promptly redefine each relative scale, and then get back to step (3) and continue to detect in real time in the sheet quantity working time of operation unit.
Operating system give each redistribute in the operation unit working time sheet quantity and the method for relative scale can be the following inversely prroportional relationship method or the method for its distortion:
The inversely prroportional relationship method: for example measure CPU usage increment in the time period and be threshold value 5 times, then next operating system sheet quantity working time of distributing to the unit of the new operation that is labeled is 1/5 of its original timeslice quantity.4/5 sheet working time that the unit of the new operation that is labeled is cut down can take the circumstances into consideration to give remaining element or be dropped.Operating system redistributes the timeslice quantity of follow-up operation for each in the operation unit, follow following principle: the follow-up operation timeslice that the unit of the new operation that is labeled is assigned with must reduce, and is less than the timeslice quantity of its original distribution.
As shown in Figure 1, be the temperature-time chart of cpu chip work.Temperature-the time curve of curve 2 cpu chip after for the dispatching method that adopts present embodiment.At t
2Constantly, the CPU usage increment does not surpass threshold value, does not therefore deal with, and computer temperature rises.At t
2Constantly, find that the value of CPU usage increment after rational function is handled surpasses threshold value, then operating system begins to use the dispatching method of present embodiment, adjust carrying out of task, the occupancy of CPU is fallen, thereby prevented the lasting rising of cpu chip temperature, made temperature remain on CPU and work below the metastable temperature, taken into account function, speed and the efficient of computing machine simultaneously.If do not adopt the dispatching method of present embodiment, then can image curve 1 the same, the temperature of cpu chip continues to rise.
The above only is the preferred embodiments of the present invention, can not limit scope of the invention process with this, and all simple conversion of doing according to claim of the present invention and description all should still belong to the protection domain that the present invention covers.
Claims (7)
1. the Optimization Dispatching method of an operating system is characterized in that comprising the steps:
Step 1: move an application program or software, this application program or software are divided into several operation unit, establishing x unit is Px, 1≤x≤N wherein, and N is a positive integer;
Step 2: the timeslice of operating system is designated as t successively
1, t
2, t
3..., t
n, with t
iAnd t
jTime span between the timeslice is called the time period, and is designated as t
Ij, special, time period t
IiBe timeslice t
iTime span, 1≤i wherein, j≤n, n are positive integer;
Step 3: detect CPU usage in real time and calculate interior CPU usage increment of each timeslice and the CPU usage increment of time period, and these increments are handled;
Step 4: computing method and disposal route according to the CPU usage increment of setting preestablish the threshold value Th of the positive number of a correspondence as the CPU usage increment processing costs of certain length time period;
Step 5: if the processing costs that detects sometime the CPU usage increment in the section is during greater than threshold value, the unit Px of new operation in this time period is carried out mark, and execution in step 6; If do not surpass threshold value, then do not do step 6, continue execution in step 3;
Step 6: operating system surpasses the degree of threshold value according to CPU usage increment processing costs, redistributes the quantity of follow-up working time of sheet in the operation unit each, gets back to step 3 then and continues to carry out.
2. according to the Optimization Dispatching method of the operating system described in the claim 1, it is characterized in that: described operation unit can be thread, process or a program segment.
3. according to the Optimization Dispatching method of the operating system described in the claim 1, it is characterized in that: described timeslice t
iThe computing method of interior CPU usage increment are t
iThe CPU usage of the finish time and t
iThe difference of the CPU usage of the zero hour.
4. according to the Optimization Dispatching method of the operating system described in the claim 1, it is characterized in that described time period t
IjThe computing method of interior CPU usage increment are following any or wherein combination of some kinds:
1) is t
jThe CPU usage of the finish time and t
iThe difference of the CPU usage of the zero hour;
2) be t
iAnd t
jBetween the arithmetic mean of CPU usage increment of some or all of timeslice;
3) be t
iAnd t
jBetween the root-mean-square value of CPU usage increment of some or all of timeslice;
4) be t
iAnd t
jBetween the variance of CPU usage increment of some or all of timeslice;
5) be t
iAnd t
jBetween the standard deviation of CPU usage increment of some or all of timeslice;
5. according to the Optimization Dispatching method of the operating system described in the claim 1, it is characterized in that:
The disposal route of in the step 3 described CPU usage increment being handled is: with the CPU usage increment of part or all of timeslice, and/or the CPU usage increment in the time period carries out continuous or discrete rational function computing as independent variable.
6. according to the Optimization Dispatching method of the operating system described in the claim 1, it is characterized in that: the computing method of selected CPU usage increment are different with disposal route in the step 3, the value difference that the threshold value in the step 4 is also set thereupon.
7. according to the Optimization Dispatching method of the operating system described in the claim 1, it is characterized in that: described operating system redistributes the timeslice quantity of follow-up operation for each in the operation unit, should follow following principle: the follow-up operation timeslice that the unit of the new operation that is labeled is assigned with reduces.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200910186336A CN101697140A (en) | 2009-10-22 | 2009-10-22 | Optimized dispatching method of operating system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200910186336A CN101697140A (en) | 2009-10-22 | 2009-10-22 | Optimized dispatching method of operating system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN101697140A true CN101697140A (en) | 2010-04-21 |
Family
ID=42142245
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN200910186336A Pending CN101697140A (en) | 2009-10-22 | 2009-10-22 | Optimized dispatching method of operating system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101697140A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102156666A (en) * | 2011-04-20 | 2011-08-17 | 上海交通大学 | Temperature optimizing method for resource scheduling of coarse reconfigurable array processor |
CN104298711A (en) * | 2014-09-12 | 2015-01-21 | 百度在线网络技术(北京)有限公司 | Method and device for scanning information to be scanned and computer equipment |
CN106033345A (en) * | 2015-03-17 | 2016-10-19 | 阿里巴巴集团控股有限公司 | Method and device for controlling CPU utilization rate |
CN115327252A (en) * | 2022-06-27 | 2022-11-11 | 上海轩田工业设备有限公司 | High-low temperature microwave performance test scheduling optimization method and system |
-
2009
- 2009-10-22 CN CN200910186336A patent/CN101697140A/en active Pending
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102156666A (en) * | 2011-04-20 | 2011-08-17 | 上海交通大学 | Temperature optimizing method for resource scheduling of coarse reconfigurable array processor |
CN102156666B (en) * | 2011-04-20 | 2012-11-28 | 上海交通大学 | Temperature optimizing method for resource scheduling of coarse reconfigurable array processor |
CN104298711A (en) * | 2014-09-12 | 2015-01-21 | 百度在线网络技术(北京)有限公司 | Method and device for scanning information to be scanned and computer equipment |
US9723020B2 (en) | 2014-09-12 | 2017-08-01 | Baidu Online Network Technology (Beijing) Co., Ltd. | Method, apparatus and computer device for scanning information to be scanned |
US9971892B2 (en) | 2014-09-12 | 2018-05-15 | Baidu Online Network Technology (Beijing) Co., Ltd. | Method, apparatus and computer device for scanning information to be scanned |
CN106033345A (en) * | 2015-03-17 | 2016-10-19 | 阿里巴巴集团控股有限公司 | Method and device for controlling CPU utilization rate |
CN106033345B (en) * | 2015-03-17 | 2019-06-11 | 阿里巴巴集团控股有限公司 | The control method and device of CPU usage |
CN115327252A (en) * | 2022-06-27 | 2022-11-11 | 上海轩田工业设备有限公司 | High-low temperature microwave performance test scheduling optimization method and system |
CN115327252B (en) * | 2022-06-27 | 2023-08-08 | 上海轩田工业设备有限公司 | High-low temperature microwave performance test scheduling optimization method and system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP1612649B1 (en) | Method and apparatus for energy efficiency in an integrated circuit | |
US7464278B2 (en) | Combining power prediction and optimal control approaches for performance optimization in thermally limited designs | |
US7529874B2 (en) | Semiconductor integrated circuit device for real-time processing | |
US20160378570A1 (en) | Techniques for Offloading Computational Tasks between Nodes | |
CN102878102B (en) | Speed adjustment processing method and device of fan | |
KR20060064438A (en) | Power management method for platform and that platform | |
CN102483646A (en) | Altering Performance Of Computational Units Heterogeneously According To Performance Sensitivity | |
CN1497406A (en) | Method and device for executing effective power throttle | |
CN104571439A (en) | Heat dissipation power consumption optimization regulation and control method compatible with environment temperature speed regulation | |
CN101697140A (en) | Optimized dispatching method of operating system | |
US9891700B2 (en) | Power management for datacenter power architectures | |
WO2022099477A1 (en) | Power consumption control method and device | |
Xiang et al. | Run-time management for multicore embedded systems with energy harvesting | |
Shoukourian et al. | Power variation aware configuration adviser for scalable HPC schedulers | |
CN104074784A (en) | Fan control system and method | |
CN102184005B (en) | Method and device for regulating dynamic voltages and frequencies | |
EP3816769B1 (en) | Method and system for controlling peak power consumption | |
CN200969053Y (en) | Power supply apparatus having intelligent type cooling control function | |
CN101685335A (en) | Application server based on SEDA as well as energy-saving device and method thereof | |
CN105159815A (en) | Fault prediction method and device of high-performance computing cluster system | |
CN116627237A (en) | Power management chip architecture system based on core chip | |
CN107341060B (en) | Virtual machine memory allocation method and device | |
CN113453504B (en) | Control method and system for power grid friendly data center refrigerating system | |
CN109472408A (en) | A kind of thermal power generation unit cold end management pad optimization regulating system | |
EP1405171A1 (en) | Method and apparatus to use task priority to scale processor performance |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C02 | Deemed withdrawal of patent application after publication (patent law 2001) | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20100421 |