Probabilistic hybrid critical system dynamic priority imprecise task energy saving scheduling method and device
By adopting a probabilistic hybrid critical system dynamic priority non-precise task energy-saving scheduling method, the problem of low resource utilization of hybrid critical systems is solved, energy consumption is reduced and tasks are completed within the deadline, thereby improving the battery life and production efficiency of UAV systems.
Patent Information
- Application Number
- CN202211040206.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-08-29
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2042-08-29
AI Technical Summary
Existing studies on energy consumption in hybrid critical systems employ deterministic analysis methods, resulting in low resource utilization and poor energy-saving effects, particularly impacting battery life and production costs in unmanned aerial vehicle (UAV) systems.
A probabilistic hybrid critical system dynamic priority non-precise task energy-saving scheduling method is adopted. By establishing the execution time under the worst probabilistic condition, calculating the probabilistic utilization rate, and adjusting the energy consumption optimization speed of low mode and high mode according to feasible conditions, the task execution strategy is dynamically adjusted.
Significantly reduced energy consumption, saving 47.36% of energy, ensuring tasks are completed within deadlines, extending equipment lifespan, and reducing production costs.
Smart Images

Figure CN115480890B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of embedded systems and mixed-critical systems low-energy real-time scheduling, and in particular to a probabilistic mixed-critical system dynamic priority non-precise task energy-saving scheduling method and device. BACKGROUND
[0002] The development trend of embedded systems is to integrate multiple different applications into the same shared platform to form a mixed-critical system. The automotive driving system and the unmanned aerial vehicle driving system are typical representatives of mixed-critical systems. In a mixed-critical system, not only do tasks have different critical levels, but the system also has different execution modes. Therefore, not only must the correct execution of tasks of different critical levels be ensured, but the correct scheduling of the system in different modes must also be ensured. In addition, it is also necessary to ensure that the results of the scheduling are output within the specified deadline.
[0003] Energy consumption is very important for mixed-critical systems, especially for battery-powered unmanned aerial vehicle systems. Reducing energy consumption not only improves the stability and reliability of the system, but also improves the endurance of the battery, reduces the production cost of the product, and improves the competitiveness of the product.
[0004] Existing energy consumption research for mixed-critical systems uses deterministic analysis methods, assuming that tasks are always executed in their worst-case time. This assumption is overly pessimistic, resulting in low resource utilization and poor energy-saving effects. SUMMARY
[0005] To solve the above technical problems, embodiments of the present application propose a probabilistic mixed-critical system dynamic priority non-precise task energy-saving scheduling method and device, which can more effectively utilize system resources and reduce energy consumption.
[0006] In a first aspect, embodiments of the present application provide a probabilistic mixed-critical system dynamic priority non-precise task energy-saving scheduling method, comprising the following steps:
[0007] S1, establishing a probabilistic mixed-critical system and determining the execution time of the mixed-critical periodic task in the worst-case probability, and calculating the probability utilization rate according to the execution time of the mixed-critical periodic task in the worst-case probability;
[0008] S2, determining the sufficient condition for the scheduling feasibility of the probabilistic mixed-critical system in the low mode and the high mode according to the probability utilization rate;
[0009] S3, calculating the energy consumption optimization speed S LO of the low mode and the energy consumption optimization speed S HI of the high mode according to the scheduling feasible condition.
[0010] S4, When the probabilistic hybrid critical system is in low mode, the hybrid critical cyclic task optimizes the energy consumption of the low mode at a speed S. LO When the probabilistic hybrid critical system is in high mode, the hybrid critical cyclic task operates at an energy-optimized speed S in high mode. HI implement.
[0011] As a preferred option, a probabilistic hybrid critical system includes a task set Γ={τ1,τ2,…,τ2,τ3} comprising n mutually independent hybrid critical periodic tasks. n Hybrid critical cycle tasks τ i (1≤i≤n, i is an integer) by (T) i ,L i pWCET i ) indicates that T i It is τ i The period; L i It is τ i The critical level is defined as either LO or HI, where LO represents a low-critical-level task and HI represents a high-critical-level task.
[0012] Preferably, in step S1, determining the execution time under the worst-case probabilistic scenario for the mixed critical cycle tasks specifically includes:
[0013] pWCET i It is a hybrid critical cycle task τ i The worst-case execution time, expressed by the following formula:
[0014]
[0015] in, Representing the hybrid critical cycle task τ i Minimum execution time and maximum execution time at maximum processor speed; when mixed critical cyclic tasks τ i When it is a low-criticality task, When task τ i When it is a high-critical-level task, It is the execution time of low-critical-level tasks in high-mode. It is the time threshold for the transition of high-critical-level task modes; and These represent the execution time as follows: The probability and distribution function; and Low mode refers to all high-criticality level mixed critical cycle tasks τ i Upon completion, its execution time shall not exceed And all low-critical-level bond-cycle tasks τ iThe execution time does not exceed High-level mode refers to all high-critical-level mixed critical-cycle tasks τ i Complete execution, with an execution time not exceeding [time not specified]. And the execution time of low-criticality tasks does not exceed
[0016] Preferably, in step S1, the probability utilization rate is calculated based on the worst-case execution time of the mixed critical cycle tasks, specifically including:
[0017] The task set is scheduled using a preemptive dynamic priority strategy, and a mixture of critical periodic tasks τ is used. i probability utilization rate U i Calculated by the following formula:
[0018]
[0019] in,
[0020] Preferably, step S2 specifically includes:
[0021] The sufficient condition for the feasibility of scheduling a probabilistic hybrid critical system in low mode is given by the following equation:
[0022] max{U LO}≤1;
[0023] Or, max{U LO}>1 and the following formula holds:
[0024] 1-F LO (||U LO ||1)<F s ;
[0025] Where, max{U LO} represents the probability distribution U LO The maximum value in, Let ||U| represent the probability distribution of the utilization of task set Γ in low mode. LO ||1 represents U LO The maximum value where the median is less than 1; and These represent the utilization probability distributions of the low-criticality task set and the high-criticality task set in the low-mode, respectively. Γ represents the convolution of two probability distributions; LO and Γ HI These represent the sets of low-criticality tasks and the sets of high-criticality tasks, respectively. Represents a hybrid critical cycle task τ i Utilization distribution in low-mode; if mixed critical cyclic tasks τ iis a low criticality level task, if the hybrid critical periodic task τ i is a high criticality level task, and its value is equal to U i ; the truncation process is as follows:
[0026]
[0027] where, and min≤l<thr, F s denotes the probability that the probabilistic hybrid critical system is allowed to fail;
[0028] A sufficient condition for the probabilistic hybrid critical system to be schedulable in the high mode is given by:
[0029] max{U HI}≤1;
[0030] or, max{U HI}>1 and the following holds:
[0031] 1-F HI (||U HI ||1)<F s ;
[0032] where, max{U HI} denotes the maximum value in the probability distribution U HI , denotes the utilization probability distribution of the task set Γ in the high mode, ||U HI ||1 denotes the maximum value in U HI with value less than 1; and denote the utilization probability distribution of the low criticality level task set in the low mode and the high criticality level task set in the high mode, respectively; denotes the convolution of two probability distributions; Γ LO and Γ HI denote the low criticality level task set and the high criticality level task set, respectively, denotes the utilization distribution of the hybrid critical periodic task τ i in the low mode; if the hybrid critical periodic task τ i is a low criticality level task, if the hybrid critical periodic task τ i is a high criticality level task, F s denotes the probability that the probabilistic hybrid critical system is allowed to fail.
[0033] As a preference, step S3 specifically comprises:
[0034] When max{U LO}≤1, S LO =max{U LO}; otherwise, S LO =1; denotes the utilization probability distribution of the task set Γ in the low mode;
[0035] When max{U HI}≤1, S HI =max{U HI}; otherwise, S HI =1; denotes the utilization probability distribution of the task set Γ in the high mode; denotes the convolution of the two probability distributions.
[0036] As a preference, step S4 specifically comprises:
[0037] The probabilistic mixed-critical system starts in the low mode, and all tasks are executed with S LO ; when the execution time of the high-criticality level task mixed-critical periodic task τ i exceeds and is not completed, or the execution time of the low-criticality level task mixed-critical periodic task τ i exceeds , the probabilistic mixed-critical system switches from the low mode to the high mode, and all tasks are executed with S HI ; the execution time of the low-criticality level mixed-critical periodic task τ i does not exceed ; otherwise, the execution is terminated; when all high-criticality level task mixed-critical periodic tasks τ i are executed completely or the processor is in an idle state, the probabilistic mixed-critical system returns from the high mode to the low mode, and all tasks are executed with S LO .
[0038] In a second aspect, embodiments of the present application provide a probabilistic mixed-critical system dynamic priority imprecise task energy-saving scheduling device, comprising:
[0039] A probabilistic utilization rate calculation module is configured to establish a probabilistic mixed-critical system, determine the execution time of a mixed-critical periodic task in a probabilistic worst case, and calculate a probabilistic utilization rate according to the execution time of the mixed-critical periodic task in the probabilistic worst case;
[0040] A condition determination module is configured to determine sufficient conditions for scheduling of a probabilistic mixed-critical system in a low mode and a high mode according to the probabilistic utilization rate;
[0041] The energy consumption speed calculation module is configured to calculate the energy consumption optimization speed S of the low mode according to the condition that the scheduling is feasible LO and the energy consumption optimization speed S of the high mode HI ;
[0042] The execution module is configured to execute the mixed critical periodic task at the energy consumption optimization speed S of the low mode when the probabilistic mixed critical system is in the low mode LO The execution module is configured to execute the mixed critical periodic task at the energy consumption optimization speed S of the high mode when the probabilistic mixed critical system is in the high mode HI .
[0043] In a third aspect, an embodiment of the present application provides an electronic device, including one or more processors; a storage device configured to store one or more programs, when the one or more programs are executed by the one or more processors, the one or more processors implement the method described in any of the implementation manners of the first aspect.
[0044] In a fourth aspect, an embodiment of the present application provides a computer readable storage medium, which stores a computer program, when the computer program is executed by a processor, the method described in any of the implementation manners of the first aspect is implemented.
[0045] Compared with the prior art, the present application has the following beneficial effects:
[0046] (1) The probabilistic mixed critical system dynamic priority non-precise task energy saving scheduling method provided by the present application saves about 47.36% energy consumption compared with the existing mixed critical system periodic task scheduling method.
[0047] (2) The probabilistic mixed critical system dynamic priority non-precise task energy saving scheduling method provided by the present application can ensure that the periodic task is completed within its deadline.
[0048] (3) The probabilistic mixed critical system dynamic priority non-precise task energy saving scheduling method provided by the present application can reduce the energy consumption of the mixed critical system, reduce the production cost of the product, prolong the use time of the equipment, and reduce the replacement period of the battery. BRIEF DESCRIPTION OF DRAWINGS
[0049] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings needed in the embodiment description. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0050] Figure 1 is an exemplary device architecture diagram to which an embodiment of the present application can be applied;
[0051] Figure 2 A flowchart of a probability mixed critical system dynamic priority non-precise task energy-saving scheduling method for an embodiment of the present application;
[0052] Figure 3 A schematic diagram of a probability mixed critical system dynamic priority non-precise task energy-saving scheduling device for an embodiment of the present application;
[0053] Figure 4 A structural schematic diagram of a computer device of an electronic device suitable for implementing an embodiment of the present application. DETAILED DESCRIPTION
[0054] In order to make the objectives, technical solutions and advantages of the present application clearer, the present application will be further described in detail below with reference to the drawings. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments of the present application, all other embodiments obtained by those of ordinary skill in the art without creative work fall within the scope of the present application.
[0055] Figure 1 An exemplary device architecture 100 to which the probability mixed critical system dynamic priority non-precise task energy-saving scheduling method or the probability mixed critical system dynamic priority non-precise task energy-saving scheduling device of an embodiment of the present application can be applied is shown.
[0056] As shown in Figure 1 , the device architecture 100 can include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is used to provide a communication link medium between the terminal devices 101, 102, 103 and the server 105. The network 104 can include various connection types, such as wired, wireless communication links or fiber optic cables, etc.
[0057] A user can use the terminal devices 101, 102, 103 to interact with the server 105 through the network 104 to receive or send messages, etc. Various applications, such as data processing applications, file processing applications, etc. can be installed on the terminal devices 101, 102, 103.
[0058] The terminal devices 101, 102, and 103 can be hardware or software. When the terminal devices 101, 102, and 103 are hardware, they can be various electronic devices including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like. When the terminal devices 101, 102, and 103 are software, they can be installed in the above-listed electronic devices. They can be implemented as multiple software or software modules (for example, software or software modules for providing distributed services) or as a single software or software module. No specific limitation is made herein.
[0059] The server 105 can be a server providing various services, for example, a background data processing server processing files or data uploaded by the terminal devices 101, 102, and 103. The background data processing server can process the obtained files or data to generate a processing result.
[0060] It should be noted that the probability mixed critical system dynamic priority non-precise task energy-saving scheduling method provided by the embodiments of the present application can be executed by the server 105 or the terminal devices 101, 102, and 103, and accordingly, the probability mixed critical system dynamic priority non-precise task energy-saving scheduling apparatus can be arranged in the server 105 or the terminal devices 101, 102, and 103.
[0061] It should be understood that Figure 1 The number of terminal devices, networks, and servers in the above-mentioned apparatus architecture is only illustrative. Any number of terminal devices, networks, and servers can be provided according to implementation needs. In the case where the data to be processed does not need to be obtained from a remote place, the above-mentioned apparatus architecture can not include a network, but only a server or a terminal device.
[0062] Figure 2 A probability mixed critical system dynamic priority non-precise task energy-saving scheduling method provided by an embodiment of the present application is shown, which includes the following steps:
[0063] S1, a probability mixed critical system is established, and the execution time in the worst case of the probability of the mixed critical periodic task is determined, and the probability utilization rate is calculated according to the execution time in the worst case of the probability of the mixed critical periodic task.
[0064] In a specific embodiment, the step S1 specifically includes:
[0065] The probability mixed critical system includes a task set Γ = {τ1, τ2, …, τn} containing n independent mixed critical periodic tasks. n The mixed critical periodic task τi (1≤i≤n, i is an integer) is determined by (T i , L i , and pWCETi. i WCETii represents, where T i is the period of τ i ; L i is the criticality level of τ i , which has a value of LO or HI, LO is a low criticality level task, and HI is a high criticality level task. pWCET i is the probability worst case execution time of a mixed critical periodic task τ i , which has a value represented by the following formula:
[0066]
[0067] wherein, respectively represent the minimum execution time and the maximum execution time of a mixed critical periodic task τ i at the maximum processor speed; when the mixed critical periodic task τ i is a low criticality level task, when the task τ i is a high criticality level task, is the execution time of a low criticality level task in a high mode; is the time threshold of a mode switch of a high criticality level task; and respectively represent the probability that the execution time is and the distribution function; and the low mode refers to that when all the high criticality level mixed critical periodic tasks τ i complete execution, the execution time thereof is not more than and the execution time of all the low criticality level key periodic tasks τ i is not more than the high mode refers to that when all the high criticality level mixed critical periodic tasks τ i complete execution, the execution time thereof is not more than and the execution time of a low criticality level task is not more than
[0068] Embodiments of the present application schedule a task set by using a preemption dynamic priority strategy, which refers to that the priority of different jobs of the same mixed critical periodic task can be changed at different times, and a high priority task can preempt a low priority task. Embodiments of the present application schedule a task by using an earliest deadline first strategy. The earliest deadline first strategy refers to that the priority of a task is determined by a deadline, the smaller the deadline, the higher the priority; when the deadlines are the same, the smaller the arrival time of a task, the higher the priority; when the deadline and the arrival time are the same, the smaller the subscript of a task, the higher the priority. The probability utilization rate U i of a mixed critical periodic task τ iCalculated by the following formula:
[0069]
[0070] in,
[0071] S2, based on the probability utilization rate, determine the sufficient conditions for the feasibility of scheduling the probabilistic hybrid critical system in both low and high modes.
[0072] In a specific embodiment, step S2 specifically includes:
[0073] The sufficient condition for the feasibility of scheduling a probabilistic hybrid critical system in low mode is given by the following equation:
[0074] max{U LO}≤1;
[0075] Or, max{U LO}>1 and the following formula holds:
[0076] 1-F LO (||U LO ||1)<F s ;
[0077] Where, max{U LO} represents the probability distribution U LO The maximum value in, Let ||U| represent the probability distribution of the utilization of task set Γ in low mode. LO ||1 represents U LO The maximum value where the median is less than 1; and These represent the utilization probability distributions of the low-criticality task set and the high-criticality task set in the low-mode, respectively. Γ represents the convolution of two probability distributions. LO and Γ HI These represent the sets of low-criticality tasks and the sets of high-criticality tasks, respectively. Represents a hybrid critical cycle task τ i Utilization distribution in low-mode; if mixed critical cyclic tasks τ i It is a low-criticality task. If the key cycle tasks τ are mixed i It is a high-critical-level task, That The value is equal to U i In the distribution of values The boundary is used for truncation; the truncation process is as follows:
[0078]
[0079] in, And min≤l<thr,
[0080] F s This represents the probability that a probabilistically hybrid critical system is allowed to fail.
[0081] The sufficient condition for the feasibility of scheduling a probabilistic hybrid critical system in high mode is given by the following equation:
[0082] max{U HI}≤1;
[0083] Or, max{U HI}>1 and the following formula holds:
[0084] 1-F HI (||U HI ||1)<F s ;
[0085] Where, max{U HI} represents the probability distribution U HI The maximum value in, Let ||U| represent the probability distribution of the utilization of task set Γ in high mode. HI ||1 represents U HI The maximum value where the median is less than 1; and These represent the utilization probability distributions of low-criticality task sets in low-mode task sets and high-criticality task sets in high-mode tasks, respectively. Γ represents the convolution of two probability distributions. LO and Γ HI These represent the sets of low-criticality tasks and the sets of high-criticality tasks, respectively. Represents a hybrid critical cycle task τ i Utilization distribution in low-mode; if mixed critical cyclic tasks τ i It is a low-criticality task. If the key cycle tasks τ are mixed i It is a high-critical-level task. F s This represents the probability that a probabilistically hybrid critical system is allowed to fail.
[0086] S3, based on the conditions for feasible scheduling, calculate the energy consumption optimization speed S in low mode. LO And high-mode energy efficiency optimization speed S HI .
[0087] In a specific embodiment, step S3 specifically includes:
[0088] When max{U LO When}≤1, SLO = max{U LO}; otherwise, S LO = 1. denotes the utilization probability distribution of the task set Γ in the low mode, max{U LO} denotes the maximum value in the probability distribution U LO ; and denote the utilization probability distribution of the low criticality task set and the high criticality task set in the low mode, respectively; denotes the convolution of the two probability distributions; Γ LO and Γ HI denote the low criticality task set and the high criticality task set, respectively, denotes the utilization distribution of the mixed criticality periodic task τ i in the low mode; if the mixed criticality periodic task τ i is a low criticality task, if the mixed criticality periodic task τ i is a high criticality task, the value of U i is truncated at the value ;
[0089] When max{U HI}≤1, S HI = max{U HI}; otherwise, S HI = 1. denotes the utilization probability distribution of the task set Γ in the high mode; max{U HI} denotes the maximum value in the probability distribution U HI , and denote the utilization probability distribution of the low criticality task set in the low mode and the high criticality task set in the high mode, respectively; denotes the convolution of the two probability distributions; Γ LO and Γ HI denote the low criticality task set and the high criticality task set, respectively, denotes the utilization distribution of the mixed criticality periodic task τ i in the low mode; if the mixed criticality periodic task τ i is a low criticality task, if the mixed criticality periodic task τ i is a high criticality task denotes the convolution of the two probability distributions.
[0090] S4, when the probabilistic mixed-critical system is in the low mode, the mixed-critical periodic tasks are executed at the energy-optimized speed S of the low mode LO S4, when the probabilistic mixed-critical system is in the low mode, the mixed-critical periodic tasks are executed at the energy-optimized speed S of the low mode HI S4, when the probabilistic mixed-critical system is in the low mode, the mixed-critical periodic tasks are executed at the energy-optimized speed S of the low mode
[0091] In a specific embodiment, step S4 specifically comprises:
[0092] The probabilistic mixed-critical system starts in the low mode, all tasks are executed at S LO ; when the execution time of the high-criticality-level mixed-critical periodic task τ i exceeds C i thr / S LO is not completed, or the execution time of the low-criticality-level mixed-critical periodic task τ i exceeds C i max / S LO ; the probabilistic mixed-critical system switches from the low mode to the high mode, all tasks are executed at S HI in the high mode; the execution time of the low-criticality-level mixed-critical periodic task τ i does not exceed C i deg / S HI , otherwise the execution is terminated; when all high-criticality-level mixed-critical periodic tasks τ i are executed or the processor is in an idle state, the probabilistic mixed-critical system returns from the high mode to the low mode, at this time all tasks are executed at S LO .
[0093] In this embodiment, the mixed-critical periodic task set Γ = {τ1, τ2, τ3} contains three mixed-critical periodic tasks τ1 = (10, HI, pWCET1), τ2 = (15, LO, pWCET2), and τ3 = (20, HI, pWCET3), and the execution time of the mixed-critical periodic tasks in the worst case of probability is as follows:
[0094]
[0095]
[0096] Therefore, max{U LO} = 0.55, f LO (max{U LO}) = 0.007912, F LO (max{U LO}) = 1, max{U HI} = 0.85, fHI (max{U HI}) = 0.000002, F HI (max{U HI}) = 1, S LO = 0.55, S HI = 0.85, the average energy consumption of the mixed critical periodic task τ1 in the low mode and the high mode is 9.16 and 13.92 respectively; the average energy consumption of the whole task set in the low mode and the high mode is 20.32 and 30.88 respectively; the total energy consumption of the system without using the probability model is 38.6; the method of the embodiment of the present application is compared with the method of executing the task in its worst case execution time, and the energy consumption is saved by about 47.36% in the low mode and by about 20% in the high mode when scheduling the task set in the interval [0, 60].
[0097] Further referring to Figure 3 , as an implementation of the method shown in the above figures, the present application provides an embodiment of a device for energy-saving scheduling of a probabilistic mixed critical system dynamic priority imprecise task, which corresponds to the method embodiment shown in Figure 2 , and the device can be applied in various electronic devices.
[0098] The embodiment of the present application provides a device for energy-saving scheduling of a probabilistic mixed critical system dynamic priority imprecise task, which comprises:
[0099] A probability utilization rate calculation module 1 is configured to establish a probabilistic mixed critical system, determine the execution time of a mixed critical periodic task in the worst case, and calculate the probability utilization rate according to the execution time of the mixed critical periodic task in the worst case.
[0100] A condition determination module 2 is configured to determine sufficient conditions for scheduling of the probabilistic mixed critical system in the low mode and the high mode according to the probability utilization rate.
[0101] An energy consumption speed calculation module 3 is configured to calculate the energy consumption optimization speed S LO in the low mode and the energy consumption optimization speed S HI in the high mode according to the sufficient conditions for scheduling.
[0102] An execution module 4 is configured to execute the mixed critical periodic task at the energy consumption optimization speed S LO in the low mode when the probabilistic mixed critical system is in the low mode, and execute the mixed critical periodic task at the energy consumption optimization speed S HI in the high mode when the probabilistic mixed critical system is in the high mode.
[0103] The following refers to Figure 4It illustrates an electronic device suitable for implementing embodiments of this application (e.g., Figure 1 The diagram shows the structure of a computer device 400 (a server or terminal device). Figure 4 The electronic device shown is merely an example and should not impose any limitation on the functionality and scope of use of the embodiments of this application.
[0104] like Figure 4 As shown, the computer device 400 includes a central processing unit (CPU) 401 and a graphics processing unit (GPU) 402, which can perform various appropriate actions and processes according to programs stored in read-only memory (ROM) 403 or programs loaded from storage section 409 into random access memory (RAM) 404. The RAM 404 also stores various programs and data required for the operation of the device 400. The CPU 401, GPU 402, ROM 403, and RAM 404 are interconnected via a bus 405. An input / output (I / O) interface 406 is also connected to the bus 405.
[0105] The following components are connected to I / O interface 406: an input section 407 including a keyboard, mouse, etc.; an output section 408 including an LCD, speakers, etc.; a storage section 409 including a hard disk, etc.; and a communication section 410 including a network interface card, such as a LAN card or modem. The communication section 410 performs communication processing via a network such as the Internet. A drive 411 may also be connected to I / O interface 406 as needed. A removable medium 412, such as a hard disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on drive 411 as needed so that computer programs read from it can be installed into storage section 409 as needed.
[0106] In particular, according to embodiments of this disclosure, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via communication section 410, and / or installed from removable medium 412. When the computer program is executed by central processing unit (CPU) 401 and graphics processing unit (GPU) 402, the functions defined in the methods of this application are performed.
[0107] Note that the computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium or any combination thereof. The computer-readable medium can be, for example but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a computer-readable medium can include, but are not limited to, an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present context, a computer-readable medium can be any tangible medium that can contain or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present context, a computer-readable signal medium can include a computer-readable program code in a baseband or propagated as carrier waves in a propagated data signal associating with a carrier wave. Such a propagated signal can take a wide variety of forms including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer-readable signal medium can also be any computer-readable medium that can be used to carry or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The program contained in the computer-readable medium can be transmitted in any suitable format including, but not limited to, wireless, wireline, optical fiber cable, RF, or any suitable combination thereof.
[0108] Computer program code for carrying out operations of the present application can be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C++ or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider).
[0109] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using dedicated hardware-based means to perform the specified function or operation, or using a combination of dedicated hardware and computer instructions.
[0110] The modules described in the embodiments of this application can be implemented in software or hardware. These modules can also be located within a processor.
[0111] In another aspect, this application also provides a computer-readable medium, which may be included in the electronic device described in the above embodiments; or it may exist independently and not assembled into the electronic device. The computer-readable medium carries one or more programs, which, when executed by the electronic device, cause the electronic device to: establish a probabilistic hybrid critical system and determine the worst-case execution time of the hybrid critical cyclic task; calculate the probabilistic utilization rate based on the worst-case execution time of the hybrid critical cyclic task; determine sufficient conditions for the feasibility of scheduling the probabilistic hybrid critical system in low and high modes based on the probabilistic utilization rate; and calculate the energy-optimized speed S in low mode based on the scheduling feasibility conditions. LO And high-mode energy efficiency optimization speed S HI When the probabilistic hybrid critical system is in low mode, the hybrid critical cyclic task operates at an energy-optimized speed S in low mode. LO When the probabilistic hybrid critical system is in high mode, the hybrid critical cyclic task operates at an energy-optimized speed S in high mode. HI implement.
[0112] The above description is only the preferred embodiment of the present application and the explanation of the technical principles. It should be understood by those skilled in the art that the scope of the protection of the present application is not limited to the technical solutions formed by the specific combinations of the above technical features. It should also cover other technical solutions formed by the combinations of the above technical features or their equivalent features without departing from the concept of the present application. For example, the technical solutions formed by the mutual replacement of the above features and the technical features with similar functions disclosed (but not limited to) in the present application.
Claims
1. A probabilistic mixed-critical system dynamic priority imprecise task energy saving scheduling method, characterized in that, The method comprises the following steps: S1, establishing a probabilistic mixed-critical system, and determining execution time of a mixed-critical periodic task in a worst case of probability, and calculating a probability utilization rate according to the execution time of the mixed-critical periodic task in the worst case of probability; S2, determining sufficient conditions for scheduling of the probabilistic mixed-critical system in a low mode and a high mode according to the probability utilization rate, and specifically comprising: the sufficient conditions for scheduling of the probabilistic mixed-critical system in the low mode are given by the following formula: ; or and the following applies: ; wherein, denotes the maximum value of the probability distribution denotes the task set the utilization probability distribution of the low mode, denotes the maximum value of which is less than 1; and denote the utilization probability distribution of the low mode of the low criticality level task set and the high criticality level task set, respectively; denotes the convolution of the two probability distributions; and denote the low criticality level task set and the high criticality level task set, respectively, denotes the mixed criticality periodic task the utilization distribution of the low mode; if the mixed criticality periodic task is a low criticality level task, ; if the mixed criticality periodic task is a high criticality level task, its , its value is equal to the value is truncated in the distribution; the truncation process is as follows: ; wherein, , and , , denotes the probability that the probabilistic hybrid critical system allows a failure; the sufficient conditions for scheduling of the probabilistic mixed-critical system in the high mode are given by the following formula: ; or and the following applies: ; wherein, denotes the maximum value in the probability distribution , denotes the task set in the high mode utilization probability distribution, denotes the maximum value in which the median is less than 1; and denote the low criticality level task set in the low mode utilization probability distribution and the high criticality level task set in the high mode utilization probability distribution, respectively; denotes the convolution of the two probability distributions; and denote the low criticality level task set and the high criticality level task set, respectively, denotes the mixed criticality periodic task in the low mode utilization distribution; if the mixed criticality periodic task is a low criticality level task, ; if the mixed criticality periodic task is a high criticality level task, , denotes the probability that the probability mixed criticality system allows a failure; S3, according to the condition of scheduling feasible, calculate the energy consumption optimization speed of low mode and the energy consumption optimization speed of high mode ; S4. when the probabilistic mixed-critical system is in a low mode, the mixed-critical periodic task is executed at an energy-optimized speed of the low mode performing, when the probabilistic mixed-critical system is in a high mode, the mixed-critical periodic task is executed at an energy-optimized speed of the high mode performing.
2. The probabilistic hybrid-critical system dynamic priority imprecise task power management scheduling method according to claim 1, wherein, The probabilistic mixed-criticality system comprises a task set comprising mutually independent mixed-criticality periodic tasks , a mixed-criticality periodic task is represented by wherein is the period of ; is the criticality level of , which takes the value or , is a low criticality level task, is a high criticality level task.
3. The probabilistic hybrid system dynamic priority imprecise tasking energy saving scheduling method of claim 2, wherein, In the step S1, the execution time of the mixed-critical periodic task in the worst case of probability is determined, and specifically comprising: is a mixed critical periodic task the worst-case execution time of the probability, whose value is expressed by the following equation: ; wherein, , respectively represent mixed critical periodic tasks minimum execution time and maximum execution time at the maximum processor speed; when mixed critical periodic tasks are low criticality level tasks, ; when tasks are high criticality level tasks, ; is the execution time of low criticality level tasks in high mode; is the time threshold for mode transition of high criticality level tasks; and respectively represent the probability of execution time and the distribution function; and ; the low mode refers to the execution time of all high criticality level mixed critical periodic tasks does not exceed and the execution time of all low criticality level key periodic tasks does not exceed ; the high mode refers to the execution time of all high criticality level mixed critical periodic tasks does not exceed and the execution time of low criticality level tasks does not exceed .
4. The probabilistic hybrid system dynamic priority imprecise task driven energy saving scheduling method according to claim 3, wherein, In the step S1, the probability utilization rate is calculated according to the execution time of the mixed-critical periodic task in the worst case of probability, and specifically comprising: Scheduling a task set using a pre-emptive dynamic priority policy, mixed critical periodic tasks Probability of utilization Is calculated by the following formula: ; wherein , , .
5. The probabilistic hybrid system dynamic priority imprecise tasking energy saving scheduling method of claim 1, wherein, The step S3 specifically comprises: When time, ; otherwise, ; representing a task set in low mode utilization probability distribution; When time, ; otherwise, ; denotes the task set in high mode of utilization probability distribution; denotes the convolution of two probability distributions.
6. The probabilistic hybrid system dynamic priority imprecise tasking energy saving scheduling method of claim 5, wherein, The step S4 specifically comprises: the probabilistic mixed-critical system starts in a low mode, all tasks are executed with low criticality; when a high criticality level task mixed-critical periodic task is executed, the execution time of which exceeds and the execution of which is not completed, or a low criticality level task mixed-critical periodic task is executed, the execution time of which exceeds ; the probabilistic mixed-critical system switches from the low mode to a high mode, in which all tasks are executed with high criticality; the execution time of a low criticality level mixed-critical periodic task does not exceed , otherwise the execution is terminated; when all high criticality level task mixed-critical periodic tasks are executed completely or the processor is in an idle state, the probabilistic mixed-critical system returns from the high mode to the low mode, in which all tasks are executed with low criticality.
7. A probabilistic hybrid critical system dynamic priority non-precise task energy-saving scheduling device, characterized in that, comprising: a probability utilization rate calculation module configured to establish a probabilistic mixed-critical system, and determine execution time of a mixed-critical periodic task in a worst case of probability, and calculate a probability utilization rate according to the execution time of the mixed-critical periodic task in the worst case of probability; a condition determination module configured to determine sufficient conditions for scheduling of the probabilistic mixed-critical system in a low mode and a high mode according to the probability utilization rate, and specifically comprising: the sufficient conditions for scheduling of the probabilistic mixed-critical system in the low mode are given by the following formula: ; or and the following applies: ; wherein, denotes the maximum value of the probability distribution denotes the task set the utilization probability distribution of the low mode, denotes the maximum value of which is less than 1; and denote the utilization probability distribution of the low mode of the low criticality level task set and the high criticality level task set, respectively; denotes the convolution of the two probability distributions; and denote the low criticality level task set and the high criticality level task set, respectively, denotes the mixed criticality periodic task the utilization distribution of the low mode; if the mixed criticality periodic task is a low criticality level task, ; if the mixed criticality periodic task is a high criticality level task, its , its value is equal to the value in the distribution, the truncation processing is performed; the truncation processing process is as follows: ; wherein, , and , , denotes the probability that the probabilistic hybrid critical system allows a failure; the sufficient conditions for scheduling of the probabilistic mixed-critical system in the high mode are given by the following formula: ; or and the following applies: ; in, Represents probability distribution The maximum value in, Represents task set In the utilization probability distribution of the high mode, express The maximum value where the median is less than 1; and These represent the utilization probability distributions of low-criticality task sets in low-mode task sets and high-criticality task sets in high-mode tasks, respectively. This represents the convolution of two probability distributions; and These represent the sets of low-criticality tasks and the sets of high-criticality tasks, respectively. Indicates a hybrid critical cycle task Utilization distribution in low-mode; if mixed critical cycle tasks It is a low-criticality task. If mixed critical cycle tasks It is a high-critical-level task. , This represents the probability that the probabilistic hybrid critical system is allowed to fail; The energy consumption speed calculation module is configured to calculate the energy consumption optimization speed of the low mode and the energy consumption optimization speed of the high mode according to the condition of the scheduling feasibility ; and ; an execution module configured to execute the mixed-critical periodic task at a low mode energy-optimized speed when the probabilistic mixed-critical system is in the low mode an execution module configured to execute the mixed-critical periodic task at a high mode energy-optimized speed when the probabilistic mixed-critical system is in the high mode an execution module configured to execute the mixed-critical periodic task at a high mode energy-optimized speed when the probabilistic mixed-critical system is in the high mode 8. An electronic device, comprising: one or more processors; a storage device for storing one or more programs, when the one or more programs are executed by the one or more processors, the one or more processors implement the method of any one of claims 1-6.
9. A computer-readable storage medium having stored thereon a computer program, characterized in that, The program is executed by the processor to implement the method of any one of claims 1-6.
Citation Information
Patent Citations
Hybrid key task energy consumption optimization scheduling method based on probability model
CN112633589A
Energy consumption sensing method and system for updating hybrid critical tasks by using fixed priority utilization rate
CN114578944A