CN1818875A - Grouped hard realtime task dispatching method of built-in operation system - Google Patents
Grouped hard realtime task dispatching method of built-in operation system Download PDFInfo
- Publication number
- CN1818875A CN1818875A CN 200610049874 CN200610049874A CN1818875A CN 1818875 A CN1818875 A CN 1818875A CN 200610049874 CN200610049874 CN 200610049874 CN 200610049874 A CN200610049874 A CN 200610049874A CN 1818875 A CN1818875 A CN 1818875A
- Authority
- CN
- China
- Prior art keywords
- task
- group
- real
- time
- distance
- 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
Landscapes
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
A hard real-time task attemper realization method of embedded operating system, the method is calculating the characteristics of the forecasted tasks in the task of the embedded operating system, and defines the maintenance interval of each of them, define the team, the team group, the interval of the team and the interval of the team group, attemper the task with least confliction in the multi-task situation, consequently save the switching time and the effect of the embedded operating system.
Description
Technical field
The present invention relates to embedded OS real-time task scheduling technical field, especially relate to a kind of implementation method of embedded OS grouping hard real-time task scheduling.
Background technology
Operating system is an intermediary of serving as between computer user and the computer hardware, and is used for the computer program of supervisory computer resource and controlling application program operation.The operation of a program be unable to do without the cooperation of operating system, is written into internal memory comprising instruction and data, initialization of I/O equipment and file system or the like; The management of every kind of I/O equipment and use all have the characteristics of oneself.And operating system has been taken over these work, thereby makes the user can feel more convenient in the process of these I/O equipment of use.File access not only needs to be familiar with the characteristics of relevant I/O equipment (disc driver etc.), but also the file layout that will be familiar with being correlated with.In addition,, consider, need make corresponding regulation and processing the access rights of file from the computer security angle for multi-user operating system or network operating system.These all are the work that operating system will be finished.For a multi-user or network operating system, operating system need be made corresponding regulation and processing to the custom system access rights.When operating system, such-and-such problem can appear.Operating system should provide corresponding mechanism to detect these information, and can provide rational processing or report user to some problem.
In some modern operating system, consider that for system function optimization or security of system angle operating system can be to user's use record relevant information.The general operation system all can provide abundant API to supply programmer's developing application, and a lot of program editing instrument, and Integrated Development Environment or the like also all provides by operating system.And computing machine has a lot of resources, and they are respectively applied for transmission, processing or the storage of data and the control of these operations.Operating system has just been given in the management work of these resources.
Real time operating system (RTOS) is meant the multiple task operating system that can make and finish response to external event in the time that limits, it is the important system resource in the embedded computer, different with the operating system of general-purpose platform, it often is embedded into target machine hardware device internal operation, the general user can't see its runnable interface, thereby the embedded OS that is otherwise known as.It often adopts microkernel designs, has the characteristics of real-time, reliability and tailorability, the application scenario that is very suitable for embedded system and requires to handle in real time.
Real-time feature has 2 points, and that is exactly that system not only needs to provide logical result of calculation, and its processing time also need to satisfy certain requirement, such as can not surpass certain closing time or the like.Can be divided into two classes to real-time system, a class is hard real-time (Hard Real-Time); An other class then is soft (Soft Real-Time) in real time.So-called hard real-time is meant that final result will be catastrophic if system fails to begin or finish in certain closing time to the processing of certain real-time task, even if this just means that but result is logical still meaningless; And in soft real-time system, be an expectation value closing time that Processing tasks starts or finishes, and may not be certain and must satisfy; Even if the processing time has surpassed closing time, also be significant.
The difference of real time operating system and normal operations system mainly shows five aspects, and determinacy, response sensitivity, user that its task that Here it is is handled participate in control, reliability and the emergency protection measure.
Real time operating system should be accomplished this point: start time that real-time task is handled and concluding time should be that determine, predictable, this is seeming extremely important handling in real time.From this respect, in real time operating system, the handling capacity of system is handled with determining of task and is compared, and less important many, and the task of real time operating system is handled possesses certain determinacy.
The determinacy of measurement system has a reasonable index, is exactly that system starts this two time interval of event occurrence from receiving the interruption and the corresponding Processing tasks that require to handle.This time parameter of general operation system is very big, and may have the change of several magnitude.And in real time operating system, it should be very little, and more stable, and a higher limit is arranged.
Summary of the invention
The object of the present invention is to provide a kind of implementation method of embedded OS grouping hard real-time task scheduling.
The technical scheme that the present invention solves its technical matters employing is as follows:
1) in the embedded OS, for real-time task, the definition of a plurality of real-time task set:
Tie up, add up the characteristics of each measurable task, each characteristic is called a dimension of this process;
Group, embedded OS divides into groups to real-time task, the task cluster that dimension space is close is group, during grouping mainly according to task according to resource needed with to the requirement of real-time;
Cohort, some dimensions are gone up similar group combination;
Distance between process: use Euclidean distance between the process of group space, to calculate;
Group distance: use Euclidean distance between group, to calculate;
Distance between cohort: use Euclidean distance between cohort, to calculate with the part dimension;
The task of Xiing mutually: the little task of distance between process;
The task of repelling each other: the big task of distance between process;
2) dispatching method of real-time task
I) task grouping
For the real-time task in the system, add up each measurable task, task is divided into different groups according to resource needed with requirement to real-time, and is different cohorts, distance between distance, group distance and cohort between calculation procedure different components;
Ii) scheduling in the group
Select only process in group, concrete dispatching algorithm can be chosen according to the different situations of each group, and the task of as far as possible selecting to inhale is mutually dispatched;
Iii) scheduling between the group
The situation of utilizing of situation that collection system is present and various resources is selected suitable dispatching algorithm, because dispatching algorithm is to dispatch according to the association attributes of process, so,, realize various common dispatching algorithms as long as adjust kind and weight choosing of attribute.
Described various common dispatching algorithm is: the circulation execution algorithm, the dispatching algorithm of first in first out is based on the dispatching algorithm of priority or the dispatching algorithm of reaction type formation.
The present invention compares with background technology, and the useful effect that has is:
(1) real-time.Start time and concluding time that real-time task is handled are that determine, predictable, and in real time operating system, the handling capacity of system and determining of task are handled and compared, and less important many, and the task processing of real time operating system possesses certain determinacy.
(2) sensitivity.System is after confirming task requests, and the time of handling relevant calculation task is shorter, helps improving response speed.
Description of drawings
Accompanying drawing is a dispatching method synoptic diagram of the present invention.
Specific implementation method
The present invention is further illustrated below in conjunction with drawings and Examples.
A kind of implementation method of embedded OS grouping hard real-time task scheduling, its embodiment is:
1) in the embedded OS, for real-time task, the definition of a plurality of real-time task set:
Tie up, add up the characteristics of each measurable task, each characteristic is called a dimension of this process;
Group, embedded OS divides into groups to real-time task, the task cluster that dimension space is close is group, during grouping mainly according to task according to resource needed with to the requirement of real-time;
Cohort, some dimensions are gone up similar group combination;
Distance between process: use Euclidean distance between the process of group space, to calculate;
Group distance: use Euclidean distance between group, to calculate;
Distance between cohort: use Euclidean distance between cohort, to calculate with the part dimension;
The task of Xiing mutually: the little task of distance between process;
The task of repelling each other: the big task of distance between process;
2) dispatching method of real-time task
I) task grouping
As the preparation of dispatching algorithm, earlier task is divided into different groups according to resource needed with requirement to real-time, compare convenient management like this to resource, for example, when a certain resource scarcity, can directly stop scheduling to this group, improve the efficient of system.Specifically, the group of a real-time task is set specially, and is a part of resource of this group reservation, the response time that is used for guaranteeing real-time task.
For the real-time task in the system, also to add up each measurable task, task is divided into different groups according to resource needed with requirement to real-time, and is different cohorts, distance between distance, group distance and cohort between calculation procedure different components.
In multiprogramming system (MPS), operating system need be the various resources of each process reasonable distribution, thereby makes and not only can not allow their operation produce conflict mutually, but also wishes and can make full use of these resources.In computer system, the most valuable and the easiest resource that causes that each process is competed is exactly a processor.How fairly and reasonably to distribute to the enough processor time of each process, and the utilization factor that improves processor as far as possible is the important content of Principles of Operating System research equally.And this task is to be finished by the scheduling mechanism of operating system.
Ii) scheduling in the group
Select only process in group, concrete dispatching algorithm can be chosen according to the different situations of each group, and the task of as far as possible selecting to inhale is mutually dispatched; Scheduling is exactly to select only process in group in the group, concrete dispatching algorithm can be chosen according to the different situations of each group, for example for the relevant group of network, possible rotation therapy better, and FIFO may more can embody the real-time of system for the group of real-time process.Each group all has own dispatching algorithm, do like this can the interior process of adjustment group very neatly the demand to resource, also can adjust in time according to different situations.But because need be before traditional dispatching algorithm in group, dispatch earlier, thus if algorithm is too complicated, can cause the efficient of system to reduce, so in group in the scheduling, the general comparative maturity that all is to use, fairly simple dispatching algorithm.
For example, can adopt the circulation execution algorithm.
The fundamental guiding ideology of circulation execution algorithm is, the processor time is divided into one by one timeslice (Time Slice), from the waiting process formation, select the method for next operation process the same with FCFS, different is, the processor time that each selected process is once occupied is timeslice so at most, then, next selected process will replace the control that this process obtains processor in the mode of preemptive type.And the processor time slicing is interrupted realizing promptly after a timeslice had consumed, having one interrupted producing by timer, and inform scheduler program, dispatching algorithm just is activated then, chooses the process that the next one will move, the circulation of a beginning new round.
It is exactly that it is in the imbalance of handling the resource use that can bring when I/O operations-intensive process and processor use intensive process that the circulation execution algorithm has a shortcoming.The intensive process of I/O can cause the I/O device busy, and processor uses seldom.
Processor uses intensive process then can allow processor work day and night, and I/O equipment often is in idle condition.This can cause this algorithm between process fairness and the quality of balance used of resource aspect performance poor.
Its improvement is virtual circulation execution algorithm.
The process creation of virtual circulation execution algorithm, fall in lines and selected operation part without the slightest difference with the FCFS algorithm.Different is to have added an assisted process formation.Like this, if finish when the I/O operation of present its application of an original process because of the I/O ensure suspension of operation, it is not to enter common waiting process formation, but enters the assisted process formation.When a new processor timeslice is arrived, process in the common waiting process formation of advance ratio in the assisted process formation is preferentially obtained the processor control, and will can not surpass its working time it in the last timeslice of once oneself obtaining with the left time.
Iii) scheduling between the group
In the group of each group, after the finishing scheduling, just entered into the stage of scheduling between group.The employed dispatching algorithm of native system can change according to the concrete condition of system.As everyone knows, there is not a kind of dispatching algorithm to be applicable to various situations, every kind of dispatching algorithm all has the usable condition of oneself, so use a kind of fixing dispatching algorithm can't allow system keep high-efficiency operation certainly, have only according to the situation of system's operation and come the reasonably operation conditions of Adjustment System of conversion dispatching algorithm always.Concrete realization is to select suitable dispatching algorithm by the present situation of collection system and the situation of utilizing of various resources, because dispatching algorithm is to dispatch according to the association attributes of process, so, as long as adjust kind and weight choosing of attribute, just various common dispatching algorithms can have been realized, such as virtual circulation execution algorithm, the specific algorithm process is as 2) iii) in to the description of algorithm.
Scheduling makes some exist the process of coupling to be assigned to same number of processor and operation simultaneously one to one mutually between group.For several processes that are mutually related, if parallel processing will reduce synchronous obstruction, reduce process switching, thereby improve performance; In addition, because a scheduling decision can influence one group of process simultaneously, thereby also reduced the frequency that scheduler program is carried out, thereby reduced scheduling time.
Described various common dispatching algorithm is: the circulation execution algorithm, the dispatching algorithm of first in first out is based on the dispatching algorithm of priority or the dispatching algorithm of reaction type formation.
Claims (2)
1, a kind of implementation method of embedded OS grouping hard real-time task scheduling is characterized in that:
1) in the embedded OS, for real-time task, the definition of a plurality of real-time task set:
Tie up, add up the characteristics of each measurable task, each characteristic is called a dimension of this process;
Group, embedded OS divides into groups to real-time task, the task cluster that dimension space is close is group, during grouping mainly according to task according to resource needed with to the requirement of real-time;
Cohort, some dimensions are gone up similar group combination;
Distance between process: use Euclidean distance between the process of group space, to calculate;
Group distance: use Euclidean distance between group, to calculate;
Distance between cohort: use Euclidean distance between cohort, to calculate with the part dimension;
The task of Xiing mutually: the little task of distance between process;
The task of repelling each other: the big task of distance between process;
2) dispatching method of real-time task
I) task grouping
For the real-time task in the system, add up each measurable task, task is divided into different groups according to resource needed with requirement to real-time, and is different cohorts, distance between distance, group distance and cohort between calculation procedure different components;
Ii) scheduling in the group
Select only process in group, concrete dispatching algorithm can be chosen according to the different situations of each group, and the task of as far as possible selecting to inhale is mutually dispatched;
Iii) scheduling between the group
The situation of utilizing of situation that collection system is present and various resources is selected suitable dispatching algorithm, because dispatching algorithm is to dispatch according to the association attributes of process, so,, realize various common dispatching algorithms as long as adjust kind and weight choosing of attribute.
2, the implementation method of a kind of embedded OS grouping hard real-time task scheduling according to claim 1, it is characterized in that: described various common dispatching algorithms are: the circulation execution algorithm, the dispatching algorithm of first in first out is based on the dispatching algorithm of priority or the dispatching algorithm of reaction type formation.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNB2006100498741A CN100377091C (en) | 2006-03-16 | 2006-03-16 | Grouped hard realtime task dispatching method of built-in operation system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CNB2006100498741A CN100377091C (en) | 2006-03-16 | 2006-03-16 | Grouped hard realtime task dispatching method of built-in operation system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN1818875A true CN1818875A (en) | 2006-08-16 |
CN100377091C CN100377091C (en) | 2008-03-26 |
Family
ID=36918899
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CNB2006100498741A Expired - Fee Related CN100377091C (en) | 2006-03-16 | 2006-03-16 | Grouped hard realtime task dispatching method of built-in operation system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN100377091C (en) |
Cited By (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100444121C (en) * | 2006-09-11 | 2008-12-17 | 中国工商银行股份有限公司 | Batch task scheduling engine and dispatching method |
CN101246437B (en) * | 2008-01-28 | 2010-06-09 | 中兴通讯股份有限公司 | Built-in real-time system course equalization scheduling method |
CN102027447A (en) * | 2008-05-16 | 2011-04-20 | 微软公司 | Local collections of tasks in a scheduler |
CN101540787B (en) * | 2009-04-13 | 2011-11-09 | 浙江大学 | Implementation method of communication module of on-chip distributed operating system |
CN102455932A (en) * | 2010-10-22 | 2012-05-16 | 金蝶软件(中国)有限公司 | Serial execution method, device and system for task instances |
CN101452404B (en) * | 2008-12-09 | 2013-11-06 | 中兴通讯股份有限公司 | Task scheduling apparatus and method for embedded operating system |
CN103631751A (en) * | 2013-12-17 | 2014-03-12 | 武汉科技大学 | Multi-task set partitioning method based on connection characteristics |
CN104090747A (en) * | 2014-05-22 | 2014-10-08 | 清华大学 | Method for optimizing Linux intelligent terminal through real-time scheduling optimizer |
CN104765640A (en) * | 2014-01-02 | 2015-07-08 | 中国科学院声学研究所 | Intelligent service scheduling method |
CN106502767A (en) * | 2015-09-08 | 2017-03-15 | 大唐移动通信设备有限公司 | A kind of process management method and its device |
CN109144716A (en) * | 2017-06-28 | 2019-01-04 | 中兴通讯股份有限公司 | Operating system dispatching method and device, equipment based on machine learning |
CN116700135A (en) * | 2023-08-09 | 2023-09-05 | 长江三峡集团实业发展(北京)有限公司 | Method and device for testing task scheduling mode of programmable logic controller |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CA2131406C (en) * | 1993-09-21 | 2002-11-12 | David D'souza | Preemptive multi-tasking with cooperative groups of tasks |
US7383550B2 (en) * | 2002-12-23 | 2008-06-03 | International Business Machines Corporation | Topology aware grid services scheduler architecture |
US20040226015A1 (en) * | 2003-05-09 | 2004-11-11 | Leonard Ozgur C. | Multi-level computing resource scheduling control for operating system partitions |
US20060037018A1 (en) * | 2004-08-16 | 2006-02-16 | Dell Products L.P. | System, method and software providing an adaptive job dispatch algorithm for large distributed jobs |
-
2006
- 2006-03-16 CN CNB2006100498741A patent/CN100377091C/en not_active Expired - Fee Related
Cited By (19)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN100444121C (en) * | 2006-09-11 | 2008-12-17 | 中国工商银行股份有限公司 | Batch task scheduling engine and dispatching method |
CN101246437B (en) * | 2008-01-28 | 2010-06-09 | 中兴通讯股份有限公司 | Built-in real-time system course equalization scheduling method |
CN102027447B (en) * | 2008-05-16 | 2013-12-04 | 微软公司 | Local collections of tasks in a scheduler |
CN102027447A (en) * | 2008-05-16 | 2011-04-20 | 微软公司 | Local collections of tasks in a scheduler |
CN101452404B (en) * | 2008-12-09 | 2013-11-06 | 中兴通讯股份有限公司 | Task scheduling apparatus and method for embedded operating system |
CN101540787B (en) * | 2009-04-13 | 2011-11-09 | 浙江大学 | Implementation method of communication module of on-chip distributed operating system |
CN102455932B (en) * | 2010-10-22 | 2014-06-25 | 金蝶软件(中国)有限公司 | Serial execution method, device and system for task instances |
CN102455932A (en) * | 2010-10-22 | 2012-05-16 | 金蝶软件(中国)有限公司 | Serial execution method, device and system for task instances |
CN103631751A (en) * | 2013-12-17 | 2014-03-12 | 武汉科技大学 | Multi-task set partitioning method based on connection characteristics |
CN103631751B (en) * | 2013-12-17 | 2016-04-27 | 武汉科技大学 | A kind of multitask set partitioning method based on connection features |
CN104765640A (en) * | 2014-01-02 | 2015-07-08 | 中国科学院声学研究所 | Intelligent service scheduling method |
WO2015100995A1 (en) * | 2014-01-02 | 2015-07-09 | 中国科学院声学研究所 | Intelligent service scheduling method |
CN104765640B (en) * | 2014-01-02 | 2018-02-16 | 中国科学院声学研究所 | A kind of intelligent Service dispatching method |
CN104090747A (en) * | 2014-05-22 | 2014-10-08 | 清华大学 | Method for optimizing Linux intelligent terminal through real-time scheduling optimizer |
CN104090747B (en) * | 2014-05-22 | 2018-08-21 | 清华大学 | The method that Linux intelligent terminals are optimized using Real-Time Scheduling optimizer |
CN106502767A (en) * | 2015-09-08 | 2017-03-15 | 大唐移动通信设备有限公司 | A kind of process management method and its device |
CN109144716A (en) * | 2017-06-28 | 2019-01-04 | 中兴通讯股份有限公司 | Operating system dispatching method and device, equipment based on machine learning |
CN116700135A (en) * | 2023-08-09 | 2023-09-05 | 长江三峡集团实业发展(北京)有限公司 | Method and device for testing task scheduling mode of programmable logic controller |
CN116700135B (en) * | 2023-08-09 | 2023-10-20 | 长江三峡集团实业发展(北京)有限公司 | Method and device for testing task scheduling mode of programmable logic controller |
Also Published As
Publication number | Publication date |
---|---|
CN100377091C (en) | 2008-03-26 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN1818875A (en) | Grouped hard realtime task dispatching method of built-in operation system | |
CN1158596C (en) | Scheduling operations using dependency matrix | |
US8156495B2 (en) | Scheduling threads on processors | |
US8713573B2 (en) | Synchronization scheduling apparatus and method in real-time multi-core system | |
US20120072627A1 (en) | Dynamic creation and destruction of io resources based on actual load and resource availability | |
US8627325B2 (en) | Scheduling memory usage of a workload | |
CN1908903A (en) | System and method for executing job step, and computer product | |
CN109144710A (en) | Resource regulating method, device and computer readable storage medium | |
CN102096599A (en) | Multi-queue task scheduling method and related system and equipment | |
CN1577253A (en) | EDF scheduling method | |
CN1975655A (en) | Method and apparatus for managing access to storage | |
CN1877534A (en) | Accomplishing method for embedded real-time file system task scheduling | |
Yu et al. | Cloud task scheduling algorithm based on three queues and dynamic priority | |
Zhang et al. | A spark scheduling strategy for heterogeneous cluster | |
US20210390405A1 (en) | Microservice-based training systems in heterogeneous graphic processor unit (gpu) cluster and operating method thereof | |
CN109491775B (en) | Task processing and scheduling method used in edge computing environment | |
CN109298919B (en) | Multi-core scheduling method of soft real-time system for high-utilization-rate task set | |
CN1825288A (en) | Method for implementing process multi-queue dispatching of embedded SRAM operating system | |
WO2018119899A1 (en) | Storage controller and io request processing method | |
KR101639947B1 (en) | Hadoop preemptive deadline constraint scheduling method, execution program thereof method and recorded medium of the program | |
CN1315047C (en) | A method for managing cluster job | |
KR20150089665A (en) | Appratus for workflow job scheduling | |
CN114067917A (en) | GATK super computer system based on tuning parameters | |
CN1302412C (en) | Computer group system and its operation managing method | |
CN1732439A (en) | Audio processing system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
C17 | Cessation of patent right | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20080326 Termination date: 20120316 |