Load awareness and task migration scheduling method of heterogeneous multi-core power terminal and related equipment
By collecting load status data in real time and constructing load state vectors and utility function models, the problem of real-time perception and migration decision-making of task scheduling strategies in heterogeneous multi-core power terminals was solved, achieving load balancing and performance optimization, and improving computing resource utilization and system stability.
Patent Information
- Application Number
- CN202511681815.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-17
- Publication Date
- 2026-01-30
AI Technical Summary
In existing technologies, the task scheduling strategy of heterogeneous multi-core power terminals cannot perceive the core load status in real time, resulting in low utilization of computing resources, lack of global optimality in migration decisions, and affecting the real-time performance and reliability of the terminal.
By collecting load status data in real time, constructing a load status vector, classifying tasks and calculating dynamic priorities, and combining global load imbalance and utility function models, the optimal migration scheme is generated to achieve intelligent task scheduling.
It improves task processing efficiency and operational stability, avoids system jitter and performance loss, and realizes real-time load balancing and optimal performance scheduling of heterogeneous multi-core power terminals.
Smart Images

Figure CN121433901A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a load sensing and task migration scheduling method and related equipment for a heterogeneous multi-core power terminal. Background Technology
[0002] In related technologies, with the rapid development of smart grids, the monitoring, control, and protection operations of power systems are placing increasingly higher demands on the computing power of the edge side. New power edge computing devices, such as distribution automation terminals (DTUs / FTUs) and intelligent converged terminals, are increasingly adopting a heterogeneous multi-core system-on-chip (HMPSoC) architecture, which integrates processors with multiple high-performance cores (such as the ARM Cortex-A series) and multiple energy-efficient cores (such as the ARM Cortex-M series). This architecture aims to balance the needs of high-performance computing with low-power operation.
[0003] However, the introduction of heterogeneous multi-core processors also brings new challenges to task scheduling. First, traditional scheduling strategies, mostly based on static load allocation or periodic detection mechanisms, cannot accurately perceive the real-time load status of each core, resulting in some cores being under high load for extended periods while others remain idle, leading to low utilization of computing resources. Second, existing methods often only consider CPU utilization or simple task queue length during task migration, failing to address the specific needs of power services and ignoring the coupling relationships between tasks. This results in migration decisions lacking global optimality and may even cause system jitter or increased latency. Furthermore, traditional migration mechanisms often use fixed threshold triggers, lacking the ability to quantitatively analyze and dynamically adjust the overall system imbalance, making it difficult to adapt to the diverse task types and complex operating states of power terminals, thus affecting the real-time performance and reliability of the terminals.
[0004] In summary, the technical problems existing in the relevant technologies need to be improved. Summary of the Invention
[0005] The main objective of this application is to propose a load sensing and task migration scheduling method and related equipment for heterogeneous multi-core power terminals, so as to achieve real-time load balancing and optimal performance scheduling of heterogeneous multi-core power terminals, thereby significantly improving task processing efficiency and operational stability.
[0006] To achieve the above objectives, one aspect of this application proposes a load awareness and task migration scheduling method for heterogeneous multi-core power terminals, the method comprising the following steps: Collect load status data for each processing core in a heterogeneous multi-core power terminal; Based on the load status data, a real-time load status vector is constructed; The tasks are categorized, and a dynamic priority is calculated for each categorized task to generate task priority data. Based on the real-time load state vector, the global load imbalance is calculated, and a set threshold is used to determine whether to trigger the task migration scheduling process. In the task migration scheduling process, a utility function model is constructed based on the task priority data; the utility function model is constructed based on the priority of the migration candidate tasks, the expected performance gain, and the migration cost. Based on the utility function model, the utility of the task-goal core is calculated to generate the optimal migration scheme. The task migration operation is performed based on the optimal migration scheme; the task migration operation includes pausing the source core task, saving the execution context, transferring context data, and resuming task execution on the target core.
[0007] In some embodiments, the load status data includes CPU utilization, cache utilization, and task queue wait time for each processing core.
[0008] In some embodiments, the real-time load state vector Calculated using the following weighted formula: ; in, Indicates core At the point of time CPU utilization; Indicates cache utilization; This indicates the average waiting time for the task; , and This indicates the configurable weighting coefficients.
[0009] In some embodiments, classifying tasks and calculating dynamic priorities for each classified task to generate task priority data includes: When a heterogeneous multi-core power terminal receives a task, it classifies the task according to its service type, real-time requirements, and resource requirements, and generates a corresponding task category. The task categories include: high real-time control tasks, periodic data acquisition tasks, non-periodic data analysis tasks, and network communication tasks. Based on the task categories, a dynamic priority evaluation model is constructed for each task; the dynamic priority evaluation model determines the current priority of the task through weighted calculation based on the task's basic priority, deadline urgency, and resource consumption. Based on the dynamic priority evaluation model, the dynamic priority of each task is calculated. Based on the dynamic priority, task priority data is generated.
[0010] In some embodiments, the global load imbalance is measured by the standard deviation or coefficient of variation of all core load state values.
[0011] In some embodiments, the step of calculating the utility of the task-goal core based on the utility function model and generating an optimal migration scheme includes: Based on the utility function model, the utility value of the combination relationship between each migration candidate task and multiple target cores is calculated to obtain the utility value of different task-target core pairs. Based on the utility value, all task-target core pairs are comprehensively compared, and the task-target core pair with the highest utility value is selected as the optimal migration scheme.
[0012] In some embodiments, the utility function model Calculated using the following formula: ; in, For the task Priority; For the expected performance gain; For the cost of migration; For decision weights.
[0013] In some embodiments, the migration cost Calculated using the following formula: ; in, Tasks awaiting migration; As the core source; The core objective; For the task Context saving and recovery time; For task-related data in the core and Estimated transmission time between them; The estimated additional energy consumption for performing the migration process.
[0014] In some embodiments, the method further includes: After the task migration operation is performed, the actual execution time and energy consumption feedback results are continuously monitored, and the weight coefficients in the load state vector and utility function model are automatically adjusted using machine learning algorithms based on the deviation between the actual value and the estimated value.
[0015] To achieve the above objectives, another aspect of this application proposes a load awareness and task migration scheduling system for heterogeneous multi-core power terminals, the system comprising: The load data acquisition module is used to collect load status data of each processing core in the heterogeneous multi-core power terminal. The first construction module is used to construct a real-time load status vector based on the load status data; The task priority module is used to classify tasks, calculate dynamic priorities for each task, and generate task priority data. The load assessment module is used to calculate the global load imbalance based on the real-time load status vector, and determine whether to trigger the task migration scheduling process according to the set threshold. The second construction module is used to construct a utility function model based on the task priority data in the task migration and scheduling process. The migration optimization module is used to perform utility calculations on the task-target core based on the utility function model and generate the optimal migration scheme. The task migration control module is used to perform task migration operations based on the optimal migration scheme.
[0016] To achieve the above objectives, another aspect of this application provides a power edge computing device, which includes a heterogeneous multi-core processor, a memory, and a communication interface. The memory stores a computer program, and the processor executes the computer program to implement the above-described method.
[0017] To achieve the above objectives, another aspect of the embodiments of this application proposes a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described method.
[0018] To achieve the above objectives, another aspect of this application provides a computer program product, including a computer program that, when executed by a processor, implements the above-described method.
[0019] The embodiments of this application include at least the following beneficial effects: This application provides a load perception and task migration scheduling method and related equipment for heterogeneous multi-core power terminals. This scheme collects load status data of each processing core in real time and constructs a load status vector, thereby accurately reflecting the operating status and resource occupancy of each core, providing data support for subsequent scheduling. By classifying tasks and calculating dynamic priorities, the scheduling strategy can combine the real-time requirements of tasks, resource consumption characteristics, and business importance to achieve differentiated scheduling decisions. Through dynamic calculation of global load imbalance, it can adaptively determine whether to trigger the task migration process, avoiding system jitter and performance loss caused by frequent migration. In the task migration stage, a utility function model is introduced to uniformly quantify and evaluate task priority, expected performance gain, and migration cost. The optimal migration scheme is selected through the principle of maximizing utility, thereby realizing intelligent and optimized migration decision-making. Attached Figure Description
[0020] Figure 1 This is a flowchart illustrating a load sensing and task migration scheduling method for a heterogeneous multi-core power terminal provided in an embodiment of this application. Figure 2 yes Figure 1 A flowchart illustrating step S3 in the process; Figure 3 yes Figure 1 The flowchart of step S6 is shown. Detailed Implementation
[0021] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of this application and are not intended to limit it. In the following description, when referring to the accompanying drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with those of this application; they are merely examples of apparatuses and methods consistent with some aspects of the embodiments of this application as detailed in the appended claims.
[0022] It is understood that the terms “first,” “second,” etc., used in this application may be used herein to describe various concepts, but unless otherwise stated, these concepts are not limited by these terms. These terms are only used to distinguish one concept from another. For example, without departing from the scope of the embodiments of this application, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the words “if,” “when,” or “in response to a determination” as used herein may be interpreted as “when…” or “when…” or “in response to a determination.”
[0023] As used in this application, the terms "at least one", "multiple", "each", "any", etc., "at least one" includes one, two or more, "multiple" includes two or more, "each" refers to each of the corresponding multiples, and "any" refers to any one of the multiples.
[0024] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.
[0025] This application provides a load sensing and task migration scheduling method and related equipment for a heterogeneous multi-core power terminal. This scheme collects load status data from each processing core in real time and constructs a load status vector, thereby accurately reflecting the operating status and resource consumption of each core, providing data support for subsequent scheduling. By classifying tasks and calculating dynamic priorities, the scheduling strategy can combine the real-time requirements, resource consumption characteristics, and business importance of tasks to achieve differentiated scheduling decisions. Through dynamic calculation of global load imbalance, it can adaptively determine whether to trigger the task migration process, avoiding system jitter and performance loss caused by frequent migrations. During the task migration stage, a utility function model is introduced to uniformly quantify and evaluate task priority, expected performance gain, and migration cost. The optimal migration scheme is selected based on the principle of maximizing utility, thereby achieving intelligent and optimized migration decision-making.
[0026] This application provides a load sensing and task migration scheduling method and related equipment for a heterogeneous multi-core power terminal, relating to the field of computer technology. The load sensing and task migration scheduling method for a heterogeneous multi-core power terminal provided in this application can be applied to a terminal, a server, or software running on a terminal or server. In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, smart speaker, smartwatch, or vehicle terminal, but is not limited to these; the server can be configured as an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. The server can also be a node server in a blockchain network; the software can be an application implementing a load sensing and task migration scheduling method for a heterogeneous multi-core power terminal, but is not limited to the above forms.
[0027] This application can be used in a wide variety of general-purpose or special-purpose computer system environments or configurations. Examples include: personal computers, server computers, handheld or portable devices, tablet devices, multiprocessor systems, microprocessor-based systems, set-top boxes, programmable consumer electronics devices, network PCs, minicomputers, mainframe computers, and distributed computing environments including any of the above systems or devices. This application can be described in the general context of computer-executable instructions executed by a computer, such as program modules. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform specific tasks or implement specific abstract data types. This application can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.
[0028] Please see Figure 1-3 As shown, this invention relates to a load sensing and task migration scheduling method and related equipment for a heterogeneous multi-core power terminal.
[0029] Figure 1 This is an optional flowchart of a load awareness and task migration scheduling method for a heterogeneous multi-core power terminal provided in an embodiment of this application. Figure 1 The method may include, but is not limited to, steps S1 to S7: S1: Collect load status data for each processing core in the heterogeneous multi-core power terminal; the load status data includes the CPU utilization, cache utilization, and task queue waiting time of each processing core. In this embodiment, the heterogeneous multi-core power terminal includes a performance core, a high-efficiency core, and a dedicated signal processing core.
[0030] During operation, a fixed sampling period is set to collect the operating status of each processing core. The sampling period can be between 50ms and 100ms to balance real-time performance and data stability.
[0031] The collected load status data includes the following: CPU utilization data: Instantaneous utilization is calculated by reading the number of instructions executed and the number of clock cycles from the performance counter unit inside the processing core; a moving average method is used to smooth the utilization within consecutive sampling periods to eliminate fluctuations caused by transient task switching; for performance cores, a shorter sampling window can be set to improve response accuracy.
[0032] Cache utilization data: The cache utilization ratio is calculated by recording the number of cache accesses and cache hits of the core within the sampling period. To reflect the cache characteristics of different task types, the statistical interval can be reset when switching tasks, so that the cache utilization can reflect the real-time task characteristics. When the cache utilization exceeds the threshold for a long period of time, it can be determined that the core is experiencing cache contention or memory access latency backlog.
[0033] Task queue waiting time data: The average waiting time is calculated by recording the time interval from when a task enters the execution queue to when it starts execution, and within the sampling period. The average waiting time is calculated separately for periodic tasks and real-time tasks to reflect the scheduling sensitivity of different task categories. When the average waiting time continues to increase, it indicates that the core is experiencing load accumulation and needs to be identified as a candidate core for migration in subsequent scheduling.
[0034] All collected load status data are accompanied by a unified timestamp and undergo time synchronization processing to form a continuous time-series data sequence. This method enables real-time and accurate reflection of the dynamic operating load of each core in a heterogeneous multi-core power terminal, providing a highly timely data foundation for subsequent load vector calculations.
[0035] S2: Construct a real-time load state vector based on load state data; where the real-time load state vector... Calculated using the following weighted formula: ; in, Indicates core At the point of time CPU utilization reflects the level of workload of computing resources; This indicates the last-level cache (LLC) utilization or miss rate of core j, reflecting the intensity of memory access and potential memory bottlenecks; This represents the average waiting latency of the task ready queue in core j, directly reflecting the task response speed; , and Represents the normalized weighting coefficients. These weights can be initially configured based on specific hardware platforms and business scenarios, and then dynamically adjusted by subsequent feedback mechanisms.
[0036] In this embodiment, after collecting the load status data of each processing core, the load status data is organized, analyzed and fused to form a real-time load status vector that can comprehensively characterize the operating load of each core.
[0037] First, the collected data on CPU utilization, cache usage, and task queue wait time are normalized. Normalization aims to eliminate the influence of differences in hardware parameters, operating frequencies, and cache structures among different cores, enabling comprehensive analysis of different data types under the same evaluation scale.
[0038] Then, the normalized data is weighted and fused according to a set weight ratio. The weight ratio can be dynamically adjusted according to the power terminal's operation strategy or business model. When the terminal is in high-performance operation mode, focus on computing load and appropriately increase the weight of CPU utilization. When the terminal is in energy-saving or low-power mode, more attention is paid to task response efficiency, which can increase the proportion of task waiting time. In scenarios with frequent communication or data interaction, the proportion of cache usage can be appropriately increased to reflect the impact of data access bottlenecks.
[0039] During the weighted fusion process, the results within the continuous sampling period are processed by time-moving average to eliminate errors caused by short-term fluctuations, so that the final load state vector can reflect the stable operating trend of the core over a period of time.
[0040] Finally, the load state vectors of all processing cores are combined in core number order to form a complete global load state set. This set can dynamically reflect the overall operational balance of the heterogeneous multi-core power terminals at the current moment, providing a quantitative basis for subsequent task classification, load imbalance judgment, and migration decisions.
[0041] By using the above methods, the construction of the load state vector not only achieves real-time perception of different cores, but also takes into account temporal continuity and cross-core comparability, laying a reliable data foundation for subsequent intelligent scheduling.
[0042] S3: Classify tasks and calculate dynamic priorities for each classified task to generate task priority data; Among them, reference Figure 2 As shown, tasks are categorized, and dynamic priorities are calculated for each categorized task to generate task priority data, including but not limited to the following steps: S31: When the heterogeneous multi-core power terminal receives a task, it classifies the task according to the service type, real-time requirements and resource demand characteristics of the task, and generates the corresponding task category; among which, the task categories include: high real-time control task, periodic data acquisition task, non-periodic data analysis task and network communication task. In this embodiment, when the power terminal receives a task request, it first determines the task based on the task source, function identifier, and execution characteristics.
[0043] The classification criteria for tasks are mainly based on three aspects: Business type characteristics: Distinguish the functional attributes of tasks in power business, such as protection and control, data acquisition, status analysis, communication and interaction, etc. Real-time requirements: Determine the timeliness level based on the task response time limit and execution cycle; Resource requirement characteristics: Classify the CPU, storage and I / O bandwidth usage based on the task.
[0044] Based on the above criteria, the tasks are divided into the following four categories: High real-time control tasks: such as relay protection, automatic power distribution control, fault isolation, etc. These tasks have strong real-time requirements and allow for extremely low maximum response delay. Periodic data acquisition tasks: such as timed acquisition operations of voltage, current, frequency, etc., with a fixed execution cycle, which need to be completed stably within the cycle; Non-periodic data analysis tasks, such as load forecasting, condition assessment, and trend analysis, involve large computational loads but have relatively low real-time requirements. Network communication tasks include data reporting and remote control command reception. They are sensitive to communication latency but have a relatively light computational load.
[0045] After the tasks are categorized, each task is labeled with its category attribute to provide a basis for subsequent priority calculations.
[0046] S32: Based on task category, construct a dynamic priority evaluation model for each task; the dynamic priority evaluation model determines the current priority of the task through weighted calculation based on the task's basic priority, deadline urgency, and resource consumption. In this embodiment, after the tasks are classified, a dynamic priority evaluation model is established for different task categories.
[0047] This evaluation model takes into account the following three key factors: Basic task priority: Assign initial weights based on task category. For example, high real-time control tasks have the highest basic priority, followed by periodic data acquisition tasks, while data analysis and communication tasks have relatively lower basic priority. Deadline urgency: As the current time approaches the task deadline, the urgency of the task gradually increases, thus dynamically raising its priority. This mechanism embodies the "Earliest Deadline First" (EDF) principle. Resource consumption: Tasks with high CPU and memory consumption have higher migration or scheduling costs, and their priority should be adjusted appropriately based on resource sensitivity during priority evaluation.
[0048] During the priority assessment process, the weights of various factors can be dynamically adjusted according to the scheduling strategies of different scenarios. For example, when the power terminal is under high load, the weight of the deadline factor can be appropriately increased to ensure critical real-time tasks; when the terminal is under low load or in energy-saving operation mode, the weight of the resource consumption factor can be increased to reduce overall energy consumption.
[0049] S33: Based on the dynamic priority evaluation model, the dynamic priority of each task is calculated; In this embodiment, after establishing the priority evaluation model, the real-time priority value of each task is calculated based on the task information collected at the current time.
[0050] In the calculation process, the basic priority, deadline urgency, and resource consumption of each task are first standardized to eliminate differences in units and ensure the comparability of different factors. Then, according to the weight ratio set by the evaluation model, the factors are weighted and combined to obtain the current priority value of the task.
[0051] During execution, the priority of a task is not fixed, but is dynamically adjusted according to the task status: When a task is in the waiting queue and its remaining execution time is close to the deadline, its priority will be significantly increased. When a task is partially completed and the remaining execution workload is small, its priority can be appropriately reduced to free up computing resources for time-sensitive tasks. For tasks that consume resources for a long time but yield low returns, their priority should be continuously reduced over multiple cycles to prevent resources from being inefficiently used. When an abnormal task execution is detected (such as an abnormal increase in waiting delay or data transmission blockage), its priority is temporarily increased, and resources are prioritized to restore normal task execution.
[0052] In addition, to prevent scheduling jitter caused by frequent priority fluctuations, a priority update time interval threshold can be set so that priority adjustments are carried out within a fixed period, thus maintaining scheduling stability.
[0053] After priority calculation is completed, a uniform priority sequence is generated for all tasks, and they are sorted from highest to lowest priority value. The sorting result reflects the importance order of tasks at the current moment, providing a basis for subsequent load balancing judgments and task migration.
[0054] This dynamic calculation and periodic update mechanism enables task priorities to be adjusted in real time according to changes in business status and system load, ensuring that high real-time power tasks are given priority response, while improving the overall utilization efficiency of heterogeneous multi-core resources.
[0055] Specifically, the formula for calculating dynamic priority is as follows: ; in, Indicates the time point of the task. The dynamic priority value; This indicates the basic priority of a task, determined by its business type (e.g., protection tasks > control tasks > data analysis tasks). Indicates the deadline for the task; Indicates the current system time, when The smaller the value, the closer the task deadline is; its priority item... Increasing the value raises the scheduling priority, reflecting the "Earliest Deadline First (EDF)" principle. This indicates the resource consumption assessment value of a task. For example, tasks that consume critical I / O or require a large amount of memory can have their priority increased to ensure resource supply. , and This represents the weighting coefficient used in priority calculations.
[0056] S34: Generate task priority data based on dynamic priority.
[0057] S4: Based on the real-time load state vector, calculate the global load imbalance and determine whether to trigger the task migration scheduling process according to the set threshold; the global load imbalance is measured by the standard deviation or coefficient of variation of all core load state values.
[0058] Specifically, global load imbalance It can be represented by the coefficient of variation of all core load indices: in, It is the total number of core members; This indicates that core j is at time point. Real-time load status value; It is the average load index across all cores. When Greater than the set threshold At that time, the migration process is triggered.
[0059] In this embodiment, after obtaining the real-time load state vector of each processing core, the load level of all cores is comprehensively analyzed to evaluate the overall load balance of the multi-core power terminal.
[0060] First, the load values of each core at the same sampling time are compared horizontally. By statistically analyzing the dispersion of load differences between cores, it can be seen whether there is a significant deviation in the overall resource allocation. When the load of some cores is consistently higher than that of other cores, it indicates that the core may be undertaking too many tasks, while other cores have idle resources.
[0061] Secondly, a longitudinal analysis is performed on the load change trend across multiple sampling periods in a continuous time series. If the load fluctuation exceeds a preset stable range within a certain time window, or if the load of some core components remains consistently higher than the global average level, the system is determined to have entered an unbalanced state.
[0062] The analysis results are then compared with a preset imbalance threshold. The imbalance threshold can be adjusted according to different operational objectives. When prioritizing task response speed, the threshold is set low to trigger migration promptly. When prioritizing energy saving or stability, a higher threshold is set to reduce performance fluctuations caused by frequent migrations.
[0063] When the calculation result exceeds the set threshold, it indicates that there has been a significant deviation in the load distribution among multiple cores, and the task migration scheduling process should be initiated; if the threshold is not exceeded, the current task allocation status is maintained, only the load monitoring record is updated, and the process waits for the next cycle judgment.
[0064] This step enables adaptive judgment of the overall operating status, ensuring that task migration operations are triggered only when necessary, thereby balancing real-time performance and system stability, and avoiding ineffective migrations and additional energy consumption.
[0065] S5: In the task migration scheduling process, a utility function model is constructed based on the task priority data; the utility function model is constructed based on the priority of the migration candidate tasks, the expected performance gain, and the migration cost. In this embodiment, after determining that task migration scheduling is required, priority evaluation and utility analysis are performed on the tasks to be migrated in order to construct a utility function model that comprehensively considers performance gains and migration costs.
[0066] Migrationable tasks are selected from overloaded cores. Selection criteria include task type, real-time requirements, runtime, and resource consumption characteristics. Tasks with strong core-binding dependencies are kept running in their current positions, while unbound tasks, periodic computation tasks, or tasks with long latency are considered as migration candidates.
[0067] By combining task priority data, a dynamic priority is determined for each candidate task. The dynamic priority comprehensively considers the task's business type, deadline urgency, and current resource usage. For example, in power control scenarios, relay protection and fault handling tasks have higher priorities, while periodic data acquisition tasks have lower priorities. As task execution progresses, the priority can be adjusted in real time based on changes in deadlines and delays, making the scheduling process time-adaptive.
[0068] After identifying the candidate tasks, a quantitative analysis of the potential benefits and costs of task migration was conducted, as follows: Migration benefits: refers to the reduction in execution time and queue latency resulting from the lower load on the target core after a task is migrated to the target core; Migration costs include the time required to pause task execution, the latency of saving and transferring task context, and the performance loss caused by reloading the cache. Priority trade-offs: Consider the positive impact of the task on overall real-time performance and critical business processing capabilities after migration.
[0069] After comprehensively considering the above three factors, a utility evaluation mechanism is established to calculate the overall benefit level between the migration candidate task and the target core. If the performance gain brought by the task migration is higher than the migration cost, the task is selected as the efficient migration target; otherwise, the original core continues to execute.
[0070] In the utility analysis process, to avoid scheduling fluctuations caused by frequent migrations, an upper limit on the number of migrations can be set, and a minimum migration interval can be set to ensure the stability and predictability of scheduling behavior.
[0071] This step enables migration decisions based on task characteristics and real-time feedback, allowing task migration to be based on quantitative assessment, thereby achieving an optimal balance between performance improvement, real-time response, and energy consumption control.
[0072] S6: Based on the utility function model, perform utility calculations on the core task-goal relationship to generate the optimal migration plan; Among them, reference Figure 3 As shown, based on the utility function model, the utility of the task-goal core is calculated to generate the optimal migration plan, including but not limited to the following steps: S61: Based on the utility function model, the utility value of the combination relationship between each transfer candidate task and multiple target cores is calculated to obtain the utility value of different task-target core pairs; In this embodiment, the calculation process of utility value takes into account the following three aspects: Task priority factors: The priority of each task reflects its importance and timeliness in the current power business scenario. Tasks with high real-time control requirements or those nearing their deadlines have higher priority weights and therefore have a greater impact on migration requirements in utility assessments.
[0073] Expected performance gains: This factor measures the potential performance improvements a task may experience after migration, including reduced execution time, shorter queuing times, and improved response latency. During the evaluation process, the expected performance of the task running on the target core is predicted based on its performance characteristics (such as clock speed, cache capacity, and processing power) and the current load level. Higher computing power or shorter execution queues on the target core result in greater expected gains.
[0074] Migration cost factors: Migration cost reflects the additional overhead required for a task to migrate across cores, including the time for saving and resuming the context of the paused task, the latency of transferring task data between cores, and the performance loss caused by cache reloading. For tasks with large amounts of data or complex execution states, the migration cost is relatively high, thus playing a negative moderating role in utility calculation.
[0075] When performing utility calculations, adjustments need to be made to account for the structural differences between different types of cores. For example, when a candidate task is migrated from a high-efficiency core to a high-performance core, the expected performance gain is usually greater, while when migrating from a high-performance core to an energy-efficient core, a balance between potential performance degradation and energy efficiency improvement must be considered.
[0076] By comprehensively analyzing the above three factors, the utility value of each "task-target core" combination can be obtained. The magnitude of the utility value directly reflects the overall benefit of migrating the task to the target core, providing a basis for selecting the optimal migration plan.
[0077] S62: Based on the utility value, a comprehensive comparison is made of all task-target core pairs, and the task-target core pair with the highest utility value is selected as the optimal migration scheme.
[0078] In this embodiment, after obtaining the utility values of all task-target core pairs, these utility values are sorted and filtered.
[0079] When comparing the utility outcomes of different combinations, prioritize the following two scenarios: Task migration can significantly improve overall load balancing and reduce the pressure on high-load cores; The task has a high priority and migration can significantly reduce latency or improve execution efficiency.
[0080] If multiple combinations have similar utility values during the screening process, the selection will be further optimized based on the following strategies: Prioritize solutions with lower migration costs to reduce the additional time loss caused by context switching and data transfer; If the migration costs are comparable, choose the option that offers greater performance gains. When multiple tasks compete on the same core, a secondary comparison can be made based on the task category weights, allowing critical tasks to have priority in migration opportunities.
[0081] After selecting the optimal solution, the "task-target core" mapping is marked as the migration plan for the current period. This migration plan includes the task identifier, source core number, target core number, and expected performance improvement indicators, which are used to guide subsequent task migration execution steps.
[0082] To prevent jitter caused by frequent migrations, the migration status can be recorded after the task migration is completed, and a cooldown period window can be set so that the task will not participate in the migration evaluation again for a short period of time. This mechanism ensures the stability of migration decisions and the consistency of execution.
[0083] Through the above process, it is possible to achieve refined evaluation and selection of different task and target core combinations in multi-core power terminals, so that migration behavior is based on quantitative analysis and priority constraints, thereby improving the overall computing resource utilization and scheduling efficiency while ensuring real-time performance.
[0084] Specifically, utility function model Calculated using the following formula: ; in, For the task Priority; The expected performance gain, primarily reflected in reduced execution time, is achieved through heterogeneous cores with varying computing capabilities. (This can be obtained through benchmarking), task The computational cost is ; For the cost of migration; For decision weights.
[0085] Specifically, migration cost Calculated using the following formula: ; in, Tasks awaiting migration; As the core source; The core objective; For the task The context saving and restoring time depends primarily on the size of the task state. (Such as the number of registers, stack size) and processor architectural characteristics. This can be approximated as... ; For task-related data in the core and The estimated transmission time depends on the amount of data in the task. and core Effective communication bandwidth between ; The estimated additional energy consumption for performing the migration process.
[0086] Among them, context saving and recovery time With task status size Related to the core architecture; data transmission time With task data volume Communication bandwidth between the core and the core related.
[0087] Specifically, expected performance gain Through the task At the core of the goal The expected reduction in execution time on the source core The reduction in queuing time can be used to assess this, and can be estimated as follows: ; in, Indicates task The computational workload is typically measured by the number of task instructions, computation cycles, or data processing volume; it reflects the computational density and processing complexity of the task. and Representing the source core With the core of the target The computational performance parameters can be obtained through offline benchmarking, reflecting the workload that each core can complete per unit of time. Generally, the more powerful the core, the greater its computational performance. The larger the value; : Indicates task At the source core The estimated execution time is as follows; : Indicates task At the core of the goal The estimated execution time is as follows; and They represent time. At any moment, the core of the source With the core of the target The average task queuing latency reflects the task queue load on different cores. Larger and If the difference is smaller, migration can significantly reduce task latency; the difference between the two... This is the reduction in waiting time.
[0088] S7: Execute task migration operations based on the optimal migration scheme; the task migration operations include pausing the source core task, saving the execution context, transferring context data, and resuming task execution on the target core.
[0089] In this embodiment, after determining the optimal migration scheme, the task migration operation is executed sequentially according to the preset migration process to ensure a smooth switch and correct recovery of the task from the source core to the target core.
[0090] First, pause the execution of the selected migration task on the source core. The pause operation should be performed at a safe point in the task's execution, i.e., when the task is not in a critical resource access or interrupt handling process, to prevent state loss or data inconsistency. During the pause, record the task's current execution context information, including program counter location, register state, stack pointer, local variables, and task execution state identifiers.
[0091] Secondly, the execution context of the task is packaged and saved. The context data is saved using a lightweight structure, extracting only the critical runtime information necessary for task recovery to reduce data volume and shorten migration latency. After packaging, the context data is written to a shared storage area or temporary buffer, along with verification information to ensure transmission integrity.
[0092] Subsequently, the saved context data is transferred to the target core. Data transfer can take different forms depending on the characteristics of the inter-core communication channel: When the cores share the same physical memory, data mapping can be performed by directly referencing the shared address area; When cores need to communicate via an interconnect bus, asynchronous transmission combined with a verification mechanism can be used to ensure that data arrives accurately.
[0093] After successful transfer of context data, task recovery is performed on the target core. The recovery process includes loading register states, rebuilding the task stack and memory page table mappings, and resetting the task's execution flag. To prevent cache inconsistencies, a cache flush operation can be performed before recovery to clear any residual data. Once recovery is complete, the task is inserted into the target core's ready queue, awaiting scheduling.
[0094] After the task is restarted, its execution time and response latency continue to be monitored. If the execution performance of the migrated task meets expectations and the overall system energy consumption does not increase significantly, the migration is considered successful. If execution anomalies, increased latency, or increased energy consumption occur, the migration parameters can be adaptively adjusted in subsequent scheduling cycles.
[0095] In addition, to prevent tasks from being migrated multiple times in a short period of time, a migration cooldown window can be set, preventing the same task from being repeatedly scheduled and migrated within a certain period. This mechanism helps maintain scheduling stability and avoids performance fluctuations caused by frequent migrations.
[0096] Through the above steps, efficient and reliable task migration across cores can be achieved within a heterogeneous multi-core power terminal. This ensures the pressure relief of high-load cores and makes full use of the computing power of idle cores, thereby significantly improving the real-time performance of task execution and overall resource utilization.
[0097] In one embodiment, the method further includes: after performing the task migration operation, continuously monitoring the actual execution time and energy consumption feedback results, and automatically adjusting the weight coefficients in the load state vector and utility function model using a machine learning algorithm based on the deviation between the actual value and the estimated value.
[0098] In this embodiment, after the task migration operation is completed, the execution status of the migrated task is continuously tracked to evaluate the actual performance of the migration effect, and the scheduling model is adaptively optimized through a feedback learning mechanism.
[0099] The execution time of the migration task is continuously monitored. This monitoring starts at the migration completion time and records the task's startup latency, execution duration, and overall completion time on the target core. By comparing the actual execution time with the execution time estimated in the utility function model before migration, it can be determined whether the migration plan has achieved the expected performance improvement. When the actual execution time is significantly lower than the estimated value, it indicates that the migration has brought significant benefits; conversely, if the execution time increases, it indicates that there is a deviation in the model's estimation of migration costs or performance prediction.
[0100] The energy consumption changes after migration are measured and analyzed. By collecting data on the power changes of the target core before and after migration and the average power consumption during task execution, the impact of task migration on overall energy efficiency can be obtained. If energy consumption decreases and performance remains stable after migration, it indicates that the scheduling strategy has achieved effective energy consumption optimization; if energy consumption increases and performance improvement is limited, it indicates that the weight allocation focuses too much on performance factors, and the weight balance should be appropriately adjusted.
[0101] After obtaining actual execution time and energy consumption feedback data, the deviation between these data and the estimated values from the utility function model is compared, triggering an automatic optimization process. This optimization process uses machine learning algorithms to dynamically update the weight coefficients in the load state vector and the utility function model.
[0102] Specifically, an algorithmic framework based on reinforcement learning or adaptive control can be adopted: When the utility function model overestimates the task's benefits in the long run, the weights related to performance benefits are automatically reduced. When the utility function model underestimates the cost of migration or energy consumption, the cost weight is increased to suppress high-risk migration; When the load prediction error is large, the weight ratio of each indicator in the load state vector (such as CPU utilization, cache utilization, and wait latency) is readjusted to make the load representation more closely reflect the actual operating conditions.
[0103] Through the aforementioned feedback learning mechanism, long-term adaptive adjustments to scheduling parameters can be achieved, enabling continuous optimization of the load perception and utility function model. Over time, the prediction accuracy of the model under different load patterns and task characteristics gradually improves, thereby achieving higher resource utilization efficiency and energy consumption synergistic optimization in the heterogeneous multi-core environment of power terminals.
[0104] This application also provides a load sensing and task migration scheduling system for a heterogeneous multi-core power terminal, the system comprising: The load data acquisition module is used to collect load status data of each processing core in the heterogeneous multi-core power terminal. The first construction module is used to construct a real-time load status vector based on the load status data; The task priority module is used to classify tasks, calculate dynamic priorities for each task, and generate task priority data. The load assessment module is used to calculate the global load imbalance based on the real-time load status vector, and determine whether to trigger the task migration scheduling process according to the set threshold. The second construction module is used to construct a utility function model based on the task priority data in the task migration and scheduling process. The migration optimization module is used to perform utility calculations on the task-target core based on the utility function model and generate the optimal migration scheme. The task migration control module is used to perform task migration operations based on the optimal migration scheme.
[0105] It is understood that the content of the above method embodiments is applicable to this system embodiment. The specific functions implemented in this system embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.
[0106] This application also provides a power edge computing device, which includes a heterogeneous multi-core processor, a memory, and a communication interface. The memory stores a computer program, and the heterogeneous multi-core processor executes the computer program to implement the above-described method. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.
[0107] It is understood that the content of the above method embodiments is applicable to this device embodiment. The specific functions implemented by this device embodiment are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0108] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described method.
[0109] It is understood that the content of the above method embodiments is applicable to this storage medium embodiment. The specific functions implemented in this storage medium embodiment are the same as those in the above method embodiments, and the beneficial effects achieved are also the same as those achieved in the above method embodiments.
[0110] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the above-described method.
[0111] It is understood that the content of the above method embodiments is applicable to the embodiments of this program product. The specific functions implemented by the embodiments of this program product are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0112] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. Furthermore, memory may include high-speed random access memory, and may also include non-transitory memory, such as at least one disk storage device, flash memory device, or other non-transitory solid-state storage device. In some embodiments, memory may optionally include memory remotely located relative to the processor, and these remote memories can be connected to the processor via a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
[0113] This application provides a load sensing and task migration scheduling method and related equipment for a heterogeneous multi-core power terminal. This scheme collects load status data from each processing core in real time and constructs a load status vector, thereby accurately reflecting the operating status and resource consumption of each core, providing data support for subsequent scheduling. By classifying tasks and calculating dynamic priorities, the scheduling strategy can combine the real-time requirements, resource consumption characteristics, and business importance of tasks to achieve differentiated scheduling decisions. Through dynamic calculation of global load imbalance, it can adaptively determine whether to trigger the task migration process, avoiding system jitter and performance loss caused by frequent migrations. During the task migration stage, a utility function model is introduced to uniformly quantify and evaluate task priority, expected performance gain, and migration cost. The optimal migration scheme is selected based on the principle of maximizing utility, thereby achieving intelligent and optimized migration decision-making.
[0114] The embodiments described in this application are for the purpose of more clearly illustrating the technical solutions of the embodiments of this application, and do not constitute a limitation on the technical solutions provided by the embodiments of this application. As those skilled in the art will know, with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of this application are also applicable to similar technical problems.
[0115] Those skilled in the art will understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of this application, and may include more or fewer steps than shown, or combine certain steps, or different steps.
[0116] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0117] Those skilled in the art will understand that all or some of the steps in the methods disclosed above, as well as the functional modules / units in the systems and devices, can be implemented as software, firmware, hardware, or suitable combinations thereof.
[0118] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0119] The preferred embodiments of the present application have been described above with reference to the accompanying drawings, but this does not limit the scope of the claims of the present application. Any modifications, equivalent substitutions, and improvements made by those skilled in the art without departing from the scope and substance of the embodiments of the present application shall be within the scope of the claims of the present application.
Claims
1. A load-aware and task migration scheduling method for a heterogeneous multi-core power terminal, characterized in that, The method comprises the following steps: Collecting load state data of each processing core in a heterogeneous multi-core power terminal; Based on the load state data, constructing a real-time load state vector; Classifying tasks and calculating the dynamic priority of each classified task to generate task priority data; Based on the real-time load state vector, calculating the global load imbalance degree and determining whether to trigger the task migration scheduling process according to the set threshold; In the task migration scheduling process, constructing an utility function model according to the task priority data; the utility function model is constructed based on the priority of the migration candidate task, the expected performance gain and the migration cost; According to the utility function model, performing utility calculation on the task-target core to generate an optimal migration scheme; Based on the optimal migration scheme, performing task migration operation; the task migration operation includes suspending the source core task, saving the execution context, transferring the context data and resuming the task running on the target core.
2. The method of claim 1, wherein, The load state data includes CPU utilization, cache occupancy and task queue waiting time of each processing core.
3. The method of claim 1, wherein, the real-time load state vector weighted by the following equation: ; wherein, represents the core at a point in time CPU utilization; represents the cache occupancy rate; represents the average task waiting delay; , and represent configurable weight coefficients.
4. The method of claim 1, wherein, The task classification and dynamic priority calculation of each classified task to generate task priority data comprises: When the heterogeneous multi-core power terminal receives a task, the task is classified according to the business type, real-time requirement and resource demand characteristics of the task to generate corresponding task categories; the task categories include high real-time control tasks, periodic data collection tasks, non-periodic data analysis tasks and network communication tasks; Based on the task categories, a dynamic priority evaluation model is constructed for each task; the dynamic priority evaluation model determines the current priority of the task through weighted calculation based on the basic priority, deadline urgency and resource occupancy degree of the task; Based on the dynamic priority evaluation model, the dynamic priority of each task is calculated; According to the dynamic priority, task priority data is generated.
5. The method of claim 1, wherein, The global load imbalance degree is measured by the standard deviation or coefficient of variation of all core load state values.
6. The method of claim 1, wherein, According to the utility function model, the utility value of each migration candidate task and multiple target cores is calculated to obtain the utility value of different task-target core pairs; According to the utility value, all task-target core pairs are compared comprehensively to select the task-target core pair with the highest utility value as the optimal migration scheme. The method further comprises:
7. The method of claim 6, wherein, The utility function model is calculated by the equation: ; wherein, is a priority of the task ; is an expected performance gain; is a migration cost; is a decision weight.
8. The method of claim 7, wherein, the migration cost is calculated by the following equation: ; wherein, is the task to be migrated; is the source core; is the target core; is the task context save and restore time; is the estimated time for the task related data transfer between cores and ; and is the estimated additional energy consumption for performing the migration process.
9. The method of claim 1, wherein, After performing the task migration operation, the actual execution time and energy consumption feedback results are continuously monitored, and the weight coefficients in the load state vector and the utility function model are automatically adjusted according to the deviation between the actual value and the estimated value by using a machine learning algorithm. The running state of the power edge computing device is controlled by the method of any one of claims 1 to 9.
10. An electric power edge computing device comprising a heterogeneous multi-core processor, a memory and a communication interface, characterized in that,
Citation Information
Cited By
A processor, a processor resource configuration method, a storage medium and a program product
CN122240343A