Task scheduling and resource allocation method for isomorphic multi-FPGA (Field Programmable Gate Array) system

Through the task grouping scheduling method based on critical path nodes and resource constraints in multi-FPGA systems, the problem of low resource utilization is solved, fast and efficient task scheduling and resource allocation are achieved, and the overall performance of the system is improved.

CN118708304AActive Publication Date: 2024-09-27NANJING UNIV OF AERONAUTICS & ASTRONAUTICS
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202310308029.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-03-27
Publication Date
2024-09-27
Estimated Expiration
2043-03-27

AI Technical Summary

Technical Problem

Existing multi-FPGA system task scheduling and resource allocation methods fail to fully utilize the resource parallelism of FPGA, resulting in low resource utilization and long algorithm running time or high hardware resource vacancy rate.

Method used

A task grouping scheduling and resource allocation method based on critical path nodes and FPGA resource constraints is adopted. By modeling the communication dependencies between tasks, the key node search algorithm using the earliest and latest start times is used to determine the task sequence and divide it according to resource constraints. Task group creates a slot-based directed acyclic graph to optimize task scheduling and resource allocation on multi-FPGA systems.

Benefits of technology

It achieves fast and efficient task scheduling on multiple FPGA systems, improves FPGA resource utilization and task execution speed, and reduces the maximum completion time Makespan.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118708304A
    Figure CN118708304A
Patent Text Reader

Abstract

The invention discloses a task scheduling and resource allocation method for an isomorphic multi-FPGA system, and belongs to the technical field of multi-FPGA system application. The method comprises the following steps: firstly, modeling tasks of an isomorphic multi-FPGA system and a to-be-executed system; preliminarily determining the data transmission time DTT between the tasks according to the communication bandwidth and the data volume; establishing a node sequence list based on key nodes on a key path of the task graph; dividing nodes in the sequence list into slots under the resource limitation of a single FPGA, and constructing a directed acyclic graph based on the slots; and finally, determining a final execution position of the slot and calculating a time parameter to obtain an optimal FPGA use number. Aiming at the problems of low task scheduling efficiency and unreasonable resource configuration of an isomorphic multi-FPGA system, a scheduling scheme with balanced performance is designed, and the resource utilization rate of the FPGA is improved while the execution speed of a complex task is improved to the maximum extent.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of multi-FPGA system application, and in particular to a task scheduling and resource allocation method for a homogeneous multi-FPGA system. Background Art

[0002] Field Programmable Gate Array (FPGA) is widely used due to its high performance, low power consumption and reconfigurable features. Traditional single FPGA systems have limited resources and are often stretched to the limit when accelerating complex tasks. Therefore, multi-FPGA systems, especially homogeneous multi-systems consisting of multiple FPGAs of the same model, are gaining more and more attention. Multi-FPGA systems have a high degree of execution parallelism, allowing a group of multiple tasks to be executed in parallel on one FPGA, and allowing multiple groups of tasks to be executed in parallel on multiple FPGAs, thereby greatly improving the execution speed of complex tasks.

[0003] In multi-FPGA systems, it is urgent to design efficient task scheduling and resource allocation solutions to fully utilize the resource parallelism of FPGAs, maximize the execution speed of complex tasks, and improve the resource utilization of FPGAs. However, existing research on task scheduling and resource allocation in multi-FPGA systems mostly focuses on how to save communication time and how to partially use high-latency tasks to hide the execution time of low-latency tasks, without fully utilizing the resource parallel advantages of FPGAs. There are also a few research works that use heuristic methods to group tasks, but the resource utilization of FPGAs is low, and there are problems such as long algorithm running time or high hardware resource idleness. In response to the above problems, the patent of this invention proposes a method for isomorphic multi-FPGA systems.

[0004] Task scheduling and resource allocation methods for FPGA systems. Summary of the invention

[0005] The purpose of the present invention is to address the above-mentioned problems and deficiencies and propose a method for task scheduling and resource allocation for a homogeneous multi-FPGA system. Based on modeling the multi-FPGA system and the system tasks to be executed, the present invention designs a scheme for grouping and scheduling system tasks and allocating resources based on critical path nodes and FPGA resource constraints according to the communication dependencies between tasks, thereby realizing fast and efficient task scheduling on the multi-FPGA system.

[0006] In order to achieve the above object, the technical solution adopted by the present invention is: a task scheduling and resource allocation method for a homogeneous multi-FPGA system, characterized in that it includes the following steps:

[0007] (1) Using F = {F1, F2, ..., F m} describes a multi-FPGA system consisting of m homogeneous FPGAs, and uses FC = {RB, RC, RD, BW} to describe the characteristics of each FPGA, where RB, RC, and RD are the number of BRAM, CLB, and DSP resources in each FPGA, respectively, and BW is the communication bandwidth of the FPGA;

[0008] (2) The task list T = {T1, T2, ..., T n} system tasks are modeled as a directed acyclic graph G = (N, E): using N = {N T1 , N T2 , ..., N Tn} describes the node set, N Ti ={ET Ti , B Ti , C Ti , D Ti ,Data Ti}Describe the i-th node T i The characteristics of ET Ti For node T i The execution time in FPGA, B Ti , C Ti and D Ti Node T i The number of BRAMs, CLBs, and DSPs required to execute in the FPGA, Data Ti For node T i The amount of output data; use E = {E T1 , E T2 , ..., E T(n-1)}Describe the edge set, E Ti ={E Ti-Tj1 , E Ti-Tj2 , ..., E Ti-Tjr} represents node T i r feedforward directed edge sets, where E Ti-Tjt (1≤t≤r) represents node T i To node T jt The feed-forward directed edges of .

[0009] (3) Calculate the weight DTT of each feedforward directed edge in the edge set E in step (2) Ti-Tj : Use DTT Ti-Tj Describe the node T in the task graph G i and T i The communication time between i to T j The feedforward directed edge E Ti-Tj The weight of the task T i Output data volume Data TiThe DTT is determined by the FPGA communication bandwidth BW Ti-Ti Value: DTT Ti-Tj =Data Ti / BW;

[0010] (4) In the task graph G of step (2), according to the node feature N Ti and the weight DTT of each forward directed edge in step (3) Ti-Tj ,determine the key nodes using the key node search algorithm based on the earliest and latest start time, and establish a node sequence list with the key nodes as the backbone;

[0011] (5) According to the task graph G described in step (2) and the node sequence list described in step (4), all nodes are divided into a number of task groups to be scheduled, with the number of single FPGA resources as a constraint, and a slot-based directed acyclic graph is created;

[0012] (6) In the slot-based directed acyclic graph described in step (5), determine on which FPGA each slot is placed for execution and the optimal number of FPGAs to be used.

[0013] Furthermore, the specific implementation method of step (4) is as follows:

[0014] (4.1) In the task graph G described in step (2), the earliest start time of each node is calculated starting from the source node: the earliest start time EST of the source node T1 is T1 =0, any other node T i If there are p parent nodes, then its earliest start time is EST Ti =max{EST Tx +ET Tx +DTT Tx-Ti}| 1≤x≤p ;

[0015] (4.2) Calculate the critical path length of the task graph G in step (2): CPL = max{EST Ty +ET Ty}| 0<y≤n ;

[0016] (4.3) In the task graph G described in step (2), the latest start time of each node is calculated starting from the sink node: sink node T n Latest start time LST Tn =CPL-ET Tn , if any other node Ti has q child nodes, then its latest start time LST Ti =min{LST Tz -ET Ti -DTTTi-Tz}| 1≤z≤q ;

[0017] (4.4) In the task graph G described in step (2), starting from the source node, determine whether each node is a key node: for any node T i If EST Ti =LST Ti , then T i is a key node, put it into the key node sequence list; otherwise T i It is not a critical node and will not be processed;

[0018] (4.5) In the task graph G described in step (2), a post-order traversal method is used to search the parent node branch of each key node in the key node sequence list described in step (4.4) in the order of left subtree - right subtree - root node, and insert it before the key node and after the previous key node in the key node sequence list to obtain a node sequence list.

[0019] Furthermore, the specific implementation method of step (5) is as follows:

[0020] (5.1) In the node sequence list described in step (4.5), the node sequence list is divided into several segments with the key node as the dividing point, each segment includes a key node and its parent node branch;

[0021] (5.2) Divide each segment of key nodes and their parent node branches described in step (5.1) into several slots in the order of the list, and ensure that the total resources of all nodes contained in each slot are not greater than the total resources of a single FPGA: If the kth slot contains s task nodes {T k1 , T k2 , ..., T ks},but

[0022] (5.3) Find the slots with higher resource vacancy rates among all slots, and try to merge the slots with higher resource vacancy rates at the same level or adjacent levels of the task graph G, while ensuring that the total resources of all nodes contained in each slot are not greater than the total resources of a single FPGA;

[0023] (5.4) According to the feedforward directed edge dependencies in the task graph G described in step (2), the dependencies between the merged slots in step (5.3) are sorted out to create a slot-based directed acyclic graph with slots as nodes.

[0024] Furthermore, the specific implementation method of step (6) is as follows:

[0025] (6.1) Determine on which FPGA each slot in the slot-based directed acyclic graph described in step (5.4) is placed for execution: when using l (2≤l≤m) FPGAs, prioritize placing parallel slots that have a common predecessor slot but are not predecessors / successors to each other on different FPGAs, and place the remaining slots on other FPGAs in order of execution; after l FPGAs are placed, start placing again from the first FPGA;

[0026] (6.2) According to the placement result described in step (6.1), determine the scheduling order in the execution process, and calculate the start and end time of each slot to obtain the maximum completion time Makespan when using l FPGAs;

[0027] (6.3) Change the size of l, repeat steps (6.1) and (6.2), traverse the results of scheduling with different numbers of FPGAs within the maximum number of FPGAs m, and determine the optimal number of FPGAs to use when Makespan is minimized. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Figure 1 Flow chart of the method of the present invention

[0029] Figure 2 is a directed acyclic graph of tasks to be executed

[0030] Figure 3 A slot-based directed acyclic graph

[0031] Figure 4 Slot scheduling and resource allocation diagram DETAILED DESCRIPTION

[0032] The following is a detailed description of an embodiment of the present invention. This embodiment is exemplary and is only used to explain the present invention, and should not be construed as limiting the present invention. Referring to the accompanying drawings of the specification, a method for task scheduling and resource allocation for a homogeneous multi-FPGA system of the present invention is described in detail below. Figure 1 As shown, this embodiment is directed to a method for task scheduling and resource allocation for reconstructing a multi-FPGA platform, and includes the following steps.

[0033] (1) Using F = {F1, F2, ..., F m} describes a multi-FPGA system composed of m homogeneous FPGAs, and uses FC = {RB, RC, RD, BW} to describe the characteristics of each FPGA, where RB, RC and RD are the number of BRAM, CLB, and DSP resources in each FPGA, respectively, and BW is the communication bandwidth of the FPGA.

[0034] Taking the multi-FPGA system F={F1, F2, F3, F4} composed of 4 Xilinx XC7K325 as an example, the number of BRAM, CLB, and DSP resources contained in each FPGA are 26150, 900, and 840 respectively. Assuming its communication bandwidth is 1000kB / s, it can be modeled using FC={26150, 900, 840, 1000}.

[0035] (2) The task list T = {T1, T2, ..., T n} system tasks are modeled as a directed acyclic graph G = (N, E): using N = {N T1 , N T2 , ..., N Tn} describes the node set, N Ti ={ET Ti , B Ti , C Ti , D Ti ,Data Ti}Describe the i-th node T i The characteristics of ET Ti For node T i The execution time in FPGA, B Ti , C Ti and D Ti Node T i The number of BRAMs, CLBs, and DSPs required to execute in the FPGA, Data Ti is the output data volume of node Ti; use E = {E T1 , E T2 , ..., E T(n-1)}Describe the edge set, E Ti ={E Ti-Tj1 , E Ti-Tj2, , ..., E Ti-Tjr} represents node T i r feedforward directed edge sets, where E Ti-Tjt (1≤t≤r) represents node T i To node T jt The feed-forward directed edges of .

[0036] by Figure 2 The following table shows 12 tasks to be executed: T = {T1, T2, ..., T 12} system task as an example, assuming that the characteristics of each node in its node set are: N T1 ={280, 250, 9150, 170, 140}, N T2 ={140, 410, 2715, 250, 20}, N T3={160, 220, 1710, 80, 20}, N T4 ={180, 320, 14450, 100, 30}, N T5 ={630, 310, 4192, 110, 90}, N T6 ={280, 240, 1080, 220, 40}, N T7 ={1360, 50, 8450, 360, 170}, N T8 ={360, 200, 8110, 270, 70}, N T9 ={1710, 60, 9725, 400, 190}, N T10 ={600, 230, 7500, 260, 150}, N T11 ={420, 140, 4815, 20, 90}, N T12 ={40, 460, 13900, 40, 0}, where the execution time unit is ms and the output data volume unit is kB; the forward directed edge sets of each node in the edge set are: E T1 ={E T1-T2 , E T1-T3 , E T1-T4 , E T1-T5 , E T1-T6}, E T2 ={E T2-T7}, E T3 ={E T3-T7}, E T4 ={E T4-T8}, E T5 ={E T5-T9}, E T6 ={E T6-T 9}, E T7 ={E T7-T10}, E T8 ={E T8-T10}, E T9 ={E T9-T10 , E T9-T11}, E T10 ={E T10-T12}, E T11 ={E T11-T12}.

[0037] (3) Calculate the weight DTT of each feedforward directed edge in the edge set E in step (2) Ti-Tj : Use DTT Ti-Tj Describe the node T in the task graph G i and T j The communication time between i to T i The feed-forward directed edge ETi-Tj The weight of the task T i Output data volume Data Ti The DTT is determined by the FPGA communication bandwidth BW Ti-Tj Value: DTT Ti-Tj =Data Ti / BW.

[0038] like, Figure 2 In the edge set E of the task graph G shown in the figure, the feedforward directed edge set E starting from node T1 T1 ={E T1-T2 , E T1-T3 , E T1-T4 , E T1-T5 , E T1-T6 The weight of} is: DTT T1-Tj|j=2,3,4,5,6 =Data T1 / BW=140 / 1000=0.14s=140ms; similarly, the weights of the feedforward directed edge sets starting from other nodes are DTT={20, 20, 30, 90, 40, 170, 70, 190, 150, 90, 0}.

[0039] (4) In the task graph G of step (2), according to the node feature N Ti and the weight DTT of each forward directed edge in step (3) Ti-Tj ,The key nodes are determined using the key node search algorithm based on the earliest and latest ,starting time, and a node sequence list is established with the key nodes as the backbone.

[0040] (4.1) In the task graph G described in step (2), the earliest start time of each node is calculated starting from the source node: the earliest start time EST of the source node T1 is T1 =0, any other node T i If there are p parent nodes, then its earliest start time is EST Ti =max{EST Tx +ET Tx +DTT Tx-Ti}| 1≤x≤p .

[0041] Figure 2 In the task graph G shown in the figure, EST T1 =0; Node T2 has one parent node T1, and its earliest start time is EST T2 =420; and so on, the earliest start time of the remaining nodes is EST T3 =420, EST T4 =420, EST T5 =420, EST T6 =420, ESTT7 =600,EST T8 =630, EST T9 =1140, EST T10 =3040,EST T11 =3040,EST T12 =3790.

[0042] (4.2) Calculate the critical path length of the task graph G in step (2): CPL = max{EST Ty +ET Ty}| 0<y≤n .

[0043] Figure 2 The critical path length CPL of the task graph G shown in the figure is max{EST Ty +ET Ty}| 0<y≤12 =3790+40=3830.

[0044] (4.3) In the task graph G described in step (2), the latest start time of each node is calculated starting from the sink node: sink node T n Latest start time LST Tn =CPL-ET Tn , any other node T i If there are q child nodes, then the latest start time LST Ti =min{LST Tz -ET Ti -DTT Ti-Tz}| 1≤z≤q .

[0045] Figure 2 In the task graph G shown in the figure, the sink node T 12 The latest start time is EST T12 =CPL-ET T12 =3790, node T 11 There is 1 child node T 12 , whose latest start time is LST T11 =3280; the latest start time of the remaining nodes is LST T10 =3040, LST T9 =1140, LST T8 =2610,LST T7 =1510,LST T6 =820, LST T5 =420, LST T4 =2400, LST T3 =1330, LST T2 =1350, LSTT1 =0.

[0046] (4.4) In the task graph G described in step (2), starting from the source node, determine whether each node is a key node: for any node T i If EST Ti =LST Ti , then T i is a key node, put it into the key node sequence list; otherwise T i It is not a critical node and will not be processed.

[0047] Figure 2 In the task graph G shown in the figure, for node T1, EST T1 =LST T1 , so T1 is a key node and puts it into the key node sequence list; for node T2, EST T2 ≠LST T2 , so T2 is not a key node and is not processed; and so on, the final key node sequence list is {1, 5, 9, 10, 12}.

[0048] (4.5) In the task graph G described in step (2), a post-order traversal method is used to search the parent node branch of each key node in the key node sequence list described in step (4.4) in the order of left subtree - right subtree - root node, and insert it before the key node and after the previous key node in the key node sequence list to obtain a node sequence list.

[0049] Figure 2 In the task graph G shown, the key node T 10 There are two parent nodes, T7 and T8. T7 has two parent nodes, T2 and T3, and T8 has one parent node, T4. After traversing and searching, the parent node branch obtained is {2, 3, 7, 4, 8}, which is inserted into the key node T 10 Before the key node T9, and after the key node T9; and so on, the final node sequence list is {1, 5, 6, 9, 2, 3, 7, 4, 8, 10, 11, 12}.

[0050] (5) According to the task graph G described in step (2) and the node sequence list described in step (4), all nodes are divided into a number of task groups to be scheduled, with the number of single FPGA resources as a constraint, and a slot-based directed acyclic graph is created.

[0051] (5.1) In the node sequence list described in step (4.5), the node sequence list is divided into several segments with the key node as the dividing point, and each segment contains a key node and its parent node branch.

[0052] Taking the node sequence list {1, 5, 6, 9, 2, 3, 7, 4, 8, 10, 11, 12} described in step (4.5) as an example, it can be divided into 5 sections with 5 key nodes as dividing points, namely {1}, {5}, {6, 9}, {2, 3, 7, 4, 8, 10}, {11, 12}.

[0053] (5.2) Divide each segment of key nodes and their parent node branches described in step (5.1) into several slots in the order of the list, and ensure that the total resources of all nodes contained in each slot are not greater than the total resources of a single FPGA: If the kth slot contains s task nodes {T k1 , T k2 , ..., T ks},but

[0054] Figure 2 In the task graph G shown in the figure, take the fourth segment {2, 3, 7, 4, 8, 10} of the node sequence list as an example. First, check whether {2, 3} meets the resource limit. If it does, continue to try whether {2, 3, 7} meets the resource limit until {2, 3, 7, 4} exceeds the resource limit. At this time, remove node 4 and divide {2, 3, 7} into one slot. Then continue to check from node 4. {4, 8} meets the resource limit, but {4, 8, 10} exceeds it. Therefore, {4, 8} is divided into one slot, and the last {10} is divided into one slot. By analogy, a total of 7 slots are divided, namely {1}, {5}, {6, 9}, {2, 3, 7}, {4, 8}, {10}, {11, 12}.

[0055] (5.3) Find the slots with higher resource vacancy rates among all slots, and try to merge the slots with higher resource vacancy rates at the same level or adjacent levels of the task graph G, while ensuring that the total resources of all nodes contained in each slot is not greater than the total resources of a single FPGA.

[0056] Taking the partition result described in step (5.2) as an example, excluding the source slot, we first try to merge slots {5} and {6, 9}. We find that the merged slots satisfy the resource constraints, so we merge them into one slot {5, 6, 9}. Similarly, {10} and {11, 12} can also be merged into one slot {10, 11, 12}. After the merge is completed, a total of 5 slots are obtained, namely S1 = {1}, S2 = {2, 3, 7}, S3 = {4, 8}, S4 = {5, 6, 9}, and S5 = {10, 11, 12}.

[0057] (5.4) According to the feedforward directed edge dependencies in the task graph G described in step (2), the dependencies between the merged slots in step (5.3) are sorted out to create a slot-based directed acyclic graph with slots as nodes.

[0058] according to Figure 2 The relationship between the feedforward directed edges in the task graph shown in Figure 1 is used to sort out the dependencies between the five slots merged in step (5.3). The resulting slot-based directed acyclic graph is as follows: Figure 3 shown.

[0059] (6) In the slot-based directed acyclic graph described in step (5), determine on which FPGA each slot is placed for execution and the optimal number of FPGAs to be used.

[0060] (6.1) Determine on which FPGA each slot in the slot-based directed acyclic graph described in step (5.4) is placed for execution: when using l (2≤l≤m) FPGAs, prioritize placing parallel slots that have a common predecessor slot but are not predecessor / successor relationships with each other on different FPGAs, and place the remaining slots on other FPGAs in order of execution; after l FPGAs are placed, start placing again from the first FPGA.

[0061] like, Figure 3 In the slot-based directed acyclic graph shown in FIG. 1 , S2, S3, and S4 have a common predecessor S1, and are not predecessor / successor relationships with each other, and are parallel slots. When l=3, first allocate parallel slots S2 / S3 / S4 to FPGA1 / 2 / 3, then allocate non-parallel slot S1 to FPGA1, and finally allocate S5 to FPGA2.

[0062] (6.2) According to the placement results described in step (6.1), determine the scheduling order during the execution process, and calculate the start and end time of each slot to obtain the maximum completion time Makespan.

[0063] for Figure 3 The slot-based directed acyclic graph is shown in Figure 2. According to the placement result of step (6.1), the final scheduling scheme is as follows: Figure 4As shown: At time ①, S1 is first executed on FPGA1; after S1 is executed, at time ②, S2, S3 and S4 are executed in parallel on FPGA1, FPGA2 and FPGA3 respectively; after the parallel execution, at time ③, S5 is executed on FPGA2. At this time, the start and end time of each slot are S1{0, 280}, S2{280, 1800}, S3{420, 960}, S4{420, 2760}, S5{2950, ​​3590} respectively. The maximum completion time Makespan=3590.

[0064] (6.3) Change the size of l, repeat steps (6.1) and (6.2), traverse the results of scheduling with different numbers of FPGAs within the maximum number of FPGAs m, and determine the optimal number of FPGAs to use when Makespan is minimized.

[0065] For example, the total number of FPGAs m=4. After traversal, the Makespan obtained when l=2, 3, and 4 are recorded as {4060, 3590, 3590} respectively. By comparison, it can be seen that the minimum Makespan can be obtained when l=3 and 4, so the optimal number of FPGAs is 3.

[0066] The above descriptions are merely embodiments of the present invention and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A task scheduling and resource allocation method for a homogeneous multi-FPGA system, characterized in that: The following steps are involved: (1) Using F = {F1, F2, ..., F m } describes a multi-FPGA system consisting of m homogeneous FPGAs, and uses FC = {RB, RC, RD, BW} to describe the characteristics of each FPGA, where RB, RC, and RD are the number of BRAM, CLB, and DSP resources in each FPGA, respectively, and BW is the communication bandwidth of the FPGA; (2) The task list T = {T1, T2, ..., T n } system tasks are modeled as a directed acyclic graph G = (N, E): using N = {N T1 , N T2 , ..., N Tn } describes the node set, N Ti ={ET Ti , B Ti , C Ti , D Ti ,Data Ti }Describe the i-th node T i The characteristics of ET Ti For node T i The execution time in FPGA, B Ti , C Ti and D Ti Node T i The number of BRAMs, CLBs, and DSPs required to execute in the FPGA, Data Ti For node T i The amount of output data; use E = {E T1 , E T2 , ..., E T(n-1) }Describe the edge set, E Ti ={E Ti-Tj1 , E Ti-Tj2 ,,...,E Ti-Tjr } represents node T i r feedforward directed edge sets, where E Ti-Tjt (1≤t≤r) represents node T i To node T jt The feed-forward directed edges of (3) Calculate the weight DTT of each feedforward directed edge in the edge set E in step (2) Ti-Tj : Use DTT Ti-Tj Describe the node T in the task graph G i and T j The communication time between i to T j The feed-forward directed edge E Ti-Tj The weight of the task T i Output data volume Data Ti The DTT is determined by the FPGA communication bandwidth BW Ti-Tj Value: DTT Ti-Tj =Data Ti / BW; (4) In the task graph G of step (2), according to the node feature N Ti and the weight DTT of each forward directed edge in step (3) Ti-Tj ,determine the key nodes using the key node search algorithm based on the earliest and latest start time, and establish a node sequence list with the key nodes as the backbone; (5) According to the task graph G described in step (2) and the node sequence list described in step (4), all nodes are divided into a number of task groups to be scheduled, with the number of single FPGA resources as a constraint, and a slot-based directed acyclic graph is created; (6) In the slot-based directed acyclic graph described in step (5), determine on which FPGA each slot is placed for execution and the optimal number of FPGAs to be used.

2. A task scheduling and resource allocation method for a homogeneous multi-FPGA system, characterized in that: In step (4), the key nodes are determined using a key node search algorithm based on the earliest and latest start times, and a method for establishing a node sequence list with the key nodes as the backbone is as follows: (4.1) In the task graph G described in step (2), the earliest start time of each node is calculated starting from the source node: the earliest start time EST of the source node T1 is T1 =0, any other node T i If there are p parent nodes, then its earliest start time is EST Ti =max{EST Tx +ET Tx +DTT Tx-Ti }| l≤x≤p ; (4.2) Calculate the critical path length of the task graph G in step (2): CPL = max{EST Ty +ET Ty }| 0<y≤n ; (4.3) In the task graph G described in step (2), the latest start time of each node is calculated starting from the sink node: sink node T n Latest start time LST Tn =CPL-ET Tn , any other node T i If there are q child nodes, then the latest start time LST Ti =min{LST Tz -ET Ti -DTT Ti-Tz }| l≤z≤q ; (4.4) In the task graph G described in step (2), starting from the source node, determine whether each node is a key node: for any node T i If EST Ti =LST Ti , then T i is a key node, put it into the key node sequence list; otherwise T i It is not a critical node and will not be processed; (4.5) In the task graph G described in step (2), a post-order traversal method is used to search the parent node branch of each key node in the key node sequence list described in step (4.4) in the order of left subtree - right subtree - root node, and insert it before the key node and after the previous key node in the key node sequence list to obtain a node sequence list.

3. A task scheduling and resource allocation method for a homogeneous multi-FPGA system, characterized in that: In the step (5), all nodes are divided into a number of slots of task groups to be scheduled based on the number of single FPGA resources as a constraint, and a method for creating a slot-based directed acyclic graph is as follows: (5.1) In the node sequence list described in step (4.5), the node sequence list is divided into several segments with the key node as the dividing point, each segment includes a key node and its parent node branch; (5.2) Divide each segment of key nodes and their parent node branches described in step (5.1) into several slots in the order of the list, and ensure that the total resources of all nodes contained in each slot are not greater than the total resources of a single FPGA: If the kth slot contains s task nodes {T k1 , T k2 , ..., T ks },but (5.3) Find the slots with higher resource vacancy rates among all slots, and try to merge the slots with higher resource vacancy rates at the same level or adjacent levels of the task graph G, while ensuring that the total resources of all nodes contained in each slot are not greater than the total resources of a single FPGA; (5.4) According to the feedforward directed edge dependencies in the task graph G described in step (2), the dependencies between the merged slots in step (5.3) are sorted out to create a slot-based directed acyclic graph with slots as nodes.

4. A task scheduling and resource allocation method for a homogeneous multi-FPGA system, characterized in that: In step (6), the method for determining on which FPGA each slot is placed for execution and the optimal number of FPGAs to be used is as follows: (6.1) Determine on which FPGA each slot in the slot-based directed acyclic graph described in step (5.4) is placed for execution: when using l (2≤l≤m) FPGAs, prioritize placing parallel slots that have a common predecessor slot but are not predecessors / successors to each other on different FPGAs, and place the remaining slots on other FPGAs in order of execution; after l FPGAs are placed, start placing again from the first FPGA; (6.2) According to the placement result described in step (6.1), determine the scheduling order in the execution process, and calculate the start and end time of each slot to obtain the maximum completion time Makespan when using l FPGAs; (6.3) Change the size of l, repeat steps (6.1) and (6.2), traverse the results of scheduling with different numbers of FPGAs within the maximum number of FPGAs m, and determine the optimal number of FPGAs to use when Makespan is minimized.

Citation Information

Patent Citations

  • Hybrid task scheduling method of directed acyclic graph (DGA) based reconfigurable system

    CN104239135A

  • Task scheduling system of heterogeneous multi-core platform and scheduling method for task scheduling system

    CN105260237A

  • Dynamic partially reconfigurable system application partitioning and scheduling method based on module fusion

    CN111274016A