Method and device for multiprocessor system load balancing

A multi-processor system, load balancing technology, applied in multi-programming devices, electrical digital data processing, instruments, etc., can solve problems affecting system performance, etc.

Active Publication Date: 2015-09-09
HUAWEI TECH CO LTD
View PDF7 Cites 3 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0004] Although the above method can achieve the effect of load balancing, it is also possible to migrate some processes that occupy a large memory space to the target CPU, so that when these processes are executed on the target CPU, they need to access the memory of the remote node multiple times. Or it is necessary to copy a large amount of data related to the process from the storage of the remote node to the storage of the local node, thereby affecting the performance of the system

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method and device for multiprocessor system load balancing
  • Method and device for multiprocessor system load balancing
  • Method and device for multiprocessor system load balancing

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0026] Such as figure 1 As shown, the embodiment of the present invention provides a method for multiprocessor system load balancing, including:

[0027] Step 101, determine the local central processing unit CPU and the target CPU in the multiprocessor system;

[0028] For a multiprocessor system, whether there is load imbalance in the multiprocessor system is detected every time the clock is interrupted, and load balancing processing needs to be performed in the case of load imbalance in the multiprocessor system. The load balancing process refers to migrating a process from a CPU with a large load to a CPU with a small load; wherein, the CPU from which the process migrates is called the local CPU, and the CPU from which the process migrates is called the target CPU; generally speaking, A CPU with a heavy load can be used as a local CPU, and a CPU with a light load can be used as a target CPU.

[0029] Step 102: Perform migration priority sorting according to the size of th...

Embodiment 2

[0038] Considering that in certain application environments or scenarios, the multiprocessor system needs to meet the load requirements of the certain application environments or scenarios. In the load balancing method for a multiprocessor system provided by the embodiment of the present invention, a threshold is set in advance for the migration priority according to the load requirements of the multiprocessor system in an application environment or scenario.

[0039] Such as figure 2 As shown, the method for multiprocessor system load balancing provided by the embodiment of the present invention includes:

[0040] Step 201, determine the local CPU and target CPU in the multiprocessor system;

[0041] Refer to step 101.

[0042] Step 202: Perform migration priority sorting according to the size of the memory space occupied by the processes in the local CPU queue; and the process that occupies less memory space has a higher migration priority;

[0043] The explanation of th...

Embodiment 3

[0051] Since the execution time of a process can reflect the size of the memory space occupied by the process to a certain extent, generally speaking, the execution time of the process and the memory space occupied by the process form a positive functional relationship, that is, the longer the execution time of the process, the Indicates that the process takes up more memory space. The execution time of the process refers to the time spent from the start of execution to the end of execution of the process. Based on the above considerations, as image 3 As shown, the embodiment of the present invention provides another method for load balancing of a multiprocessor system.

[0052] Step 301, determine the local central processing unit CPU and the target CPU in the multiprocessor system;

[0053] Refer to step 101.

[0054] Step 302, calculating the execution time of each process in the local CPU queue;

[0055] For example, if there are 9 processes in the local CPU queue, th...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

A method and a device for balancing load of a multiprocessor system relate to the resource allocation field of the multiprocessor system, for achieving the object of reducing the number of accessing a remote node memory or the amount of copying data when the processes migrated into a target Central Processing Unit (CPU) are performed. The method for balancing the load of the multiprocessor system comprises: determining the local CPU and the target CPU in the multiprocessor system; sequencing the migration priorities, based on the size of memory space occupied by the processes in the queue of the local CPU; wherein the less the memory space occupied by the process is, the higher the migration priority of the process is; and migrating the process whose migration priority is the highest other than the processes being performed in the queue of the local CPU into the target CPU. The solutions provided by the present invention can be applicable to the multiprocessor system of Non-Uniform Memory Access (NUMA) Architecture.

Description

technical field [0001] The invention relates to the resource allocation field of a multiprocessor system, in particular to a method and device for load balancing of a multiprocessor system. Background technique [0002] In a multi-processor system, each CPU (Central Processing Unit, central processing unit) maintains a queue separately, which will lead to load imbalance among multiple CPUs, which requires the process (or thread) from the load A large CPU is migrated to a CPU with a small load to achieve load balancing; the CPU from which the process migrates is called the local CPU, and the CPU to which the process migrates is called the target CPU. [0003] In the prior art, a method of migrating processes according to the hot and cold conditions of the processes in the cache is proposed to achieve load balancing, which specifically includes: first, setting the threshold (maximum value) of the waiting time of the process, the so-called waiting time of the process is Refers...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Patents(China)
IPC IPC(8): G06F9/48
CPCG06F9/5088
Inventor 郑寒
Owner HUAWEI TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products