Task-based heterogeneous CPU-GPU (Central Processing Unit-Graphics Processing Unit) on-chip network routing method, device and system and medium

By adopting the task-based routing method and the virtual channel crossbar arbiter in the heterogeneous CPU-GPU on-chip network, the data hotspot and network congestion problems in the central layout mode of the heterogeneous CPU-GPU on-chip network architecture are solved, and lower cost is achieved. Latency and higher performance routing schemes.

CN118740709AActive Publication Date: 2024-10-01SHANDONG INSPUR SCI RES INST CO LTD

Patent Information

Application Number
CN202410766347.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-14
Publication Date
2024-10-01
Estimated Expiration
2044-06-14

AI Technical Summary

Technical Problem

There are data hotspots and network congestion problems in the existing heterogeneous CPU-GPU on-chip network architecture center layout mode, resulting in information blocking and traffic imbalance, affecting system performance.

Method used

Adopt a task-based routing method and set the priority of path selection rules, decreasing step by step from A to D: A. Keep the number of routing hops as few as possible; B. Keep high-traffic paths as few as possible; C. Leave hotspot areas as soon as possible; D. Workload balancing, with virtual channels at router input ports via XY and YX routing methods, crossbar arbiter to avoid deadlocks.

Benefits of technology

It reduces network latency, improves overall performance, avoids deadlock problems, significantly improves network performance, and solves data hotspots and congestion problems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118740709A_ABST
    Figure CN118740709A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of chip design, and discloses a task-based heterogeneous CPU-GPU (Central Processing Unit-Graphic Processing Unit) on-chip network routing method, device and system and a medium. Firstly, a path selection rule of a routing method is set, the rule comprises as few task execution routing hops as possible, as few distributed high-flow paths as possible, departure from a hot spot area as soon as possible and balance of workload in a network as possible, then a corresponding routing method is determined according to the path selection rule, and when a cache access request is executed and a GPU requests to reply a task, the path selection rule is determined. And when a CPU request reply task is executed by using an XY routing method, a YX routing method is adopted. According to the invention, the blocking problem in the central layout mode of the existing CPU-GPU heterogeneous on-chip network architecture is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of chip design technology, for example, a task-based heterogeneous CPU-GPU on-chip network routing method, device, system and medium. Background Art

[0002] At present, with the increasing computing requirements of various tasks in production and life, heterogeneous multi-core chips have emerged to solve the problem of insufficient computing power of traditional homogeneous multi-core CPUs. Among them, the heterogeneous combination of CPU-GPU is the most common. CPU and GPU share the last-level cache (LLC), memory controller (MC) and other on-chip resources to reduce communication overhead and improve system performance.

[0003] However, resource sharing is bound to bring about resource competition problems. The multi-threaded structure of GPU is not sensitive to latency, but its high throughput will significantly aggravate the problems caused by resource sharing. In this context, using on-chip network (NoC) to connect various modules and separate different traffic in the network has become an important solution to achieve the reasonable allocation of shared resources.

[0004] CPU-GPU LLC / MC contains four types of nodes: CPU, GPU, LLC and MC. Based on the different layout positions, various topology models are derived. Figure 1 The central layout mode targeted by this application is shown, in which nodes of the same type are relatively concentrated. This model focuses on the memory access tasks of the CPU and GPU, and the LLC and MC are distributed in the topological center area, surrounded by the CPU and GPU. The MC is surrounded by the LLC and only communicates with the LLC to reduce the number of hops. This design scheme can minimize the number of routing hops when the CPU and GPU frequently access the LLC. However, this layout method will cause some paths to face huge data carrying pressure, that is, congested paths, that is, the data paths marked in bold in the figure. In addition, frequent communication between LLC and MC will cause information hot spots in the center, that is, the parts framed by dotted lines in the figure, and the hot spots are more prone to information blocking and other problems. In the hot spot area, there is no direct communication between each LLC and each MC, so the traffic on the vertical path in the hot spot area in the figure will be less than the traffic on the horizontal path. In addition, in the peripheral CPU and GPU parts, the traffic on the loop is also relatively small. Summary of the invention

[0005] In order to provide a basic understanding of some aspects of the disclosed embodiments, a brief summary is given below. The summary is not an extensive review, nor is it intended to identify key / critical components or delineate the scope of protection of these embodiments, but rather serves as a prelude to the detailed description that follows.

[0006] The embodiments of the present disclosure provide a task-based heterogeneous CPU-GPU on-chip network routing method, device, system and medium to solve the blocking problem in the central layout mode of the existing CPU-GPU heterogeneous on-chip network architecture.

[0007] In some embodiments, the method comprises:

[0008] S01) Set the path selection rules of the routing method, and the priority of the path selection rules decreases from A to D:

[0009] A. The number of routing hops for executing tasks should be as small as possible;

[0010] B. Assign as few high-traffic paths as possible;

[0011] C. Leave the hot spot area as soon as possible;

[0012] D. The workload in the network is as balanced as possible;

[0013] S02), when executing a cache access request task, that is, when the CPU / GPU accesses LLC, according to rule B, an XY routing method is adopted, and the peripheral loop path and the vertical path of the hot spot area are preferentially passed;

[0014] S03), when executing the CPU request reply task, that is, when LLC replies to the CPU, according to rule B, the YX routing method is adopted to preferentially leave the hot spot area through the vertical path;

[0015] S04), when executing the GPU request reply task, that is, when LLC replies to the GPU, according to rule D, the XY routing method is adopted to leave the hot spot area as soon as possible and enter the loop area with low flow pressure.

[0016] Furthermore, let src be the source node, dst be the destination node, src.x and dst.x be the horizontal coordinates of the source node and the destination node respectively, src.y and dst.y be the vertical coordinates of the source node and the destination node respectively, and the XY routing method is: first compare the values ​​of src.x and dst.x, if src.x>dst.x, then route straight to the left, otherwise go straight to the right, until src.x=dst.x, then judge the relationship between src.y and dst.y, if src.y>dst.y, then route straight down, otherwise go straight up, until reaching the destination node.

[0017] Furthermore, let src be the source node, dst be the destination node, src.x and dst.x be the horizontal coordinates of the source node and the destination node respectively, src.y and dst.y be the vertical coordinates of the source node and the destination node respectively, and the YX routing method is: first compare the values ​​of src.y and dst.y, if src.y>dst.y, then route straight down, otherwise go straight up until src.y=dst.y, then judge the relationship between src.x and dst.x, if src.x>dst.x, then route straight to the left, otherwise go straight to the right, until reaching the destination node.

[0018] Furthermore, the method provides two virtual channels VC1 and VC2 at each router input port, the virtual channel VC1 is used to pass all task-based XY routing paths, and the virtual channel VC2 is used to pass all task-based YX routing paths. The router output port is provided with a cross switch, and the virtual channel of each router input port is connected to the cross switch, and the cross switch generates an output that avoids deadlock.

[0019] Furthermore, the output end of the router is also provided with a routing calculation module, a virtual channel arbitrator and a cross switch arbitrator. The routing calculation module schedules the selection of the data output port, that is, confirms the port used to output the data. The virtual channel arbitrator determines the virtual channel data that leaves the virtual channel and is transmitted to the cross switch. The cross switch arbitrator manages the matching of the input and output of the cross switch. Different outputs generated by the cross switch have different physical data links.

[0020] In some embodiments, the device includes: a routing path selection rule determination module, configured to determine the following four path selection rules, and the priorities of the path selection rules decrease from A to D:

[0021] A. The number of routing hops for executing tasks should be as small as possible;

[0022] B. Assign as few high-traffic paths as possible;

[0023] C. Leave the hot spot area as soon as possible;

[0024] D. The workload in the network is as balanced as possible;

[0025] The cache access request task routing path determination module, when executing the cache access request task, that is, when the CPU / GPU accesses the LLC, adopts the XY routing method according to rule B, giving priority to the peripheral loop path and the vertical path of the hot spot area;

[0026] The CPU request reply task routing path determination module, when executing the CPU request reply task, that is, when LLC replies to the CPU, according to rule B, adopts the YX routing method;

[0027] The GPU request reply task routing path determination module, when executing the GPU request reply task, that is, when LLC replies to the GPU, adopts the XY routing method according to rule D.

[0028] Furthermore, two virtual channels VC1 and VC2 are provided at each router input port. Virtual channel VC1 is used to pass all task-based XY routing paths, and virtual channel VC2 is used to pass all task-based YX routing paths. A cross switch is provided at the router output port. The virtual channel end of each router input port is connected to the cross switch, and the cross switch generates an output to avoid deadlock.

[0029] Furthermore, the output end of the router is also provided with a routing calculation module, a virtual channel arbitrator and a cross switch arbitrator. The routing calculation module schedules the selection of the data output port, that is, confirms the port used to output the data. The virtual channel arbitrator determines the virtual channel data that leaves the virtual channel and is transmitted to the cross switch. The cross switch arbitrator manages the matching of the input and output of the cross switch.

[0030] In some embodiments, the system includes: a processor and a memory storing program instructions, and the processor is configured to execute the task-based heterogeneous CPU-GPU on-chip network routing method as described above when running the program instructions.

[0031] In some embodiments, the storage medium stores program instructions, and when the program instructions are run, they execute the task-based heterogeneous CPU-GPU on-chip network routing method as described above.

[0032] Beneficial effects of the present invention: This solution proposes a solution to the data hotspot and network congestion problems existing in the LLC / MC topology model of heterogeneous on-chip networks with central layout. Compared with traditional routing algorithms, the algorithm of this solution has lower network latency and higher overall performance. At the same time, the task-based virtual channel can avoid the occurrence of deadlock problems, further improving network performance.

[0033] The above general description and the following description are exemplary and explanatory only and are not intended to limit the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] One or more embodiments are exemplarily described by corresponding drawings, which do not limit the embodiments. Elements with the same reference numerals in the drawings are shown as similar elements, and the drawings do not constitute a scale limitation, and wherein:

[0035] Figure 1 It is a schematic diagram of the topological model of the central layout mode;

[0036] Figure 2It is a schematic diagram of the XY routing method;

[0037] Figure 3 It is a schematic diagram of the YX routing method;

[0038] Figure 4 is a schematic diagram of a virtual channel. DETAILED DESCRIPTION

[0039] In order to be able to understand the characteristics and technical content of the embodiments of the present disclosure in more detail, the implementation of the embodiments of the present disclosure is described in detail below in conjunction with the accompanying drawings. The attached drawings are for reference only and are not used to limit the embodiments of the present disclosure. In the following technical description, for the convenience of explanation, multiple details are provided to provide a full understanding of the disclosed embodiments. However, one or more embodiments can still be implemented without these details. When writing an effect description in other cases, it is necessary to give an analysis and deduction process from the scheme to the effect. When writing an effect description, it is necessary to give an analysis and deduction process from the scheme to the effect. In order to simplify the drawings, well-known structures and devices can be simplified for display.

[0040] The terms "first", "second", etc. in the specification and claims of the embodiments of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchanged where appropriate, so as to describe the embodiments of the embodiments of the present disclosure described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions.

[0041] Unless otherwise stated, the term "plurality" means two or more.

[0042] In the embodiment of the present disclosure, the character " / " indicates that the preceding and following objects are in an "or" relationship. For example, A / B indicates: A or B.

[0043] The term "and / or" is a description of the association relationship between objects, indicating that three relationships can exist. For example, A and / or B means: A or B, or, A and B.

[0044] The term "correspondence" may refer to an association relationship or a binding relationship. The correspondence between A and B means that there is an association relationship or a binding relationship between A and B.

[0045] Example 1

[0046] This embodiment discloses a task-based CPU-GPU on-chip network routing method. Figure 1The central layout mode topology model shown in the figure, the heterogeneous CPU-GPU on-chip network includes four nodes: CPU, GPU, LLC and MC, and the four nodes form a central layout mode topology model, wherein the nodes LLC and MC are distributed in the topological center area, surrounded by the nodes CPU and GPU, and the node MC is surrounded by the node LLC. The method includes the following steps:

[0047] S01) Set the path selection rules of the routing method, and the priority of the path selection rules decreases from A to D:

[0048] A. The number of routing hops for executing tasks should be as small as possible;

[0049] B. Assign as few high-traffic paths as possible;

[0050] C. Leave the hot spot area as soon as possible;

[0051] D. The workload in the network is as balanced as possible;

[0052] S02), when executing a cache access request task, that is, when the CPU / GPU accesses LLC, according to rule B, an XY routing method is adopted, and the peripheral loop path and the vertical path of the hot spot area are preferentially passed;

[0053] S03), when executing the CPU request reply task, that is, when LLC replies to the CPU, due to the small amount of vertical traffic in the hotspot area, according to rule B, the YX routing method is adopted to preferentially leave the hotspot area through the vertical path;

[0054] S04), when executing the GPU request reply task, that is, when LLC replies to the GPU, the XY routing method is adopted according to rule D. Its purpose is to make it leave the hot spot area as soon as possible and enter the loop area with less traffic to follow rule D, and leave the hot spot area as soon as possible and enter the loop area with low traffic pressure.

[0055] Let src be the source node, dst be the destination node, src.x and dst.x be the horizontal coordinates of the source node and the destination node respectively, and src.y and dst.y be the vertical coordinates of the source node and the destination node respectively.

[0056] like Figure 2 As shown, the XY routing method is: first compare the values ​​of src.x and dst.x. If src.x>dst.x, then route straight to the left, otherwise route straight to the right until src.x=dst.x, then determine the relationship between src.y and dst.y. If src.y>dst.y, then route straight down, otherwise route straight up until reaching the destination node. If it is a CPU request task / GPU request task / GPU reply task, the XY routing method is used.

[0057] Let src be the source node, dst be the destination node, src.x and dst.x be the horizontal coordinates of the source node and the destination node respectively, and src.y and dst.y be the vertical coordinates of the source node and the destination node respectively.

[0058] like Figure 3 As shown, the YX routing method is: first compare the values ​​of src.y and dst.y. If src.y>dst.y, then route straight down, otherwise go straight up until src.y=dst.y, then determine the relationship between src.x and dst.x. If src.x>dst.x, then route straight to the left, otherwise go straight to the right until reaching the destination node. If it is a CPU reply task, the YX routing method is used.

[0059] like Figure 4 As shown, the method provides two virtual channels VC1 and VC2 at each router input port, the virtual channel VC1 is used to pass all task-based XY routing paths, and the virtual channel VC2 is used to pass all task-based YX routing paths. The router output port is provided with a cross switch, and the virtual channel of each router input port is connected to the cross switch, and the cross switch generates an output to avoid deadlock.

[0060] The output end of the router is also equipped with a routing calculation module, a virtual channel arbitrator and a cross switch arbitrator. The routing calculation module schedules the selection of the data output port, that is, confirms the port used to output data. The virtual channel arbitrator determines the virtual channel data that leaves the virtual channel and is passed to the cross switch. The cross switch arbitrator manages the matching of the cross switch input and output; different outputs generated by the cross switch have different physical data links.

[0061] Virtual channels are used to solve the deadlock problem that may be caused by the mixed use of XY and YX routing methods in this routing algorithm. Among them, VC1 is responsible for all XY routing tasks of the above task-based routing algorithm, while VC2 undertakes the related tasks of the YX part. In this way, although the routing algorithm itself arranges the XY and YX algorithms to the same latitude, the virtual channel separates their actual physical data links, thereby avoiding deadlock.

[0062] Example 2

[0063] This embodiment discloses a task-based heterogeneous CPU-GPU on-chip network routing device, wherein the heterogeneous CPU-GPU on-chip network includes four nodes: CPU, GPU, LLC and MC, and the four nodes form a central layout mode topology model, wherein the nodes LLC and MC are distributed in a topological center area, surrounded by the nodes CPU and GPU, and the node MC is surrounded by the node LLC.

[0064] The device of this embodiment includes: a routing path selection rule determination module, which is used to determine the following four path selection rules, and the priorities of the path selection rules decrease from A to D:

[0065] A. The number of routing hops for executing tasks should be as small as possible;

[0066] B. Assign as few high-traffic paths as possible;

[0067] C. Leave the hot spot area as soon as possible;

[0068] D. The workload in the network is as balanced as possible;

[0069] The cache access request task routing path determination module, when executing the cache access request task, that is, when the CPU / GPU accesses the LLC, adopts the XY routing method according to rule B, giving priority to the peripheral loop path and the vertical path of the hot spot area;

[0070] The CPU request reply task routing path determination module, when executing the CPU request reply task, that is, when LLC replies to the CPU, due to the small amount of vertical traffic in the hotspot area, according to rule B, the YX routing method is adopted;

[0071] The GPU request reply task routing path determination module, when executing the GPU request reply task, that is, when LLC replies to the GPU, adopts the XY routing method according to rule D. Its purpose is to make it leave the hot spot area as soon as possible and enter the loop area with less traffic to follow rule D.

[0072] Let src be the source node, dst be the destination node, src.x and dst.x be the horizontal coordinates of the source node and the destination node respectively, and src.y and dst.y be the vertical coordinates of the source node and the destination node respectively.

[0073] like Figure 2 As shown, the XY routing method is: first compare the values ​​of src.x and dst.x. If src.x>dst.x, then route straight to the left, otherwise route straight to the right until src.x=dst.x, then determine the relationship between src.y and dst.y. If src.y>dst.y, then route straight down, otherwise route straight up until reaching the destination node. If it is a CPU request task / GPU request task / GPU reply task, the XY routing method is used.

[0074] Let src be the source node, dst be the destination node, src.x and dst.x be the horizontal coordinates of the source node and the destination node respectively, and src.y and dst.y be the vertical coordinates of the source node and the destination node respectively.

[0075] like Figure 3As shown, the YX routing method is: first compare the values ​​of src.y and dst.y. If src.y>dst.y, then route straight down, otherwise go straight up until src.y=dst.y, then determine the relationship between src.x and dst.x. If src.x>dst.x, then route straight to the left, otherwise go straight to the right until reaching the destination node. If it is a CPU reply task, the YX routing method is used.

[0076] like Figure 4 As shown, the method provides two virtual channels VC1 and VC2 at each router input port, the virtual channel VC1 is used to pass all task-based XY routing paths, and the virtual channel VC2 is used to pass all task-based YX routing paths. The router output port is provided with a cross switch, and the virtual channel of each router input port is connected to the cross switch, and the cross switch generates an output to avoid deadlock.

[0077] The output end of the router is also equipped with a routing calculation module, a virtual channel arbitrator and a cross switch arbitrator. The routing calculation module schedules the selection of the data output port, that is, confirms the port used to output data. The virtual channel arbitrator determines the virtual channel data that leaves the virtual channel and is passed to the cross switch. The cross switch arbitrator manages the matching of the cross switch input and output; different outputs generated by the cross switch have different physical data links.

[0078] Virtual channels are used to solve the deadlock problem that may be caused by the mixed use of XY and YX routing methods in this routing algorithm. Among them, VC1 is responsible for all XY routing tasks of the above task-based routing algorithm, while VC2 undertakes the related tasks of the YX part. In this way, although the routing algorithm itself arranges the XY and YX algorithms to the same latitude, the virtual channel separates their actual physical data links, thereby avoiding deadlock.

[0079] Example 3

[0080] This embodiment discloses a task-based heterogeneous CPU-GPU on-chip network routing system, including a processor and a memory storing program instructions, wherein the processor is configured to execute the task-based heterogeneous CPU-GPU on-chip network routing method as described in Example 1 when running the program instructions.

[0081] Example 4

[0082] This embodiment discloses a storage medium storing program instructions, which, when run, execute the task-based heterogeneous CPU-GPU on-chip network routing method as described in Embodiment 1.

[0083] The computer-readable storage medium mentioned above may be a transient computer-readable storage medium or a non-transitory computer-readable storage medium.

[0084] The technical solution of the embodiment of the present disclosure can be embodied in the form of a software product, which is stored in a storage medium and includes one or more instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in the embodiment of the present disclosure. The aforementioned storage medium may be a non-transient storage medium, including: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program codes, or a transient storage medium.

[0085] The above description and the accompanying drawings fully illustrate the embodiments of the present disclosure so that those skilled in the art can practice them. Other embodiments may include structural, logical, electrical, process and other changes. The embodiments represent only possible changes. Unless explicitly required, separate components and functions are optional, and the order of operation may vary. The parts and features of some embodiments may be included in or replace the parts and features of other embodiments. Moreover, the words used in this application are only used to describe the embodiments and are not used to limit the claims. As used in the description of the embodiments and the claims, unless the context clearly indicates, the singular forms of "a", "an" and "the" are intended to include plural forms as well. Similarly, the term "and / or" as used in this application refers to any and all possible combinations of listings containing one or more associated ones. In addition, when used in the present application, the term "comprise" and its variants "comprises" and / or comprising refer to the presence of stated features, wholes, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or groups thereof. In the absence of further restrictions, the elements defined by the sentence "comprising a ..." do not exclude the presence of other identical elements in the process, method or device comprising the elements. In this article, each embodiment may focus on the differences from other embodiments, and the same and similar parts between the embodiments may refer to each other. For the methods, products, etc. disclosed in the embodiments, if they correspond to the method part disclosed in the embodiments, then the relevant parts can refer to the description of the method part.

[0086] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software may depend on the specific application and design constraints of the technical solution. The technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the embodiments of the present disclosure. The technicians may clearly understand that for the convenience and simplicity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here.

[0087] In the embodiments disclosed herein, the disclosed methods and products (including but not limited to devices, equipment, etc.) can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units can be only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between each other shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms. The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to implement this embodiment. In addition, each functional unit in the embodiment of the present disclosure may be integrated in a processing unit, or each unit may exist physically alone, or two or more units may be integrated in one unit.

[0088] The flowchart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to the embodiment of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of the code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. In some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, which can depend on the functions involved. In the description corresponding to the flowchart and the block diagram in the accompanying drawings, the operations or steps corresponding to different boxes can also occur in a different order from the order disclosed in the description, and sometimes there is no specific order between different operations or steps. For example, two consecutive operations or steps can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, which can depend on the functions involved. Each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, may be implemented by a dedicated hardware-based system that performs the specified functions or actions, or may be implemented by a combination of dedicated hardware and computer instructions.

Claims

1. A task-based heterogeneous CPU-GPU on-chip network routing method, wherein the heterogeneous CPU-GPU on-chip network includes four nodes: CPU, GPU, LLC and MC, and the four nodes form a central layout mode topology model, wherein the nodes LLC and MC are distributed in the topological center area, surrounded by the nodes CPU and GPU, and the node MC is surrounded by the node LLC, characterized in that: The following steps are involved: S01) Set the path selection rules of the routing method, and the priority of the path selection rules decreases from A to D: The number of routing hops for executing tasks should be as small as possible; Assign as few high-traffic paths as possible; Leave the hotspot area as quickly as possible; The workload within the network is as balanced as possible; S02), when executing a cache access request task, that is, when the CPU / GPU accesses LLC, according to rule B, an XY routing method is adopted, and the peripheral loop path and the vertical path of the hot spot area are preferentially passed; S03), when executing the CPU request reply task, that is, when LLC replies to the CPU, according to rule B, the YX routing method is adopted; S04), when executing the GPU request reply task, that is, when LLC replies to the GPU, according to rule D, the XY routing method is adopted.

2. The task-based heterogeneous CPU-GPU on-chip network routing method according to claim 1 is characterized in that: src is the source node, dst is the destination node, src.x and dst.x are the horizontal coordinates of the source node and the destination node respectively, src.y and dst.y are the vertical coordinates of the source node and the destination node respectively, and the XY routing method is: first compare the values ​​of src.x and dst.x. If src.x>dst.x, then route straight to the left, otherwise go straight to the right until src.x=dst.x, then determine the relationship between src.y and dst.y. If src.y>dst.y, then route straight down, otherwise go straight up, until reaching the destination node.

3. The task-based heterogeneous CPU-GPU on-chip network routing method according to claim 1, characterized in that: src is the source node, dst is the destination node, src.x and dst.x are the horizontal coordinates of the source node and the destination node respectively, src.y and dst.y are the vertical coordinates of the source node and the destination node respectively, and the YX routing method is: first compare the values ​​of src.y and dst.y. If src.y>dst.y, then route straight down, otherwise go straight up until src.y=dst.y, then judge the relationship between src.x and dst.x. If src.x>dst.x, then route straight to the left, otherwise go straight to the right, until reaching the destination node.

4. The task-based heterogeneous CPU-GPU on-chip network routing method according to claim 1, characterized in that: The method sets two virtual channels VC1 and VC2 at each router input port, the virtual channel VC1 is used to pass all task-based XY routing paths, and the virtual channel VC2 is used to pass all task-based YX routing paths. The router output port is provided with a cross switch, and the virtual channel of each router input port is connected to the cross switch, and the cross switch generates an output to avoid deadlock.

5. The task-based heterogeneous CPU-GPU on-chip network routing method according to claim 4, characterized in that: The output end of the router is also equipped with a routing calculation module, a virtual channel arbitrator and a cross switch arbitrator. The routing calculation module schedules the selection of the data output port, that is, confirms the port used to output data. The virtual channel arbitrator determines the virtual channel data that leaves the virtual channel and is passed to the cross switch. The cross switch arbitrator manages the matching of the cross switch input and output; different outputs generated by the cross switch have different physical data links.

6. A task-based heterogeneous CPU-GPU on-chip network routing device, the heterogeneous CPU-GPU on-chip network includes four nodes: CPU, GPU, LLC and MC, the four nodes form a central layout mode topology model, wherein the nodes LLC and MC are distributed in the topological center area, surrounded by the nodes CPU and GPU, and the node MC is surrounded by the node LLC, characterized in that: include: The routing path selection rule determination module is used to determine the following four path selection rules, and the priorities of the path selection rules decrease from A to D: A. The number of routing hops for executing tasks should be as small as possible; B. Assign as few high-traffic paths as possible; C. Leave the hot spot area as soon as possible; D. The workload in the network is as balanced as possible; The cache access request task routing path determination module, when executing the cache access request task, that is, when the CPU / GPU accesses the LLC, adopts the XY routing method according to rule B, giving priority to the peripheral loop path and the vertical path of the hot spot area; The CPU request reply task routing path determination module, when executing the CPU request reply task, that is, when LLC replies to the CPU, according to rule B, adopts the YX routing method; The GPU request reply task routing path determination module, when executing the GPU request reply task, that is, when LLC replies to the GPU, adopts the XY routing method according to rule D.

7. The task-based heterogeneous CPU-GPU on-chip network routing device according to claim 6, characterized in that: Two virtual channels VC1 and VC2 are provided at each router input port. Virtual channel VC1 is used to pass all task-based XY routing paths, and virtual channel VC2 is used to pass all task-based YX routing paths. A cross switch is provided at the router output port. The virtual channel end of each router input port is connected to the cross switch, and the cross switch generates an output to avoid deadlock.

8. The task-based heterogeneous CPU-GPU on-chip network routing device according to claim 7, characterized in that: The output end of the router is also equipped with a routing calculation module, a virtual channel arbitrator and a cross switch arbitrator. The routing calculation module schedules the selection of the data output port, that is, confirms the port used to output data. The virtual channel arbitrator determines the virtual channel data that leaves the virtual channel and is passed to the cross switch. The cross switch arbitrator manages the matching of the cross switch input and output.

9. A task-based heterogeneous CPU-GPU on-chip network routing system, comprising a processor and a memory storing program instructions, characterized in that: The processor is configured to execute the task-based heterogeneous CPU-GPU on-chip network routing method as described in any one of claims 1 to 5 when running the program instructions.

10. A storage medium storing program instructions, characterized in that: When the program instructions are run, they execute the task-based heterogeneous CPU-GPU on-chip network routing method as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Non deadlock routing method based on network on chip

    CN102333038A

  • Fault-tolerant method and structure applied to network-on-chip and based on error blocking model

    CN103248566A

  • CPU-GPU heterogeneous network-on-chip-oriented dynamic routing method

    CN107920025A

  • Multi-core parallel scheduling method based on CPU + GPU heterogeneous processing platform

    CN113553103A

  • Software defined hardware control method and controller

    CN114356837A

Cited By

  • NoC unicast and multicast forwarding and deadlock avoiding method and system under irregular topology

    CN119484385A

  • Method and system for noC single / multi-cast forwarding and deadlock avoidance under irregular topology

    CN119484385B

  • Task distribution method, electronic equipment and storage medium

    CN120704898A

  • A task distribution method, electronic device, and storage medium

    CN120704898B