Movatterモバイル変換


[0]ホーム

URL:


CN101504618A - Multi-core processor oriented real-time thread migration method - Google Patents

Multi-core processor oriented real-time thread migration method
Download PDF

Info

Publication number
CN101504618A
CN101504618ACNA2009100959582ACN200910095958ACN101504618ACN 101504618 ACN101504618 ACN 101504618ACN A2009100959582 ACNA2009100959582 ACN A2009100959582ACN 200910095958 ACN200910095958 ACN 200910095958ACN 101504618 ACN101504618 ACN 101504618A
Authority
CN
China
Prior art keywords
thread
migration
processor
nuclear
operating system
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CNA2009100959582A
Other languages
Chinese (zh)
Other versions
CN101504618B (en
Inventor
施青松
陈度
马建良
吴斌斌
王超
曹满
冯德贵
王勇刚
胡威
陈天洲
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang University ZJU
Original Assignee
Zhejiang University ZJU
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang University ZJUfiledCriticalZhejiang University ZJU
Priority to CN2009100959582ApriorityCriticalpatent/CN101504618B/en
Publication of CN101504618ApublicationCriticalpatent/CN101504618A/en
Application grantedgrantedCritical
Publication of CN101504618BpublicationCriticalpatent/CN101504618B/en
Expired - Fee Relatedlegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Landscapes

Abstract

Translated fromChinese

本发明公开了一种面向多核处理器的实时线程迁移方法。本发明是充分利用了共享二级cache和内存的多核硬件体系架构的特点从而有效地实现了多核处理器上的实时线程迁移方法。本发明实现了硬件支持的线程迁移初始化和处理器核之间的线程迁移,在线程运行时不需要花任何时间来轮询系统变量,减少了线程迁移时处理器核之间的数据传输,明显提高了线程执行时的性能和缩短了线程迁移的时间。本发明可以用在各种多核处理器上。

Figure 200910095958

The invention discloses a multi-core processor-oriented real-time thread migration method. The present invention makes full use of the characteristics of the multi-core hardware system framework of shared secondary cache and memory, thereby effectively realizing the real-time thread migration method on the multi-core processor. The present invention realizes hardware-supported thread migration initialization and thread migration between processor cores, does not need to spend any time polling system variables when threads are running, reduces data transmission between processor cores during thread migration, and obviously Improved thread execution performance and shortened thread migration time. The present invention can be used on various multi-core processors.

Figure 200910095958

Description

Real-time thread migration method towards polycaryon processor
Technical field
The present invention relates to carry out between the processor core on the multinuclear hardware systems framework method of thread migration.
Background technology
Because the growth of processor clock frequency, constantly riseing of processor energy consumption and temperature caused the limit of processor manufacturer in the speed competition.Face the limit of this growth, microprocessor manufacturer has invested the bosom of polycaryon processor technology one after another.The polycaryon processor technology is that processor performance promotes the new prospect of having opened up.Some company just claims that the processor of its production will use multi-core system structure comprehensively.
The polycaryon processor chip provides than the better concurrency of single core processor chip, better unit watt system performance.Concurrency is a control system, and equipment such as network route provide higher performance expansion.If these systems make full use of the concurrency that the polycaryon processor chip provides, can on performance, have greatly improved.Yet most software developer and software engineer lack corresponding experience and technological accumulation for this concurrency programming pattern, so this is a very big obstacle for the advantage of utilizing the polycaryon processor technology.
This technical obstacle is clearly, such as the management of the shared resource on the multi core chip is exactly a very big technological challenge.In most cases, each nuclear in the multi core chip has independently a level cache and a shared L2 cache, and memory subsystem interrupts subsystem and peripherals.Like this, system designer just must be guaranteed some resource of visit of each nuclear mutual exclusion.Consideration in this design has just brought higher design complexity.Such as the program of moving on different nuclear cooperates with each other if desired, so just needs a feasible Inter-Process Communication mechanism, the synchronization primitives mechanism of shared drive mechanism and guarantee shared resource.The every aspect of operating system all need be transformed just at multi-core system can make full use of the performance boost that multi-core technology is brought.
Therefore, operating system can reduce the design difficulty that multi-core technology is brought to a great extent to the support of multinuclear.Support the operating system of multinuclear to make full use of the advantage of multinuclear hardware platform for one, key is the support of operating system to multinuclear.Operating system can be brought more performance in the thread rank to the support of multinuclear.
Thread migration has carried out a large amount of research in distributed system.Distributed system is to finish calculation task jointly by collaborative each node.Distribute load to be difficult to reach load balance statically by prior task placement.In computation process, the load meeting of each node dynamically changes, and thread migration is one of method that realizes the distributed system balancing dynamic load.Thread migration is the thread that moves on a node to be transferred on the other node move.It can be retained in the result who has carried out on the source node and needn't re-execute this thread.In the middle of the thread migration mechanism that has realized at present, major part is based on the checkpoint and preserves that the mechanism that restarts realizes, promptly before migrating processes, the state of a process data are saved in check point file, this check point file is transferred on the other node then, after treating that destination node is received whole check point file, recover to move thread again according to check point file again.Each node is not share local internal memory in the distributed system, and each thread migration all will transmit lot of data.
Equally, in order to realize the balancing dynamic load of polycaryon processor, or, reduce the energy consumption of polycaryon processor, be necessary between processor core, to carry out thread migration in order to improve the performance of polycaryon processor.
Summary of the invention
The object of the present invention is to provide a kind of real-time thread migration method towards polycaryon processor.
The technical scheme that the present invention solves its technical matters employing is as follows:
1) carry out thread migration between processor core, all processor cores all have privately owned one-level cache, shared secondary cache and internal memory;
2) the thread migration initialization of hardware supported:
The first step, after each thread brought into operation, all migration point addresses of this thread all were recorded in the operating system;
Second step, operating system is saved in all migration point addresses in each thread data structure separately, and the migration point address of the thread that is moving on each processor core write in the debug registers on the nuclear, when the context switching took place, operating system was just upgraded the data in the debug registers;
In the 3rd step, in the time of thread of operating system decision migration, the zone bit that operating system just is provided with in the debug registers on this thread place processor core activates debug registers;
In the 4th step, when the thread execution instruction arrives the migration point address of thread, will produce a hardware interrupts and begin thread migration;
3) thread migration method:
When the beginning thread migration, operating system is waken the target processor nuclear of thread migration up, then according to the instruction execution result of source processor nuclear target processor nuclear is trained; After training process finishes, operating system is the thread on the source of release processor core and empty the streamline of source processor nuclear at first, then the data among the one-level cache of source processor nuclear are write back among the secondary cache, then the data in the source processor nuclear register are examined to target processor by bus transfer.The ideal processor core begins to carry out the thread that produces then receiving data storage in register on target processor nuclear.
Compared with prior art, the invention has the beneficial effects as follows:
(1) high efficiency.The present invention has realized a kind of real-time thread migration method towards polycaryon processor, wanting continuous land wheel to ask system variable in the thread implementation based on the thread migration method of checkpoint determines whether to carry out thread migration, and the thread migration initial method of hardware supported does not need flower to come the polling system variable any time, the performance when therefore obviously having improved thread execution.Data transmission procedure during owing to thread migration on polycaryon processor only need write back to the data among the one-level cache among the secondary cache, then the data in the register on the source processor nuclear are examined to target processor by bus transfer, therefore obviously shortened the time of thread migration.
(2) reliability.The present invention carries out careful analysis by the process to thread migration in the distributed system, suitably changed the process of thread migration, data transmission procedure when carefully having designed thread migration initialization and thread migration between source processor nuclear and the target processor nuclear, guaranteed that thread can normally move between processor core, made thread migration after target processor nuclear is gone up, can continue normal operation.
(3) practicality.A kind of real-time thread migration method towards polycaryon processor that the present invention proposes can be used on the various polycaryon processors.
Description of drawings
Fig. 1 is the synoptic diagram of the thread migration initialization procedure of hardware supported.
Fig. 2 is the synoptic diagram of thread migration process.
Embodiment
1) carry out thread migration between processor core, all processor cores all have privately owned one-level cache, shared secondary cache and internal memory:
In the present most polycaryon processor architectural framework, processor core all has privately owned one-level cache, and shared secondary cache and internal memory.All processor cores are shared drive all, so does not need to transmit code and data in the shared drive during thread migration.All processor cores are all shared secondary cache, and the data during thread migration among the one-level cache of source processor nuclear only need write back among the secondary cache and need not write back in the internal memory.
2) the thread migration initialization of hardware supported:
Most of modern processors all contain a series of debug registers.The PowerPC405 processor comprises 4 32 instruction address comparand register.When equaling a value in the instruction address comparand register that is activated, the value in the program counter register will produce a hardware interrupts.Similarly, in other processor, when equaling a value in the debug registers that is activated, the value in the program counter register also can produce a hardware interrupts.Utilize the thread migration initial method of this machine-processed hardware supported to make thread not need the colored variable that comes any time in the polling system in the process of implementation.The thread migration initial method of hardware supported as shown in Figure 1, comprises following four steps:
The first step, after a thread brought into operation, all migration point addresses of this thread all were recorded in the operating system;
Second step, operating system is saved in all migration point addresses in each thread data structure separately, and the migration point address of the thread that is moving on each processor core write in the debug registers on the nuclear, when context taking place switch, the data in the debug registers are upgraded in the migration point address that operating system is just used the thread that will carry out;
The 3rd step, when operating system according to thread of explorer decision migration to the another one processor core the time, the zone bit that operating system just is provided with in the debug registers on this thread place processor core activates debug registers;
In the 4th step, when the migration point address in the debug registers that is activated on the processor core of thread execution instruction arrival thread place, will produce a hardware interrupts and begin thread migration;
3) thread migration method:
As shown in Figure 2, when the beginning thread migration, if the target processor of thread migration nuclear has been closed, operating system need be waken the target processor nuclear of thread migration up, then according to the instruction execution result of source processor nuclear cache and fallout predictor on the target processor nuclear is trained.After training process finished, operating system is the thread on the source of release processor core and empty the streamline of source processor nuclear at first, then the data among the one-level cache of source processor nuclear is write back among the secondary cache.When source processor nuclear writes back to the data among the one-level cache among the secondary cache, target processor nuclear visit secondary cache just can obtain correct data.Operating system stores the data in the source processor nuclear register in the shared drive into by bus transfer then, and target processor nuclear just can be visited these data like this.At last, operating system is created a new thread on the target processor nuclear of thread migration, target processor nuclear is by the data in the visit shared drive acquisition source processor nuclear register, and these data storage in the register of oneself, then target processor nuclear just begins to carry out the thread of new establishment.

Claims (1)

1. real-time thread migration method towards polycaryon processor is characterized in that:
1) carry out thread migration between processor core, all processor cores all have privately owned one-level cache, shared secondary cache and internal memory;
2) the thread migration initialization of hardware supported:
The first step, after each thread brought into operation, all migration point addresses of this thread all were recorded in the operating system;
Second step, operating system is saved in all migration point addresses in each thread data structure separately, and the migration point address of the thread that is moving on each processor core write in the debug registers on the nuclear, when the context switching took place, operating system was just upgraded the data in the debug registers;
In the 3rd step, in the time of thread of operating system decision migration, the zone bit that operating system just is provided with in the debug registers on this thread place processor core activates debug registers;
In the 4th step, when the thread execution instruction arrives the migration point address of thread, will produce a hardware interrupts and begin thread migration;
3) thread migration method:
When the beginning thread migration, operating system is waken the target processor nuclear of thread migration up, then according to the instruction execution result of source processor nuclear target processor nuclear is trained; After training process finishes, operating system is the thread on the source of release processor core and empty the streamline of source processor nuclear at first, then the data among the one-level cache of source processor nuclear are write back among the secondary cache, then the data in the source processor nuclear register are examined to target processor by bus transfer.The ideal processor core begins to carry out the thread that produces then receiving data storage in register on target processor nuclear.
CN2009100959582A2009-02-262009-02-26 Real-time thread migration method for multi-core processorsExpired - Fee RelatedCN101504618B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN2009100959582ACN101504618B (en)2009-02-262009-02-26 Real-time thread migration method for multi-core processors

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN2009100959582ACN101504618B (en)2009-02-262009-02-26 Real-time thread migration method for multi-core processors

Publications (2)

Publication NumberPublication Date
CN101504618Atrue CN101504618A (en)2009-08-12
CN101504618B CN101504618B (en)2011-04-27

Family

ID=40976873

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN2009100959582AExpired - Fee RelatedCN101504618B (en)2009-02-262009-02-26 Real-time thread migration method for multi-core processors

Country Status (1)

CountryLink
CN (1)CN101504618B (en)

Cited By (21)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN102495762A (en)*2011-11-162012-06-13华为技术有限公司Thread scheduling method, thread scheduling device and multi-core processor system
CN101751295B (en)*2009-12-222012-08-29浙江大学Method for realizing inter-core thread migration under multi-core architecture
CN102981805A (en)*2012-11-022013-03-20浪潮(北京)电子信息产业有限公司Serial software response method and system
CN105009086A (en)*2014-03-102015-10-28华为技术有限公司Method for switching processors, computer, and switching apparatus
US9292450B2 (en)2013-03-052016-03-22Imagination Technologies LimitedMigration of data to register file cache
CN105868016A (en)*2015-01-202016-08-17复旦大学Thread transfer distribution method capable of preventing local overheat of multi-core processor
CN105930218A (en)*2016-04-182016-09-07深圳市万普拉斯科技有限公司Computing resource frequency adjustment method and system
WO2017049592A1 (en)*2015-09-252017-03-30Intel CorporationMethod and apparatus to improve shared memory efficiency
CN106776018A (en)*2016-12-012017-05-31三星(中国)半导体有限公司Host node for distributed system and method for parallel processing and equipment from node
CN106850749A (en)*2016-12-262017-06-13联想(北京)有限公司A kind of method and device, the electronic equipment of online updating kernel
CN106980492A (en)*2016-01-152017-07-25英特尔公司System, method and apparatus for determining the work arrangement on processor core
CN107980118A (en)*2015-06-102018-05-01无比视视觉技术有限公司 Multi-core processor devices using multithreading
CN108156207A (en)*2016-12-022018-06-12航天星图科技(北京)有限公司A kind of data processing method of multi-node system
CN108885559A (en)*2016-03-292018-11-23微软技术许可有限责任公司Fast transfer workload among multiple processors
CN109254849A (en)*2018-08-312019-01-22北京小米移动软件有限公司The operation method and device of application program
CN109614220A (en)*2018-10-262019-04-12阿里巴巴集团控股有限公司A kind of multiple nucleus system processor and data-updating method
CN111338577A (en)*2020-02-212020-06-26苏州浪潮智能科技有限公司Multi-core thread migration method and system of storage system and related components
CN112395079A (en)*2019-08-192021-02-23无锡江南计算技术研究所Operation core operation migration method under heterogeneous many-core architecture
CN112559176A (en)*2020-12-112021-03-26广州橙行智动汽车科技有限公司Instruction processing method and device
CN115658569A (en)*2022-12-082023-01-31井芯微电子技术(天津)有限公司Method, system and equipment for interrupting and sharing storage among AMP (amplifier) multi-core processors
CN116244229A (en)*2023-05-122023-06-09苏州浪潮智能科技有限公司Access method and device of hardware controller, storage medium and electronic equipment

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US8296768B2 (en)*2007-06-302012-10-23Intel CorporationMethod and apparatus to enable runtime processor migration with operating system assistance
CN101201753B (en)*2007-12-132012-12-26浪潮通信信息系统有限公司Method for configuring and managing multimode machine supervising engine
CN100562854C (en)*2008-03-112009-11-25浙江大学 Implementation method of multi-core processor operating system load balancing

Cited By (40)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN101751295B (en)*2009-12-222012-08-29浙江大学Method for realizing inter-core thread migration under multi-core architecture
CN102495762B (en)*2011-11-162014-04-02华为技术有限公司Thread scheduling method, thread scheduling device and multi-core processor system
CN102495762A (en)*2011-11-162012-06-13华为技术有限公司Thread scheduling method, thread scheduling device and multi-core processor system
CN102981805A (en)*2012-11-022013-03-20浪潮(北京)电子信息产业有限公司Serial software response method and system
CN102981805B (en)*2012-11-022015-11-18浪潮(北京)电子信息产业有限公司The response method of serialized software and system
US9858194B2 (en)2013-03-052018-01-02Imagination TechnologiesMigration of data to register file cache
US9292450B2 (en)2013-03-052016-03-22Imagination Technologies LimitedMigration of data to register file cache
US10678695B2 (en)2013-03-052020-06-09MIPS Tech, LLCMigration of data to register file cache
US9612968B2 (en)2013-03-052017-04-04Imagination Technologies LimitedMigration of data to register file cache
CN105009086A (en)*2014-03-102015-10-28华为技术有限公司Method for switching processors, computer, and switching apparatus
CN105009086B (en)*2014-03-102019-01-18华为技术有限公司A kind of method, computer and switching device for realizing processor switching
CN105868016B (en)*2015-01-202019-04-02复旦大学A kind of thread transfer distribution method avoiding multi-core processor hot-spot
CN105868016A (en)*2015-01-202016-08-17复旦大学Thread transfer distribution method capable of preventing local overheat of multi-core processor
US12130744B2 (en)2015-06-102024-10-29Mobileye Vision Technologies Ltd.Fine-grained multithreaded cores executing fused operations in multiple clock cycles
US11294815B2 (en)2015-06-102022-04-05Mobileye Vision Technologies Ltd.Multiple multithreaded processors with shared data cache
CN107980118A (en)*2015-06-102018-05-01无比视视觉技术有限公司 Multi-core processor devices using multithreading
CN107980118B (en)*2015-06-102021-09-21无比视视觉技术有限公司Multi-core processor device using multi-thread processing
US11068401B2 (en)2015-09-252021-07-20Intel CorporationMethod and apparatus to improve shared memory efficiency
WO2017049592A1 (en)*2015-09-252017-03-30Intel CorporationMethod and apparatus to improve shared memory efficiency
US10922143B2 (en)2016-01-152021-02-16Intel CorporationSystems, methods and devices for determining work placement on processor cores
US12293237B2 (en)2016-01-152025-05-06Intel CorporationSystems, methods and devices for determining work placement on processor cores
CN106980492B (en)*2016-01-152019-07-26英特尔公司 Apparatus, system, method, machine-readable storage medium and apparatus for computing
CN106980492A (en)*2016-01-152017-07-25英特尔公司System, method and apparatus for determining the work arrangement on processor core
US11409577B2 (en)2016-01-152022-08-09Intel CorporationSystems, methods and devices for determining work placement on processor cores
CN108885559B (en)*2016-03-292021-12-03微软技术许可有限责任公司Fast transfer of workload between multiple processors
CN108885559A (en)*2016-03-292018-11-23微软技术许可有限责任公司Fast transfer workload among multiple processors
CN105930218A (en)*2016-04-182016-09-07深圳市万普拉斯科技有限公司Computing resource frequency adjustment method and system
CN106776018A (en)*2016-12-012017-05-31三星(中国)半导体有限公司Host node for distributed system and method for parallel processing and equipment from node
CN108156207A (en)*2016-12-022018-06-12航天星图科技(北京)有限公司A kind of data processing method of multi-node system
CN106850749A (en)*2016-12-262017-06-13联想(北京)有限公司A kind of method and device, the electronic equipment of online updating kernel
CN109254849A (en)*2018-08-312019-01-22北京小米移动软件有限公司The operation method and device of application program
US11106795B2 (en)2018-10-262021-08-31Advanced New Technologies Co., Ltd.Method and apparatus for updating shared data in a multi-core processor environment
CN109614220B (en)*2018-10-262020-06-30阿里巴巴集团控股有限公司Multi-core system processor and data updating method
CN109614220A (en)*2018-10-262019-04-12阿里巴巴集团控股有限公司A kind of multiple nucleus system processor and data-updating method
CN112395079A (en)*2019-08-192021-02-23无锡江南计算技术研究所Operation core operation migration method under heterogeneous many-core architecture
CN111338577A (en)*2020-02-212020-06-26苏州浪潮智能科技有限公司Multi-core thread migration method and system of storage system and related components
CN112559176A (en)*2020-12-112021-03-26广州橙行智动汽车科技有限公司Instruction processing method and device
CN115658569A (en)*2022-12-082023-01-31井芯微电子技术(天津)有限公司Method, system and equipment for interrupting and sharing storage among AMP (amplifier) multi-core processors
CN116244229A (en)*2023-05-122023-06-09苏州浪潮智能科技有限公司Access method and device of hardware controller, storage medium and electronic equipment
CN116244229B (en)*2023-05-122023-08-04苏州浪潮智能科技有限公司Access method and device of hardware controller, storage medium and electronic equipment

Also Published As

Publication numberPublication date
CN101504618B (en)2011-04-27

Similar Documents

PublicationPublication DateTitle
CN101504618A (en)Multi-core processor oriented real-time thread migration method
EP3844620B1 (en)Method, apparatus, and system for an architecture for machine learning acceleration
CN108701040B (en)Method, apparatus, and instructions for user-level thread suspension
CN101788919B (en)Chip multi-core processor clock precision parallel simulation system and simulation method thereof
US10037227B2 (en)Systems, methods and devices for work placement on processor cores
TWI628594B (en) User level forks and rendezvous processors, methods, systems, and instructions
TWI489266B (en)Instruction that specifies an application thread performance state
CN104835110B (en)A kind of asynchronous diagram data processing system based on GPU
CN101799750B (en)Data processing method and device
CN102929686A (en)Functional verification method of on-chip multi-core processor
CN110647404A (en)System, apparatus and method for barrier synchronization in a multithreaded processor
DE102014003671A1 (en) PROCESSORS, METHODS AND SYSTEMS FOR RELAXING THE SYNCHRONIZATION OF ACCESS TO A SHARED MEMORY
CN104081315A (en)Method, apparatus and system for energy efficiency and energy conservation including thread consolidation
CN104412233B (en)The distribution of aliasing register in pipeline schedule
CN101840390B (en)Hardware synchronous circuit structure suitable for multiprocessor system and implementation method thereof
US20170024338A1 (en)Precise, Efficient, and Transparent Transfer of Execution Between an Auto-generated In-line Accelerator and Processor(s)
CN101763285A (en)Zero-overhead switching multithread processor and thread switching method thereof
KR101804677B1 (en)Hardware apparatuses and methods to perform transactional power management
JP2017016638A (en) Persistent commit processor, method, system and instructions
CN103577158A (en)Data processing method and device
Abellán et al.Efficient hardware barrier synchronization in many-core cmps
CN102681937A (en)Correctness verifying method of cache consistency protocol
CN107943592A (en)A kind of method for avoiding GPU resource contention towards GPU cluster environment
WO2014188073A1 (en)Memory unit for emulated shared memory architectures
CN103902502B (en)A kind of extendible separate type isomery thousand core system

Legal Events

DateCodeTitleDescription
C06Publication
PB01Publication
C10Entry into substantive examination
SE01Entry into force of request for substantive examination
C14Grant of patent or utility model
GR01Patent grant
C17Cessation of patent right
CF01Termination of patent right due to non-payment of annual fee

Granted publication date:20110427

Termination date:20120226


[8]ページ先頭

©2009-2025 Movatter.jp