CN110209478A - A kind of heterogeneous polynuclear system on chip method for scheduling task and device - Google Patents
A kind of heterogeneous polynuclear system on chip method for scheduling task and device Download PDFInfo
- Publication number
- CN110209478A CN110209478A CN201910404125.3A CN201910404125A CN110209478A CN 110209478 A CN110209478 A CN 110209478A CN 201910404125 A CN201910404125 A CN 201910404125A CN 110209478 A CN110209478 A CN 110209478A
- Authority
- CN
- China
- Prior art keywords
- processor
- task
- allocation plan
- frequency
- total
- 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
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3234—Power saving characterised by the action undertaken
- G06F1/329—Power saving characterised by the action undertaken by task scheduling
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/32—Means for saving power
- G06F1/3203—Power management, i.e. event-based initiation of a power-saving mode
- G06F1/3234—Power saving characterised by the action undertaken
- G06F1/3296—Power saving characterised by the action undertaken by lowering the supply or operating voltage
-
- 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/48—Program initiating; Program switching, e.g. by interrupt
- G06F9/4806—Task transfer initiation or dispatching
- G06F9/4843—Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
- G06F9/4881—Scheduling strategies for dispatcher, e.g. round robin, multi-level priority queues
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Software Systems (AREA)
- Power Sources (AREA)
Abstract
The invention discloses a kind of heterogeneous polynuclear system on chip method for scheduling task, including: that selection is total executes time least processor, selection executes time least unallocated task on the processor, which is distributed to the maximum operating frequency that the processor obtains first task allocation plan and each processor;Each processor theory minimum frequency of operation and the second task allocation plan are obtained using convex optimized algorithm, the final working frequency of each processor is selected between the minimum frequency of operation and maximum operation frequency of each processor;Final task allocation plan is obtained by way of traversal.The invention also discloses a kind of heterogeneous polynuclear system on chip task scheduling apparatus, technical solution of the present invention reduces the number being iterated with convex optimized algorithm under the premise of guarantee system is generated close to least energy consumption, algorithm complexity is substantially reduced, the execution time of algorithm is reduced.
Description
Technical field
The invention belongs to field of computer architecture, and in particular to arrive a kind of heterogeneous polynuclear system on chip task schedule side
Method and device.
Background technique
With the continuous promotion of system on chip (referred to as, SoC) operational performance, energy consumption is also being increased rapidly." dynamic electric voltage
The whole energy consumption of the effectively save system on chip of frequency modulating technology " (referred to as, DVFS) energy, is widely used in industry.Embedding
Enter in formula real-time system, the SoC extensive utilization DVFS dispatching technique of heterogeneous polynuclear carries out task distribution.In the prior art, isomery
The SoC method for allocating tasks of multicore is broadly divided into two class schemes:
The first kind is the heuritic approach based on Global motion planning.Heuritic approach is first according to task on each processor
Average performance times carry out task order, task is then assigned to corresponding processor.This kind of algorithm possesses lower multiple
Miscellaneous degree, distribution time are shorter.But this kind of algorithm does not account for the isomery characteristic of processor, energy-saving effect is not ideal enough.
Second class is the optimization algorithm dispatched based on subregion.This kind of algorithm equally first arranges the execution time of task-set
Sequence solves allocation plan with optimum theory, then determines the allocation plan of first task, then updates optimization problem again
Solving optimization problem, determines the allocation plan of second task, is constantly iterated the distribution side for obtaining last whole tasks
Case.This method for allocating tasks it can be concluded that close to theoretical value system energy consumption, but its algorithm iteration is often, uses every time
Optimum theory complexity is larger, and algorithm execution time is longer, is not easy to solve real time tasks.
Summary of the invention
In order to solve the above-mentioned problems in the prior art, the present invention provides a kind of heterogeneous polynuclear system on chip tasks
Dispatching method and device reduce system energy consumption on the basis of reducing task allocation algorithms complexity to realize.
A kind of heterogeneous polynuclear system on chip method for scheduling task of the invention includes:
Each processor working frequency=processor highest frequency is set;
Selection is total to execute time least processor, and selection executes time least unallocated task on the processor,
The task is distributed into the processor;Obtain first task allocation plan;
To each processor, selection is so that the processor always executes the time most no more than task completion deadline D
Maximum operation frequency f of the small working frequency as the processorj max;
It calculates so that system total energy consumption EtotalThe smallest each task throughout manages the distribution desired value a on devicei *j:
If ai *jGreater than preset threshold value, task i is distributed into processor j;Obtain the second task allocation plan;
The minimum frequency of operation f of each processor is calculated according to the second task allocation planj min;
It is f that each processor working frequency, which is arranged,j min, traversal, which obtains, distributes task unallocated in the second task allocation plan
To all third task allocation plans of each processor;
In the fj minAnd fj maxBetween select the final working frequency f of each processorj final;The fj finalIt is deposited to meet
It is always executed at least one each processor and manages device minimum work frequency everywhere in the third task allocation plan that the time is all not more than D
Rate;
In the third task allocation plan that each processor always executes that the time is all not more than D, select total energy consumption minimum
A third task allocation plan as final task allocation plan;
The working frequency that each processor is arranged is the f of the processorj final;It is distributed according to the final task allocation plan
Each task gives each processor;
Wherein, the i is mission number, and i=1,2 ... ..., I, I is total task number amount;The j is processor number, j
=1,2 ..., J, J are processor total quantity;Total execution time of the processor is to distribute to each task of the processor to exist
The sum of execution time on the processor.
Further, the execution time of each task on the processor are as follows:
Wherein, fj workFor the working frequency that processor j is currently selected, the CiFor the worst execution period of task i;It is described
θi jFor execution efficiency of the task i on processor j.
Further, the selection is so that the processor always executes minimum of the time no more than task completion deadline D
Maximum operation frequency f of the working frequency as the processorj maxInclude:
The working frequency of each processor is reduced level-one by step 1.1;
Step 1.2, the total execution time for calculating each processor;
Step 1.3 is greater than D if there is total execution time of processor, by the upper level of current each processor working frequency
Working frequency is as fj max;If total execution time of each processor is all not more than D, return step one is executed.
Further, the traversal obtains the institute that unallocated task in the second task allocation plan is distributed to each processor
There is third task allocation plan:
Each unallocated task is sequentially allocated to each processor, J is obtainedKA third task allocation plan;
Wherein, K is the quantity of unallocated task in the second task allocation plan.
Further, described in the fj minAnd fj maxBetween select the final working frequency f of each processorj finalInclude:
The current working frequency f of step 2.1, each processor of settingj work=fj min;
Step 2.2, the total execution time for calculating each processor in each third task allocation plan;
If step 2.3, all third task allocation plans have processor always to execute the time greater than D;By each processor
Fj workLevel-one is improved, step 2.2 is executed;If there is total execution time of each processor is all not more than the third task distribution of D
F is arranged in schemej final=fj work。
A kind of heterogeneous polynuclear system on chip task scheduling apparatus of the invention includes:
Each processor is arranged most for selecting the maximum operation frequency of each processor in maximum operation frequency selecting module
Working frequency of the high-frequency as each processor, selects total execution time least processor, and selection executes on the processor
Time least unallocated task, distributes to the processor for the task;Obtain first task allocation plan;To each processing
Device selects so that the processor always executes maximum operation frequency of minimum frequency of operation of the time no more than D as the processor
fj max;
Minimum frequency of operation selecting module is calculated for selecting the minimum frequency of operation of each processor so that system total energy
Consume EtotalThe smallest each task throughout manages the distribution desired value a on devicei *jIf: ai *jGreater than preset threshold value Δ, will appoint
Business i distributes to processor j;The minimum frequency of operation f of each processor is calculated according to the second task allocation planj min;
Task allocating module, it is each for being selected between the minimum frequency of operation and maximum operation frequency of each processor
The final working frequency of processor;Final task allocation plan is obtained, it is f that each processor working frequency, which is arranged,j min, traversal obtains
Obtain all third task allocation plans that unallocated task in the second task allocation plan is distributed to each processor;Described
fj minAnd fj maxBetween select the final working frequency f of each processorj final;The fj finalFor meet there are at least one everywhere
Reason device always executes the time and is all not more than everywhere in the third task allocation plan of D and manages device minimum frequency of operation;In each processing
Device always executes the time and is all not more than in the third task allocation plan of D, selects total energy consumption the smallest third task distribution side
Case is as final task allocation plan;The working frequency that each processor is arranged is the f of the processorj final;According to described final
Allocation plan of being engaged in distributes each task to each processor;
Further, the maximum operation frequency selecting module includes:
First total execution time calculating unit, for calculating total execution time of each processor, comprising:
It calculates each task and throughout manages execution time t on devicei,j,
The distributing to each processor of the task is being executed into total execution of the sum of the time as each processor on processor
Time;
First task scheduling unit obtains first task allocation plan for each task to be assigned to each processor;Packet
Include: selection is total to execute time least processor, and selection executes time least unallocated task on the processor, by this
The processor is distributed in business;Repeat distribution of this step until completing all tasks;
First operating voltage optimizes unit, for the maximum operation frequency of each processor to be arranged, comprising:
First task scheduling unit carry out task distribution before, be arranged each processor working frequency be the processor most
Big frequency;
After first task scheduling unit completes task distribution, the working frequency of each processor is reduced step by step, until there is place
The total execution time for managing device is greater than D, using the upper level working frequency of current each processor working frequency as fj max;
Further, the minimum frequency of operation selecting module includes:
Optimization tool unit, for calculating so that system total energy consumption EtotalThe smallest each task throughout manages the distribution on device
Desired value ai *j;
Second task scheduling unit, for the distribution desired value ai *jIt makes decisions, obtains the second task distribution side
Case, comprising: judge that each task throughout manages the distribution desired value a on devicei *jWhether preset threshold value is greater than;If so, will appoint
Business i distributes to processor j, and second distribution coefficient a of the task i on processor j is arrangedi j=1;Otherwise, a is seti j=0;It obtains
Second task allocation plan.
Second operating voltage optimizes unit, for selecting the minimum frequency of operation of each processor, comprising:
Calculate the minimum frequency of operation desired value f of each processorj min_exp,
Throughout manage can selecting in selected frequency not less than f for devicej min_expMost unskilled labourer of the minimum frequency as the processor
Working frequency fj min。
Further, the task allocating module includes:
Second total execution time calculating unit, for calculating total execution time of each processor;
Third task scheduling unit, for obtaining third task allocation plan, comprising: be sequentially allocated each unallocated task
To each processor, J is obtainedKA third task allocation plan;Wherein, K is the number of unallocated task in the second task allocation plan
Amount;
Third operating voltage optimizes unit, for the final working frequency of each processor to be arranged, comprising: each processor is arranged
Current working frequency fj work=fj min;The total execution time for judging whether there is each processor is all not more than the third task point of D
With scheme, if so, setting fj final=fj work;Otherwise, by the f of each processorj workLevel-one is improved, whether rejudge has respectively
Total execution time of processor is all not more than the third task allocation plan of D, until obtaining always holding at least one each processor
The row time is all not more than the third task allocation plan of D, and f is arrangedj final=fj work;
Energy consumption calculation unit, total execution time for calculating each processor are all not more than the third task allocation plan of D
Energy consumption;
Final allocation plan selecting unit, according to the calculated each third task allocation plan of the energy consumption calculation unit institute
Energy consumption, select the smallest third task allocation plan of energy consumption as final task allocation plan.
Preferably, described first total time calculating unit and second total time calculating unit that executes of executing is same
Unit.
Technical solution of the present invention meets each of task execution time requirement by the acquisition of simple heuritic approach first
Then the maximum operation frequency of processor obtains each processor theory minimum frequency of operation using convex optimum theory, finally most
Obtain that meet energy consumption under task execution time requirement condition minimum by traversing between small working frequency and maximum operation frequency
The working frequency of final task allocation plan and each processor, the advantages of heuritic approach and convex optimized algorithm, is combined,
The number being iterated with convex optimized algorithm is reduced under the premise of guarantee system is generated close to least energy consumption, substantially reduces calculation
Method complexity reduces the execution time of algorithm.
Detailed description of the invention
Fig. 1 is 1 heterogeneous polynuclear system on chip method for scheduling task flow chart of the specific embodiment of the invention;
Fig. 2 is 2 heterogeneous polynuclear system on chip task scheduling apparatus structural schematic diagram of the specific embodiment of the invention;
Fig. 3 is 2 maximum operation frequency selecting module structural schematic diagram of the specific embodiment of the invention;
Fig. 4 is 2 minimum frequency of operation selecting module structural schematic diagram of the specific embodiment of the invention;
Fig. 5 is 2 task allocating module modular structure schematic diagram of the specific embodiment of the invention;
Fig. 6 is technical solution of the present invention and prior art task schedule time comparison diagram;
Fig. 7 is technical solution of the present invention and prior art task energy consumption comparison figure.
Specific embodiment
Technical solution in order to better illustrate the present invention with reference to the accompanying drawing carries out a specific embodiment of the invention
Detailed description.
In the following specific embodiments of the present invention, system on chip includes J processor, and the needing to distribute of the task has I, task
The deadline of execution is D;It is mutually indepedent between task, there is no the limitation successively executed between task and does not seize, Suo Youren
Business starts to discharge at same 0 moment of time point.Each processor can running frequency fj={ fj 1,fj 2,……,fj M, wherein j is
Processor number, M be processor can running frequency quantity, fj 1<fj 2<……<fj M。
I is mission number, and i=1,2 ... ..., I, I is total task number amount;CiFor the worst execution period of task i;θi jFor
Execution efficiency of the task i on processor j;The βjFor the framework coefficient of processor j, value be for processor design and
The relevant constant value of technique;Total execution time of processor is to distribute to the execution of each task of the processor on the processor
The sum of time.
Specific embodiment 1
The present embodiment is a kind of preferred embodiment of heterogeneous polynuclear system on chip method for scheduling task of the present invention.
Referring to Fig. 1, as shown in Figure 1, the method for the present embodiment includes:
S101, system electrification starting, a group task TASKiIt is assigned to system;
Device working frequency f is managed everywhere in S102, setting systemj work=fj M;
S103, each task of calculating throughout manage the execution time on device;
S104, the total execution time least processor of selection, it is least unallocated that selection executes the time on the processor
The task is distributed to the processor, obtains first task allocation plan by task;
This step may further include:
S1041, initialization first task allocation matrix A', it is 0 that each element value in A', which is arranged,;
S1042, selection one total execution time TjLeast processor j;
S1043, selection executes time least task TASK on processor j in unappropriated taski, distribute to place
Device j is managed, corresponding element in A' is set
S1044, total execution time=T that processor j is setj+ti j;
Step S1042~S1044 is repeated, until completing all task distribution, obtains first task allocation plan;
Wherein:
First task distribution coefficient,Task i is distributed to processor j by expression,Expression will not appoint
Business i distributes to processor j.
S105, to each processor, selection is so that the processor always executes minimum frequency of operation of the time no more than D and makees
For the maximum operation frequency f of the processorj max;
This step can be specifically included further:
S1051, the working frequency f by each processorj workReduce level-one;
S1052, the total execution time for judging whether there is processor are greater than D;
S1053, it is greater than D if there is total execution time of processor, by the upper level work of current each processor working frequency
Working frequency is as fj max, execute step S106;
If total execution time of S1054, each processor is all not more than D, step S1051 is executed.
S106, calculating are so that system total energy consumption EtotalThe smallest each task throughout manages the distribution desired value a on devicei *j;
In this step, ai *jCalculation method be according to following formula, to calculate so that EtotalThe smallest ai *j;
In this specific embodiment, this step can solve a using convex optimized algorithmi *j;It specifically can be used 2014
The paper that Hubei Engineering University's journal (the 3rd phase in 2014) that 06 day 08 month year published is published is " based on the tool box Yalmip
Integer programming model method for solving " disclosed in method, a is solved using Optimization Solution tool yalmipi *j, specific to count
The Formal Languages of the nonlinear optimization theory of calculation are as follows:
S107, judge each ai *jWhether preset threshold value Δ is greater than;If so, otherwise executing step S109 executes step
Rapid S108;
Wherein, the value range of the Δ is 0.6~0.9;
S108, task i is distributed to processor j, second task distribution coefficient a of the task i on processor j is seti j=
1;
The a of S109, setting task i on processor ji j=0;
Step S107~S109 is repeated until completing all ai *jJudgement, obtain the second task allocation plan matrix
A";
Task i is distributed to processor j by expression,Task i is not distributed to processor j by expression.
S110, the minimum frequency of operation desired value f for calculating each processorj min_exp;
S111, can selecting in running frequency not less than f for device is throughout managedj min_expMinimum frequency as the processor
Minimum frequency of operation fj min;
S112, each processor working frequency of setting are fj min, traversal obtains will be unallocated in the second task allocation plan
All third task allocation plans of each processor are distributed in business;
In the present embodiment, this step further comprises:
Unallocated task each in second task allocation plan is sequentially allocated to each processor, J is obtainedKA third task point
With scheme;Wherein, K is the quantity of unallocated task in the second task allocation plan.
To each unappropriated task in the second scenario, each processor is assigned them to respectively, obtains J third
Task allocation plan;To K unallocated tasks, amounts to and obtain JKA third task allocation plan.
S113, in the fj minAnd fj maxBetween select the final working frequency f of each processorj final;
The fj finalTo meet, there are the third task distribution that at least one each processor always executes the time and is all not more than D
Device minimum frequency of operation is managed everywhere in scheme;
This step may further include:
The current working frequency f of S1131, each processor of settingj work=fj min;
Each processor always executes the time in S1132, each third task allocation plan of calculating;
In this step, the calculation method that each processor always executes the time is identical with step S103, S104;
S1133, it judges whether there is each processor and always executes the third task allocation plan that the time is all not more than D;If so,
Step S1135 is executed, otherwise, executes step S1134;
S1134, by the f of each processorj workLevel-one is improved, step S1132 is executed;
S1135, setting fj final=fj work;
S114, in the third task allocation plan that each processor always executes that the time is all not more than D, select total energy consumption
A smallest third task allocation plan is as final task allocation plan;The working frequency that each processor is arranged is at this
Manage the f of devicej final;Each task is distributed into a processor according to the final task allocation plan.
Wherein, the total energy consumption of each third task allocation plan are as follows:
Wherein, the Etotal_mThe third task allocation plan that the time is all not more than D is always executed for m-th of each processor
Total energy consumption, m are the number that each processor always executes that the time is all not more than the third task allocation plan of D;am,i jEverywhere for m-th
Reason device always executes the time and is all not more than task TASK in the third task allocation plan of DiThird distribution coefficient, am,i j=1 indicates
Task i is distributed into processor j, am,i j=0 indicates that task i is not distributed to processor j.
Specific embodiment 2
The present embodiment is a kind of preferred implementation scheme of heterogeneous polynuclear system on chip task scheduling apparatus of the present invention.
Referring to fig. 2, as shown in Fig. 2, the device of the present embodiment includes:
Maximum operation frequency selecting module, for selecting the maximum operation frequency f of each processorj max, obtain first task
Allocation plan sends the fj maxWith the first task allocation plan to task allocating module;
Referring to Fig. 3, as shown in figure 3, maximum operation frequency selecting module may further include in the present embodiment:
First total execution time calculating unit, the work frequency of each processor is obtained from first operating voltage optimization unit
Rate fj work, calculate total execution time of each processor;The total execution time for sending each processor dispatches list to first task
Member;
The calculating includes:
It calculates each task and throughout manages execution time on device,
Calculate total execution time of each processor according to the execution time for the distributing to the processor of the task, processor it is total
Executing the time is to distribute to the sum of the execution time of each task of the processor on the processor;
First task scheduling unit, from described first total total execution time for executing time calculating unit and obtaining each processor
The execution time that device is throughout managed with each task obtains the maximum functional of each processor from first operating voltage optimization unit
Frequency fj max;Each task is assigned to each processor, obtains first task allocation plan;Send the fj maxWith it is described first
Allocation plan of being engaged in is to task allocating module;
The distribution includes:
Selection is total to execute time least processor, and selection executes time least unallocated task on the processor,
The task is distributed into the processor;Repeat distribution of this step until completing all tasks;
In the present embodiment, the specific tasks distribution method of this unit and the step S104 of specific embodiment 1 are identical, herein not
It repeats again.
First operating voltage optimizes unit and sends the work of each processor for the maximum operation frequency of each processor to be arranged
Working frequency always executes time calculating unit to described first;Each task is obtained each from described first total time calculating unit that executes
Total execution time of the execution time and each processor of processor;The maximum operation frequency of each processor is sent to described first
Business scheduling unit;
The maximum operation frequency of each processor of the setting includes:
First task scheduling unit carry out task distribution before, be arranged each processor working frequency be the processor most
Big frequency;
After first task scheduling unit completes task distribution, the working frequency of each processor is reduced step by step, until there is place
The total execution time for managing device is greater than D, using the upper level working frequency of current each processor working frequency as fj max。
In the present embodiment, the specific method of each processor maximum operation frequency and the step of specific embodiment 1 is arranged in this unit
Rapid S105 is identical, and details are not described herein.
Minimum frequency of operation selecting module, for selecting the minimum frequency of operation f of each processorj min, obtain the second task
Allocation plan sends the fj minWith the second task allocation plan to task allocating module;
Referring to fig. 4, as shown in figure 4, in the present embodiment, minimum frequency of operation selecting module be may further include:
Optimization tool unit, for calculating so that system total energy consumption EtotalThe smallest each task throughout manages the distribution on device
Desired value ai *j;Send ai *jTo the second task scheduling unit;
In the present embodiment, ai *jCalculation method be according to following formula, to calculate so that EtotalThe smallest ai *j;
In the present embodiment, this unit calculates ai *jSpecific method it is identical as the step S106 of specific embodiment 1, herein not
It repeats again.
Second task scheduling unit obtains a from the optimization tool uniti *j;To each ai *jIt makes decisions,
Obtain the second task allocation plan;The minimum frequency of operation f of each processor is obtained from the second operating voltage optimization unitj min;Hair
Send the minimum frequency of operation f of the second task allocation plan and each processorj minTo task allocating module;
In the present embodiment, the specific method that this unit obtains the second task allocation plan may include:
Judge that each task throughout manages the distribution desired value a on devicei *jWhether preset threshold value Δ is greater than;
If so, task i is distributed to processor j, second task distribution coefficient a of the task i on processor j is seti j
=1;Otherwise, a of the setting task i on processor ji j=0;Obtain the second task allocation plan.
Second operating voltage optimizes unit, obtains each second task distribution coefficient a from second task scheduling uniti j,
Select the minimum frequency of operation f of each processorj min;The minimum frequency of operation is sent to second task scheduling unit;
In the present embodiment, each processor minimum frequency of operation f of this Unit selectionj minSpecific method may include:
Calculate the minimum frequency of operation desired value f of each processorj min_exp,
Throughout manage can selecting in running frequency not less than f for devicej min_expMinimum of the minimum frequency as the processor
Working frequency fj min。
Task allocating module obtains first task allocation plan and each processor from the maximum operation frequency selecting module
Maximum operation frequency;The minimum of the second task allocation plan and each processor is obtained from the minimum frequency of operation selecting module
Working frequency;The final work of each processor is selected between the minimum frequency of operation and maximum operation frequency of each processor
Frequency;Obtain final task allocation plan;
Referring to Fig. 5, as shown in figure 5, task allocating module may further include in the present embodiment:
Second total execution time calculating unit, the working frequency of each processor is obtained from third operating voltage optimization unit;
It calculates each task and throughout manages execution time on device, calculate total execution time of each processor;Send always holding for each processor
The row time optimizes unit to third operating voltage;
In the present embodiment, this unit calculates that each task throughout manages execution time on device and each processor always executes the time
Specific method and first total execute that time calculating unit is identical, and details are not described herein.
Third task scheduling unit, from maximum operation frequency selecting module acquisition first task allocation plan and everywhere
Manage the maximum operation frequency of device;The second task allocation plan and each processor are obtained from the minimum frequency of operation selecting module
Minimum frequency of operation;Unappropriated task in the second task allocation plan is sequentially allocated to each processor, third is obtained
Task allocation plan;
In the present embodiment, the specific method that this unit obtains third task allocation plan includes:
To each unappropriated task in the second scenario, each processor is assigned them to respectively, obtains J third
Task allocation plan;To K unallocated tasks, amounts to and obtain JKA third task allocation plan.
Wherein, K is the quantity of unallocated task in the second task allocation plan;
Third operating voltage optimizes unit, and the minimum work frequency of each processor is obtained from the third task scheduling unit
Rate, the maximum operation frequency of each processor, each third task allocation plan;The final working frequency f of each processor is setj final;
In the present embodiment, the final working frequency that each processor is arranged in this unit is specifically included:
The current working frequency f of each processor is setj work=fj min;
The total execution time for judging whether there is each processor is all not more than the third task allocation plan of D, if so, setting
fj final=fj work;Otherwise, by the f of each processorj workLevel-one is improved, the total execution time for whether having each processor is rejudged
All it is not more than the third task allocation plan of D, total execution time until obtaining at least one each processor is all not more than the of D
F is arranged in three task allocation plansj final=fj work;
Energy consumption calculation unit obtains f from third operating voltage optimization unitj finalWhen with total execution of each processor
Between all be not more than D third task allocation plan, calculate each processor total execution time be all not more than D third task distribution
The energy consumption of scheme;
Wherein, the total energy consumption of third task allocation plan are as follows:
Wherein, the Etotal_mThe third task allocation plan that the time is all not more than D is always executed for m-th of each processor
Total energy consumption, m are the number that each processor always executes that the time is all not more than the third task allocation plan of D;am,i jEverywhere for m-th
Reason device always executes the time and is all not more than task TASK in the third task allocation plan of DiThird distribution coefficient, am,i j=1 indicates
Task i is distributed into processor j, am,i j=0 indicates that task i is not distributed to processor j.
Final allocation plan selecting unit, from the energy consumption calculation unit obtain each third task allocation plan energy consumption and
The f of each processorj final, selection, which meets each processor and always executes the time, is all not more than D and the smallest third task of energy consumption point
With scheme as final task allocation plan;Each processing is assigned the task to according to selected third task allocation plan
Device, the working frequency that each processor is arranged is the f of the processorj final。
As a kind of preferred implementation scheme of the present embodiment, described first total execution time calculating unit and described second is always
Executing time calculating unit can be the same unit.
The technical solution algorithm that the above embodiment of the present invention provides combines the excellent of optimum theory algorithm and heuritic approach
Point reduces the number being iterated with convex optimized algorithm under the premise of guarantee system is generated close to least energy consumption, drops significantly
Low algorithm complexity reduces the execution time of algorithm.As shown in fig. 6, technical solution of the present invention task execution time compares optimization
Theoretical algorithm averagely reduces about 89%, only higher than heuritic approach by about 7%.As shown in fig. 7, the energy conservation effect of technical solution of the present invention
Fruit promotes obvious, closer system energy consumption theoretially optimum value.
It should be noted that the above examples are only used to illustrate the technical scheme of the present invention and are not limiting, although referring to compared with
Good embodiment describes the invention in detail, those skilled in the art should understand that, it can be to skill of the invention
Art scheme is modified or replaced equivalently, and without departing from the objective and range of technical solution of the present invention, should all be covered at this
In the scope of the claims of invention.
Claims (10)
1. a kind of heterogeneous polynuclear system on chip method for scheduling task characterized by comprising
Each processor working frequency=processor highest frequency is set;
Selection is total to execute time least processor, and selection executes time least unallocated task on the processor, by this
Task distributes to the processor;Obtain first task allocation plan;
To each processor, selection is so that the processor always executes most unskilled labourer of the time no more than task completion deadline D
Maximum operation frequency f of the working frequency as the processorj max;
It calculates so that system total energy consumption EtotalThe smallest each task throughout manages the distribution desired value a on devicei *j:
If ai *jGreater than preset threshold value, task i is distributed into processor j;Obtain the second task allocation plan;
The minimum frequency of operation f of each processor is calculated according to the second task allocation planj min;
It is f that each processor working frequency, which is arranged,j min, traverse to obtain and distribute to unallocated task in the second task allocation plan respectively
All third task allocation plans of processor;
In the fj minAnd fj maxBetween select the final working frequency f of each processorj final;The fj finalExist extremely to meet
Few each processor always executes the time and is all not more than everywhere in the third task allocation plan of D and manages device minimum frequency of operation;
In the third task allocation plan that each processor always executes that the time is all not more than D, select total energy consumption the smallest by one
A third task allocation plan is as final task allocation plan;
The working frequency that each processor is arranged is the f of the processorj final;Each is distributed according to the final task allocation plan
It is engaged in each processor;
Wherein, the i is mission number, and i=1,2 ... ..., I, I is total task number amount;The j is that processor is numbered, j=1,
2 ..., J, J are processor total quantity;Total execution time of the processor is to distribute to each task of the processor at this
Manage the sum of the execution time on device.
2. the method according to claim 1, wherein the execution time of each task on the processor are as follows:
Wherein, fj workFor the working frequency that processor j is currently selected, the CiFor the worst execution period of task i;The θi jFor
Execution efficiency of the task i on processor j.
3. according to the method described in claim 2, it is characterized in that, the selection is so that the processor always executes the time and is not more than
Task completes maximum operation frequency f of the minimum frequency of operation of deadline D as the processorj maxInclude:
The working frequency of each processor is reduced level-one by step 1.1;
Step 1.2, the total execution time for calculating each processor;
Step 1.3 is greater than D if there is total execution time of processor, and the upper level of current each processor working frequency is worked
Frequency is as fj max;If total execution time of each processor is all not more than D, return step one is executed.
4. according to the method described in claim 2, it is characterized in that, traversal acquisition will not divide in the second task allocation plan
All third task allocation plans of each processor are distributed to task:
Each unallocated task is sequentially allocated to each processor, J is obtainedKA third task allocation plan;
Wherein, K is the quantity of unallocated task in the second task allocation plan.
5. according to the method described in claim 4, it is characterized in that, described in the fj minAnd fj maxBetween select each processor
Final working frequency fj finalInclude:
The current working frequency f of step 2.1, each processor of settingj work=fj min;
Step 2.2, the total execution time for calculating each processor in each third task allocation plan;
If step 2.3, all third task allocation plans have processor always to execute the time greater than D;By each processor
fj workLevel-one is improved, step 2.2 is executed;If there is total execution time of each processor is all not more than the third task distribution side of D
F is arranged in casej final=fj work。
6. a kind of heterogeneous polynuclear system on chip task scheduling apparatus characterized by comprising
The most high frequency of each processor is arranged for selecting the maximum operation frequency of each processor in maximum operation frequency selecting module
Working frequency of the rate as each processor, selects total execution time least processor, and selection executes the time on the processor
The task is distributed to the processor by least unallocated task;Obtain first task allocation plan;To each processor,
It selects so that the processor always executes maximum operation frequency of minimum frequency of operation of the time no more than D as the processor
fj max;
Minimum frequency of operation selecting module is calculated for selecting the minimum frequency of operation of each processor so that system total energy consumption
EtotalThe smallest each task throughout manages the distribution desired value a on devicei *jIf: ai *jGreater than preset threshold value Δ, by task i
Distribute to processor j;The minimum frequency of operation f of each processor is calculated according to the second task allocation planj min;
Task allocating module, for selecting each processing between the minimum frequency of operation and maximum operation frequency of each processor
The final working frequency of device;Final task allocation plan is obtained, it is f that each processor working frequency, which is arranged,j min, traversal incited somebody to action
Unallocated task distributes to all third task allocation plans of each processor in second task allocation plan;In the fj minWith
fj maxBetween select the final working frequency f of each processorj final;The fj finalTo meet, there are at least one each processor is total
The execution time is all not more than reason device minimum frequency of operation everywhere in the third task allocation plan of D;It is always held in each processor
The row time is all not more than in the third task allocation plan of D, select the smallest third task allocation plan of total energy consumption as
Final task allocation plan;The working frequency that each processor is arranged is the f of the processorj final;It is distributed according to the final task
Scheme distributes each task to each processor;
Wherein, the i is mission number, and i=1,2 ... ..., I, I is total task number amount;The j is that processor is numbered, j=1,
2 ..., J, J are processor total quantity;Total execution time of the processor is to distribute to each task of the processor at this
Manage the sum of the execution time on device.
7. device according to claim 6, which is characterized in that the maximum operation frequency selecting module includes:
First total execution time calculating unit, for calculating total execution time of each processor, comprising:
It calculates each task and throughout manages execution time t on devicei,j,
The distributing to each processor of the task is being executed into total execution time of the sum of the time as each processor on processor;
First task scheduling unit obtains first task allocation plan for each task to be assigned to each processor;It include: choosing
Total execution time least processor is selected, selection executes time least unallocated task on the processor, by the task point
The dispensing processor;Repeat distribution of this step until completing all tasks;
First operating voltage optimizes unit, for the maximum operation frequency of each processor to be arranged, comprising:
Before first task scheduling unit carries out task distribution, the working frequency that each processor is arranged is the maximum frequency of the processor
Rate;
After first task scheduling unit completes task distribution, the working frequency of each processor is reduced step by step, until there is processor
Total execution time be greater than D, using the upper level working frequency of current each processor working frequency as fj max;
Wherein, fj workFor the working frequency that processor j is currently selected, the CiFor the worst execution period of task i;The θi jFor
Execution efficiency of the task i on processor j.
8. device according to claim 7, which is characterized in that the minimum frequency of operation selecting module includes:
Optimization tool unit, for calculating so that system total energy consumption EtotalThe smallest each task throughout manages the expectation of the distribution on device
Value ai *j;
Second task scheduling unit, for the distribution desired value ai *jIt makes decisions, obtains the second task allocation plan, packet
It includes: judging that each task throughout manages the distribution desired value a on devicei *jWhether preset threshold value is greater than;If so, by task i points
Second distribution coefficient a of the task i on processor j is arranged in dispensing processor ji j=1;Otherwise, a is seti j=0;Obtain second
Task allocation plan.
Second operating voltage optimizes unit, for selecting the minimum frequency of operation of each processor, comprising:
Calculate the minimum frequency of operation desired value f of each processorj min_exp,
Throughout manage can selecting in selected frequency not less than f for devicej min_expMinimum work frequency of the minimum frequency as the processor
Rate fj min。
9. device according to claim 8, which is characterized in that the task allocating module includes:
Second total execution time calculating unit, for calculating total execution time of each processor;
Third task scheduling unit, for obtaining third task allocation plan, comprising: each unallocated task is sequentially allocated to each
Processor obtains JKA third task allocation plan;Wherein, K is the quantity of unallocated task in the second task allocation plan;
Third operating voltage optimizes unit, for the final working frequency of each processor to be arranged, comprising: it is current that each processor is arranged
Working frequency fj work=fj min;The total execution time for judging whether there is each processor is all not more than the third task distribution side of D
Case, if so, setting fj final=fj work;Otherwise, by the f of each processorj workLevel-one is improved, whether rejudge has each processing
Total execution time of device is all not more than the third task allocation plan of D, when obtaining total execution of at least one each processor
Between all be not more than D third task allocation plan, be arranged fj final=fj work;
Energy consumption calculation unit, total execution time for calculating each processor are all not more than the energy of the third task allocation plan of D
Consumption;
Final allocation plan selecting unit, according to the energy consumption calculation unit calculated each third task allocation plan energy
Consumption, selects the smallest third task allocation plan of energy consumption as final task allocation plan.
10. device according to claim 9, which is characterized in that described first total executes time calculating unit and described the
Two total time calculating units that execute are the same unit.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910404125.3A CN110209478B (en) | 2019-05-16 | 2019-05-16 | Heterogeneous multi-core system-on-chip task scheduling method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910404125.3A CN110209478B (en) | 2019-05-16 | 2019-05-16 | Heterogeneous multi-core system-on-chip task scheduling method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110209478A true CN110209478A (en) | 2019-09-06 |
CN110209478B CN110209478B (en) | 2021-03-12 |
Family
ID=67787350
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910404125.3A Active CN110209478B (en) | 2019-05-16 | 2019-05-16 | Heterogeneous multi-core system-on-chip task scheduling method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110209478B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110675088A (en) * | 2019-10-12 | 2020-01-10 | 北京航空航天大学 | Efficient division method for complex tasks of digital twin system |
CN111679897A (en) * | 2020-06-05 | 2020-09-18 | 重庆邮电大学 | Heterogeneous multi-core system-on-chip task allocation method and device |
CN112766781A (en) * | 2021-01-27 | 2021-05-07 | 重庆航凌电路板有限公司 | Production task allocation method and system for equipment |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20180143853A1 (en) * | 2016-11-18 | 2018-05-24 | Qualcomm Incorporated | Circuits and Methods Providing Core Scheduling in Response to Aging for a Multi-Core Processor |
CN108647099A (en) * | 2018-05-18 | 2018-10-12 | 华东师范大学 | A kind of controlled isomery MPSoC system task dispatching methods towards optimized throughput |
CN108733491A (en) * | 2018-05-15 | 2018-11-02 | 华东师范大学 | A kind of thermal sensing and low energy consumption method for scheduling task towards isomery MPSoC systems |
CN109582457A (en) * | 2017-09-29 | 2019-04-05 | 魏莹 | Network-on-chip heterogeneous multi-core system task schedule and mapping |
-
2019
- 2019-05-16 CN CN201910404125.3A patent/CN110209478B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20180143853A1 (en) * | 2016-11-18 | 2018-05-24 | Qualcomm Incorporated | Circuits and Methods Providing Core Scheduling in Response to Aging for a Multi-Core Processor |
CN109582457A (en) * | 2017-09-29 | 2019-04-05 | 魏莹 | Network-on-chip heterogeneous multi-core system task schedule and mapping |
CN108733491A (en) * | 2018-05-15 | 2018-11-02 | 华东师范大学 | A kind of thermal sensing and low energy consumption method for scheduling task towards isomery MPSoC systems |
CN108647099A (en) * | 2018-05-18 | 2018-10-12 | 华东师范大学 | A kind of controlled isomery MPSoC system task dispatching methods towards optimized throughput |
Non-Patent Citations (3)
Title |
---|
DAWEI LI AND JIE WU: "Minimizing Energy Consumption for Frame-Based Tasks on Heterogeneous Multiprocessor Platforms", 《IEEE TRANSACTIONS ON PARALLEL AND DISTRIBUTED SYSTEMS》 * |
刘亚秋等: "基于多核处理器的低能耗任务调度优化算法", 《沈阳工业大学学报》 * |
夏军等: "异构多核片上系统的帧任务节能分配算法", 《西安电子科技大学学报》 * |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110675088A (en) * | 2019-10-12 | 2020-01-10 | 北京航空航天大学 | Efficient division method for complex tasks of digital twin system |
CN110675088B (en) * | 2019-10-12 | 2020-10-09 | 北京航空航天大学 | Efficient division method for complex tasks of digital twin system |
CN111679897A (en) * | 2020-06-05 | 2020-09-18 | 重庆邮电大学 | Heterogeneous multi-core system-on-chip task allocation method and device |
CN112766781A (en) * | 2021-01-27 | 2021-05-07 | 重庆航凌电路板有限公司 | Production task allocation method and system for equipment |
Also Published As
Publication number | Publication date |
---|---|
CN110209478B (en) | 2021-03-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110209478A (en) | A kind of heterogeneous polynuclear system on chip method for scheduling task and device | |
CN106155791B (en) | A kind of workflow task dispatching method under distributed environment | |
Shi et al. | Empirical evaluation of vector bin packing algorithms for energy efficient data centers | |
CN101719081B (en) | Method for scheduling virtual machines | |
Rubrico et al. | Online rescheduling of multiple picking agents for warehouse management | |
Sun et al. | PACO: A period ACO based scheduling algorithm in cloud computing | |
CN105446816B (en) | A kind of energy optimization dispatching method towards heterogeneous platform | |
CN104657221A (en) | Multi-queue peak-alternation scheduling model and multi-queue peak-alteration scheduling method based on task classification in cloud computing | |
CN104536803A (en) | Virtual machine scheduling method based on combination optimization | |
CN107704069B (en) | Spark energy-saving scheduling method based on energy consumption perception | |
CN104023042B (en) | Cloud platform resource scheduling method | |
CN106951059A (en) | Based on DVS and the cloud data center power-economizing method for improving ant group algorithm | |
Pan et al. | A new imperialist competitive algorithm for multiobjective low carbon parallel machines scheduling | |
CN103823718A (en) | Resource allocation method oriented to green cloud computing | |
Koo | The use of bucket brigades in zone order picking systems | |
CN108665092A (en) | A kind of whole process scheduled production and optimization method based on mixing glowworm swarm algorithm | |
CN114816699A (en) | Data center job scheduling method and system based on temperature prediction | |
Brachmann et al. | The impact of flexibility on engineer-to-order production planning | |
CN108429784A (en) | A kind of cloud resource distribution of energy efficiency priority and dispatching method | |
Wu et al. | Solving the planning and scheduling problem simultaneously in a hospital with a bi-layer discrete particle swarm optimization | |
CN107274135A (en) | The raw tobacco material overall planning method and system shared based on cooperative information | |
CN107423134A (en) | A kind of dynamic resource scheduling method of large-scale calculations cluster | |
CN112990624A (en) | Task allocation method, device, equipment and storage medium | |
CN105976052A (en) | Improved quantum-behaved particle swarm optimization algorithm-based multi-region economic dispatch method | |
CN106096818A (en) | A kind of generation method and apparatus of hydrogen resources scheduling scheme |
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 | ||
TR01 | Transfer of patent right |
Effective date of registration: 20230802 Address after: Room 2605, 26th Floor, Building 2C, Wangjing SOHO Tower, Wangjing Street, Chaoyang District, Beijing, 100102 Patentee after: Beijing Xinguang Microelectronics Technology Co.,Ltd. Address before: 400065 Chongwen Road, Nanshan Street, Nanan District, Chongqing Patentee before: CHONGQING University OF POSTS AND TELECOMMUNICATIONS |
|
TR01 | Transfer of patent right |