Congestion control method and device, electronic equipment and storage medium

By building a backvoltage network in an on-chip network and using the backvoltage signal to reverse transmission, the devices that cause congestion caused by current limit are quickly found and limited, and the congestion problem in the on-chip network is solved due to the increase in data density, and efficient and accurate congestion control is achieved.

CN119766731APending Publication Date: 2025-04-04BEIJING INSTITUTE OF OPEN SOURCE CHIP

Patent Information

Application Number
CN202510255774.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-05
Publication Date
2025-04-04

AI Technical Summary

Technical Problem

Due to the increase in data density in the on-chip network, local routing nodes are congested, resulting in a decrease in overall network bandwidth. The congestion control of existing software methods is lagging and the control is not accurate enough.

Method used

By introducing a backvoltage signal generator and link traffic meter into the on-chip network, a global backvoltage network is built, and the backvoltage signal is reverse transmitted, quickly find the packetized equipment that causes congestion, and limit the current at the source to resolve congestion.

Benefits of technology

It realizes fast and precise control of on-chip network congestion, can flexibly handle complex scenarios with multiple congestion phenomena and multiple congestion sources, and adapts to multiple topological network structures, improving the speed and accuracy of congestion control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119766731A_ABST
    Figure CN119766731A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a congestion control method and device, electronic equipment and a storage medium, and relates to the technical field of congestion control. The method is applied to a network-on-chip, and the network-on-chip comprises a back pressure signal generator and a plurality of routing nodes. The routing node comprises a plurality of output ports and a plurality of input ports, and the method comprises the following steps: under the condition that a first output port of a first routing node is congested, a back pressure signal generator obtains a data main input port corresponding to the first output port from a link flow table of the first routing node; transmitting the back pressure signal from the main input port to a second routing node adjacent to the first routing node; based on the link flow tables of the second routing node and the other routing nodes, the back pressure signals are sent to the corresponding source routing nodes in sequence; and on the basis of the back pressure signal, the packet sending behavior of the equipment corresponding to the output port, receiving the back pressure signal, of the source routing node is subjected to flow limiting, and the congestion control speed is higher and more accurate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of congestion control, and in particular to a congestion control method, a congestion control device, an electronic device and a storage medium. Background Art

[0002] Network-on-Chip (NoC) has broad application prospects due to its advantages such as higher bandwidth.

[0003] With the rise of AI applications in recent years, the data density in on-chip networks has become increasingly larger, which can easily cause congestion in local routing nodes, leading to a decrease in the overall network bandwidth. Therefore, there is an urgent need for a congestion control method that can quickly alleviate the congestion in on-chip networks.

[0004] The current congestion control method mainly relies on software. However, software-based congestion control has a certain lag, resulting in inaccurate control of congestion. Summary of the invention

[0005] In view of the above problems, embodiments of the present invention are proposed to provide a congestion control method that overcomes the above problems or at least partially solves the above problems, so as to improve the efficiency and accuracy of congestion control.

[0006] In a first aspect, the present invention provides a congestion control method, which is applied to a network on chip, wherein the network on chip comprises: a back pressure signal generator and a plurality of routing nodes; the routing nodes comprise: a plurality of output ports and a plurality of input ports, and the method comprises: In the case where congestion occurs at the first output port of the first routing node, the back pressure signal generator obtains the data main input port corresponding to the first output port from the link flow table of the first routing node; Sending a back pressure signal from the primary input port to a second routing node adjacent to the first routing node; Based on the link flow tables of the second routing node and the remaining routing nodes, the back pressure signal is sent to the corresponding source routing nodes in sequence; Based on the back pressure signal, current limiting is performed on the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal.

[0007] In a second aspect, the present invention provides a congestion control device, which is applied to a network on chip, wherein the network on chip comprises: a back pressure signal generator and a plurality of routing nodes; the routing nodes comprise: a plurality of output ports and a plurality of input ports, and the device comprises: A data main input port acquisition module, configured to, when congestion occurs at the first output port of the first routing node, enable the back pressure signal generator to acquire the data main input port corresponding to the first output port from the link flow table of the first routing node; A first sending module, configured to send a back pressure signal from the primary input port to a second routing node adjacent to the first routing node; A second sending module, configured to send the back pressure signal to the corresponding source routing node in sequence based on the link flow table of the second routing node and the remaining routing nodes; The current limiting module is used to limit the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal based on the back pressure signal.

[0008] In a third aspect, the present invention provides an electronic device, comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned congestion control method when executing the program.

[0009] In a fourth aspect, the present invention provides a readable storage medium, which, when instructions in the storage medium are executed by a processor of an electronic device, enables the electronic device to execute the above-mentioned congestion control method.

[0010] In a fifth aspect, the present invention provides a computer program product, comprising instructions, which, when executed by a processor in an electronic device, enable the electronic device to perform any one of the aforementioned congestion control methods.

[0011] The present invention includes at least the following advantages: In the present invention, a global back pressure network is constructed through the link flow table of each routing node, which can flexibly and quickly handle complex congestion perception scenarios with multiple congestion phenomena and multiple congestion sources, and can adapt to multiple topological network structures. At the same time, based on the link flow table of each routing node, the reverse transmission of the back pressure signal and the congested data flow occurring at the first output port of the first routing node is realized one by one, and finally the packet sending device causing the congestion at the first output port of the first routing node is quickly found, and the packet sending behavior of the device corresponding to the output port of the source routing node receiving the back pressure signal is limited, so that the congestion occurring at the first output port of the first routing node is accurately and quickly solved or weakened from the source, that is, the device. Moreover, the transmission path of the back pressure signal can be quickly determined through the link flow table of each routing node through the hardware of the back pressure signal generator, and the packet sending device causing the congestion occurring at the first output port of the first routing node can be quickly found, so that the control speed of the congestion of the present application is faster and more accurate. BRIEF DESCRIPTION OF THE DRAWINGS

[0012] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.

[0013] Figure 1 A flow chart showing the steps of an embodiment of a congestion control method of the present invention is shown; Figure 2 A flowchart showing another congestion control method embodiment of the present invention is shown; Figure 3 A schematic diagram showing a routing node and a link flow table of the present invention is shown; Figure 4 A schematic diagram showing back pressure signal transmission of the present invention is shown; Figure 5 A schematic diagram of current limiting at a source routing node of the present invention is shown; Figure 6 A structural block diagram of an embodiment of a congestion control device of the present invention is shown; Figure 7 It is a structural diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0014] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0015] The present application provides a congestion control method, which is applied to an on-chip network. The on-chip network includes: a back pressure signal generator and a plurality of routing nodes (Router). The number of routing nodes in the on-chip network is not limited. The routing node is a basic component of the on-chip network, which is used for temporary storage and transmission of data. The routing node includes a plurality of output ports and a plurality of input ports. Whether the number of input ports contained in the routing node is equal to the number of output ports is not specifically limited. Figure 1 , the congestion control method may specifically include the following steps.

[0016] Step 101: When congestion occurs at a first output port of a first routing node, the back pressure signal generator obtains a data main input port corresponding to the first output port from a link flow table of the first routing node.

[0017] The back pressure signal here is used to indicate that at the current moment, the first output port of the first routing node is congested and current limiting is required. The specific form and specific generation method of the back pressure signal here are not limited. The back pressure signal here can also be generated in advance, and there is no specific limitation on this.

[0018] Optionally, the back pressure signal may be generated by a back pressure signal generator, that is, the back pressure signal may be quickly generated by hardware. For example, the back pressure signal generator may pull up an electrical signal of a preset number of bits to form a back pressure signal.

[0019] The first routing node here refers to any routing node among several routing nodes of the on-chip network. The first output port here refers to the output port of the first routing node that is congested at the current moment. There can be one first routing node or multiple first routing nodes in the on-chip network at the same moment, and there is no limitation on this. At the same moment, one output port of a first routing node may be congested, or multiple output ports may be congested. Here, there are several first output ports for as many output ports as there are congested. Congestion of the first output port of the first routing node can be characterized by: at the same moment, multiple input ports of the first routing node all apply for the first output port, and some input ports do not obtain authorization for the first output port.

[0020] The main data input port corresponding to the first output port of the first routing node refers to: within a certain period of time, or a period of time before the congestion of the first output port of the first routing node occurs, the data transmitted in the first output port of the first routing node is most likely to enter the first routing node from which several or which input port. The number of main data input ports corresponding to a first output port of the first routing node can be one or more, and there is no specific limitation on this.

[0021] The link flow table of the first routing node stores in advance the main data input port corresponding to the first output port of the first routing node. Therefore, by querying the link flow table of the first routing node, the main data input port corresponding to the first output port of the first routing node can be quickly obtained.

[0022] A global back-pressure network is built through the link flow tables of each routing node, which can flexibly handle complex congestion perception scenarios with multiple congestion phenomena and multiple congestion sources, and can adapt to a variety of topological network structures.

[0023] Step 102: Send a back pressure signal from the primary input port to a second routing node adjacent to the first routing node.

[0024] Here, the reverse transmission of the back pressure signal is realized relative to the data flow. The main data input port corresponding to the first output port of the first routing node found by the link flow table of the first routing node can characterize which input ports or input ports the data transmitted in the first output port of the first routing node is most likely to enter the first routing node from within a period of time before the congestion of the first output port of the first routing node occurs. Therefore, after the back pressure signal is sent from the main input port, it reaches the second routing node. The second routing node is the routing node that is adjacent to the first routing node and is most likely to mainly transmit data to the first output port of the first routing node within a period of time before the congestion of the first output port of the first routing node occurs.

[0025] The execution subject of step 102 may be the back pressure signal generator, or the first routing node here, which is not limited.

[0026] Step 103: Based on the link flow tables of the second routing node and the remaining routing nodes, the back pressure signal is sent to the corresponding source routing nodes in sequence.

[0027] This step can be similar to the aforementioned step 101 and step 102 as a cycle execution or a single execution, mainly, the link flow table of the second routing node stores in advance the main data input port corresponding to the output port receiving the back pressure signal in the second routing node, so by querying the link flow table of the second routing node, the main data input port corresponding to the output port receiving the back pressure signal in the second routing node can be obtained. The main data input port corresponding to the output port receiving the back pressure signal in the second routing node found by the link flow table of the second routing node can characterize which or which input port the data transmitted in the output port receiving the back pressure signal in the second routing node is likely to enter the second routing node from within a period of time before the congestion of the first output port of the first routing node occurs. Therefore, after the back pressure signal is sent from the main input port, it arrives at the next routing node, and the next routing node is the routing node adjacent to the second routing node, which is likely to mainly transmit data to the output port receiving the back pressure signal in the second routing node within a period of time before the congestion of the first output port of the first routing node occurs. By analogy, the back pressure signal is transmitted in reverse order until the back pressure signal is transmitted to the corresponding source routing node. The source routing node here can be characterized as follows: in a period of time before the congestion of the first output port of the first routing node occurs, the data transmitted to the first output port of the first routing node is most likely mainly sent from the device corresponding to the output port of the source routing node that receives the back pressure signal, or in other words, the congestion of the first output port of the first routing node is most likely caused by the data sent by the device corresponding to the output port of the source routing node that receives the back pressure signal. That is, the device that causes the congestion of the first output port of the first routing node has been found through the source routing node and the back pressure signal.

[0028] Step 104: Based on the back pressure signal, current limiting is performed on the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal.

[0029] The device corresponding to the output port of the source routing node receiving the back pressure signal means: in a period of time before the congestion of the first output port of the first routing node occurs, the device mainly receives the output port of the back pressure signal through the source routing node, and sends data to the first output port of the first routing node through the source routing node, which is the reason for the congestion of the first output port of the first routing node. Therefore, based on the back pressure signal, the packet sending behavior of the device corresponding to the output port of the source routing node receiving the back pressure signal is limited, which accurately solves or reduces the congestion of the first output port of the first routing node from the source, that is, the device.

[0030] In summary, in this application, a global back pressure network is constructed through the link flow table of each routing node, which can flexibly and quickly handle complex congestion perception scenarios with multiple congestion phenomena and multiple congestion sources, and can adapt to multiple topological network structures. At the same time, based on the link flow table of each routing node, the reverse transmission of the back pressure signal and the congested data flow occurring at the first output port of the first routing node is realized one by one, and finally the packet sending device causing the congestion at the first output port of the first routing node is quickly found, and the packet sending behavior of the device corresponding to the output port of the source routing node receiving the back pressure signal is limited, so that the congestion occurring at the first output port of the first routing node is accurately and quickly solved or weakened from the source, that is, on the device. Moreover, the transmission path of the back pressure signal can be quickly determined through the link flow table of each routing node through the hardware of the back pressure signal generator, and the packet sending device causing the congestion at the first output port of the first routing node can be quickly found, so that the control speed of the congestion in this application is faster and more accurate.

[0031] Figure 2 The flowchart of another congestion control method embodiment of the present invention is also applied to a network on chip, which includes: a back pressure signal generator and a plurality of routing nodes. Here, reference is made to the above-mentioned related records. In order to avoid repetition, no further description is given. Figure 2 , the congestion control party may specifically include the following steps.

[0032] Step 201: For each output port of each routing node, the back pressure signal generator counts the number of consecutive failures of the input port in applying for channel authorization to the output port.

[0033] Figure 3 A schematic diagram of a routing node of an on-chip network is shown. Figure 3 In the on-chip network, the general working mode of a routing node is: when the input buffer of a certain input port receives Flit (the smallest unit of routing transmission), it first performs routing calculation, and then applies to the arbitration for output channel authorization based on the result of routing calculation. After obtaining the channel authorization, the Flit is finally popped out from the input buffer of the input port, and is output from the corresponding output port after being deflected by the cross switch. The main thing of step 201 is that for each output port of each routing node, the back pressure signal generator counts the number of times the input port applies to the arbitration for channel authorization of the output port, and the number of consecutive applications for channel authorization fails. This step is completed by the hardware of the back pressure signal generator, which can improve the statistical speed.

[0034] It should be noted that here, as long as one or more input ports of a routing node apply for channel authorization to the output port and fail continuously, they are counted. If one or more input ports of a routing node apply for channel authorization to the output port and fail, it usually means that the output port is currently busy or not in an idle state.

[0035] Step 202: When the number of consecutive failures of the input port of the first routing node to apply for channel authorization for the first output port is greater than or equal to a second preset number, the back pressure signal generator determines that the first output port of the first routing node is congested.

[0036] The second preset number here is set according to the requirements of the on-chip network for transmission delay, etc. If the transmission delay is required to be as small as possible, the second preset number here can be smaller, and if the transmission delay is required to be slightly larger, the second preset number here can be larger. The number of consecutive failures of the input port of the first routing node to apply for channel authorization to the first output port is greater than or equal to the second preset number, indicating that one or more input ports of the first routing node have failed to apply for channel authorization to the first output port more times, and the output demand for the first output port is relatively dense. The first output port cannot meet the output demand, which means that congestion has occurred at the first output port.

[0037] On the one hand, for each output port of each routing node, the back pressure signal generator counts the number of consecutive failures of the input port in applying for channel authorization for the output port. When the number of consecutive failures of the input port of the first routing node in applying for channel authorization for the first output port is greater than or equal to a second preset number, the back pressure signal generator determines that congestion occurs at the first output port of the first routing node. The statistical method for determining the occurrence of congestion is relatively accurate, and the determination of the occurrence of congestion is relatively accurate, which can improve the accuracy of congestion control. On the other hand, the executor here is the hardware of the back pressure signal generator, and the speed of determining congestion is relatively fast, which can improve the speed of congestion control.

[0038] Step 203: For each output port of each routing node, count the number of times that the data corresponding to the output port is input from each input port within a first preset time period.

[0039] The first preset time length is set based on the ability to accurately perceive from which input ports the data flow in each output port of each routing node is input to the routing node.

[0040] Step 204: For each output port of each routing node, based on the number of times of each input port, establish a link flow table of the routing node.

[0041] Reference Figure 3 , Figure 3 A schematic diagram of a routing node and a link flow table of the routing node at a certain moment is shown in FIG. The input ports of the routing node include: an east input port, a west input port, a north input port, a south input port, and an input port 0 where a device is connected to the routing node. The output ports of the routing node include: an east output port, a west output port, a north output port, a south output port, and an output port 0 where a device is connected to the routing node. The link flow table has two-dimensional directions, one of which represents an input port and the other represents an output port. For example, Figure 3 In the link flow table shown, E in the up and down directions refers to the east output port, W in the up and down directions refers to the west output port, S in the up and down directions refers to the south output port, N in the up and down directions refers to the north output port, and D in the up and down directions refers to output port 0 connecting the device to the routing node; E in the left and right directions refers to the east input port, W in the left and right directions refers to the west input port, S in the left and right directions refers to the south input port, N in the left and right directions refers to the north input port, and D in the left and right directions refers to input port 0 connecting the device to the routing node. Figure 3 In the link flow table, the number 0 means that the main input port of the data in the output port where the row is located is not the input port where the column is located, and the number 1 in the link flow table means that the main input port of the data in the output port where the row is located is the input port where the column is located. Figure 3 The link flow table shown in the figure indicates that, at the current moment and in a time period before, the main input port for the data in the east output port is the east input port, and at the current moment and in a time period before, the main input port for the data in the west output port is the north input port. That is, the link flow table records the link usage in the routing node, and the data flow in the current routing node is sensed through the link flow table. By establishing the link flow table in advance, the speed and accuracy of determining the transmission path or reverse transmission for the back pressure signal can be improved, and then the source routing node can be found quickly and accurately, thereby improving the accuracy and real-time performance of congestion control.

[0042] It should be noted that step 201 and step 202 here can be performed simultaneously with step 203 and step 204, or step 203 and step 204 can be performed before step 201 and step 202, or step 201 and step 202 precede step 203 and step 204, and there is no limitation on the execution order of the two.

[0043] Optionally, the aforementioned step 204 may include step 2041 and step 2042. Step 2041: for each output port of each routing node, the input port corresponding to the output port with the number of times greater than or equal to the first preset number of times within the first preset time period is determined as the main data input port corresponding to the output port; step 2042: for each routing node, each output port and the main data input port corresponding thereto are saved in the link flow table of the routing node. Specifically, the link flow table has two-dimensional directions, one of which is the input port and the other is the output port. For an output port of a routing node, within the first preset time period, the number of times the data corresponding to the output port is input from a certain input port is greater than or equal to the first preset number of times, indicating that the data corresponding to the output port is likely to be mainly input from the input port. Therefore, in the link flow table, the value at the intersection of the output port and the input port can be set to 1. For an output port of a routing node, within a first preset time period, the number of times the data corresponding to the output port is input from a certain input port is less than the first preset number of times, indicating that the data corresponding to the output port is most likely not mainly input from the input port. Therefore, in the link flow table, the value at the intersection of the output port and the input port can be set to 0. The link flow table thus formed accurately represents which input port or ports the data corresponding to the output port is most likely mainly input from within a period of time, which can improve the accuracy of the back pressure signal transmission path or reverse transmission, and then the source routing node can be accurately found, thereby improving the accuracy of congestion control. In addition, by establishing a link flow table in advance, the speed of determining the transmission path or reverse transmission for the back pressure signal can be improved, and then the source routing node can be quickly found, thereby improving the accuracy and real-time performance of congestion control.

[0044] It should be noted that the first preset number here is adjustable and can be determined according to the tolerance for network congestion. If there is a greater tolerance for on-chip network congestion, the first preset number here can be larger, and if there is a smaller tolerance for on-chip network congestion, the first preset number here can be smaller. Here, each output port of each routing node can be recorded through a register. Within the first preset time, the number of times corresponding to the output port can be counted within a sliding window of a certain period, and there is no limitation on the specific statistical method.

[0045] Step 205: When congestion occurs at the first output port of the first routing node, the back pressure signal generator obtains the main data input port corresponding to the first output port from the link flow table of the first routing node.

[0046] Step 205 may refer to the aforementioned step 101, and will not be described again here to avoid repetition.

[0047] Step 206: Add a preset number of connections in the link between adjacent routing nodes to form a back pressure path.

[0048] In the link between the routing node and its adjacent routing node, a preset number of connections are additionally added for transmitting the back pressure signal, and the preset number of bits here needs to be greater than or equal to the bit width of the back pressure signal. One way to form a back pressure path here may be: in the entire on-chip network, the links between all routing nodes and their adjacent routing nodes will increase the number of connections by a preset number of bits. In the case where a certain output port of a routing node is not congested, the back pressure path of the routing node at the output port does not need to transmit anything. Once the output port of the routing node is congested, the back pressure path of the routing node at the output port is used to transmit the back pressure signal. There is no limitation on other ways to form a back pressure path.

[0049] The present application adds a preset number of connections in the link between adjacent routing nodes to form a backpressure path, does not add additional control paths, does not introduce new routing sub-networks, and has little impact on area, power consumption, and routing resources.

[0050] Optionally, the preset number of bits here is equal to the bit width of the back pressure signal; at the same time, the bit width of the back pressure signal is less than or equal to 3 bits. Specifically, the bandwidth of the link between adjacent routing nodes is usually in the hundreds or even hundreds of bits (such as 256 bits). On this basis, only less than or equal to 3 bits of connection are added to form a back pressure path, which has little impact on the area, power consumption and routing resources. It can quickly feedback the congestion phenomenon to the source of data packet transmission with low latency, solving the lag of using software flow control to adjust the congestion phenomenon, or through the instant congestion perception hardware response of the back pressure path, it can quickly transmit the back pressure signal, which can be used as the preferred solution for instant congestion flow control of large-scale on-chip networks. For example, the bit width of the back pressure signal can be 1 bit, then a 1-bit connection is added to the link between adjacent routing nodes to form a back pressure path, which can quickly feed back the congestion phenomenon to the data packet source with a low latency of 1 hop / cycle, solving the lag of using software flow control to regulate congestion phenomena, or in other words, through the instant congestion-aware hardware response of the back pressure path, the back pressure signal can be transmitted at a speed of 1 hop / cycle, which can serve as the preferred solution for instant congestion flow control of large-scale on-chip networks; for another example, the bit width of the back pressure signal can be 2 bits, then a 2-bit connection is added to the link between adjacent routing nodes to form a back pressure path; for another example, the bit width of the back pressure signal can be 3 bits, then a 3-bit connection is added to the link between adjacent routing nodes to form a back pressure path.

[0051] For example, the bandwidth of the link between adjacent routing nodes is 256 bits. If 1 bit of connection is added, the bandwidth becomes 257 bits. Compared with 256 bits, the 1 bit of connection added in this application for transmitting the back pressure signal accounts for a very small proportion, so the impact on area, power consumption and routing resources is very small. Here, the bandwidth of the link between adjacent routing nodes is 256 bits, which is mainly used for data transmission between adjacent routing nodes.

[0052] Step 207: The back pressure signal generator generates the back pressure signal.

[0053] The back pressure signal generator may generate the back pressure signal only once, and then directly send the back pressure signal when congestion occurs at the first output port of a first routing node in the on-chip network, without generating the back pressure signal again. Alternatively, the back pressure signal generator may generate the back pressure signal when congestion occurs at the first output port of each first routing node in the on-chip network, and there is no specific limitation on this.

[0054] Step 208: Send the back pressure signal from the primary input port through the back pressure path to a second routing node adjacent to the first routing node.

[0055] This step may refer to the aforementioned step 102, the main difference being that the back pressure signal is transmitted through a specially established back pressure path, the back pressure signal is transmitted faster, and thus the congestion control speed is faster.

[0056] Step 209: Based on the link flow tables of the second routing node and the remaining routing nodes, the back pressure signal is sent to the corresponding source routing nodes in sequence through the back pressure path.

[0057] This step may refer to the aforementioned step 103, the main difference being that the back pressure signal is transmitted through a specially established back pressure path, the back pressure signal is transmitted faster, and thus the congestion control speed is faster.

[0058] Step 210: Obtain, from the link flow table of the source routing node, the data main input port corresponding to the output port of the source routing node that receives the back pressure signal.

[0059] A link flow table is also established in advance for the source routing node. From the link flow table of the source routing node, the main data input port corresponding to the output port of the source routing node that receives the back pressure signal can be queried, indicating that one of the main reasons for congestion at the first output port of the aforementioned first routing node is that the main data input port corresponding to the output port of the source routing node that receives the back pressure signal inputs more data to the source routing node.

[0060] Step 211: Based on the output port of the source routing node that receives the back pressure signal and the number of back pressure signals received within a second preset time period, a current limiter is used to limit the packet sending behavior of the device connected to the main data input port corresponding to the output port of the source routing node that receives the back pressure signal.

[0061] The device connected to the main data input port corresponding to the output port of the source routing node that receives the back pressure signal is a main packet sending device where the first output port of the aforementioned first routing node is congested.

[0062] The second preset duration here is determined based on the tolerance for congestion of the on-chip network, etc., and there is no limit on the size of the second preset duration. If the same output port of the same source routing node receives the back pressure signal, and the number of back pressure signals received within the second preset duration is relatively large, it means that the packet sending behavior of the device connected to the data main input port corresponding to the output port of the source routing node receiving the back pressure signal has caused congestion in the first output ports of multiple first routing nodes, and it is necessary to limit the packet sending behavior of the device with greater force; if the same output port of the same source routing node receives the back pressure signal, and the number of back pressure signals received within the second preset duration is relatively small, it means that the packet sending behavior of the device connected to the data main input port corresponding to the output port of the source routing node receiving the back pressure signal has caused congestion in the first output ports of fewer first routing nodes, and the packet sending behavior of the device can be limited with less force.

[0063] A current limiter is used to limit the packet sending behavior of the device connected to the main data input port corresponding to the output port of the source routing node. The current limiter as hardware can quickly limit the current and control congestion faster. A current limiting algorithm can be used here to limit the current, for example, a token bucket current limiting method or throttling according to probability can be used.

[0064] It should be noted that, for the sake of simplicity, the method embodiments are described as a series of action combinations, but those skilled in the art should be aware that the embodiments of the present invention are not limited by the order of the actions described, because according to the embodiments of the present invention, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present invention.

[0065] The present application is further explained below with reference to specific embodiments.

[0066] Reference Figure 4,The bandwidth of the link between adjacent routing nodes is 256 bits, and a 1-bit connection is added to the link between adjacent routing nodes to form a back pressure path. Figure 4 In the figure, the lines between adjacent routing nodes are links between adjacent routing nodes. The left-right direction is a row, and the up-down direction is a column. Here, the rows and columns are defined by the existence of links between adjacent routing nodes. The back pressure signal generator generates a back pressure signal, and the bit width of the back pressure signal is 1 bit. Figure 4 In the figure, the output port connected to the device of the cross routing node at the intersection of the third row and the third column from left to right and from top to bottom is congested. The back pressure signal generator queries the link flow table of the cross routing node where the congestion occurs, and finds that in the period before the congestion occurs, the data transmitted in the output port connected to the device and the routing node in the cross routing node where the congestion occurs mainly enters the cross routing node where the congestion occurs from the west input port of the cross routing node where the congestion occurs. Then, the back pressure signal generator sends the back pressure signal from the west input port of the cross routing node where the congestion occurs, and the cross routing node adjacent to the cross routing node where the congestion occurs in the west direction receives the back pressure signal (i.e. Figure 4 The cross-routing node at the intersection of the third row and second column from left to right and from top to bottom receives the back pressure signal), specifically, Figure 4 The east output port of the cross-routing node at the intersection of the third row and the second column from left to right and from top to bottom received the back pressure signal. Then the back pressure signal generator queries the link flow table of the cross-routing node at the intersection of the third row and the second column from left to right and from top to bottom, and finds that in the period before the congestion occurred, the data transmitted in the east output port of the cross-routing node at the intersection of the third row and the second column from left to right and from top to bottom mainly entered the cross-routing node from the west input port and the north input port of the cross-routing node. Then, the back pressure signal generator sends the back pressure signal from the west input port and the north input port of the cross-routing node to the cross-routing node adjacent to the cross-routing node in the west direction (i.e. Figure 4 The cross-routing node at the intersection of the third row and the first column from left to right and from top to bottom) and the cross-routing node adjacent to the cross-routing node in the north direction (i.e. Figure 4 The cross-routing nodes at the intersection of the second row and the second column from left to right and from top to bottom in the figure all receive the back pressure signal. Figure 4 In the figure, the transmission path of the back pressure signal is shown by the thicker arrow. So far, two source routing nodes have been found for the congestion that occurs at the device of the cross routing node at the intersection of the third row and the third column from left to right and from top to bottom and the output port connected to the routing node. Among them, Figure 4 The east output port of the cross routing node at the intersection of the third row and the first column from left to right and from top to bottom receives the back pressure signal. Figure 4The south output port of the cross routing node at the intersection of the second row and the second column from left to right and from top to bottom receives the back pressure signal.

[0067] By querying the link flow tables of the two source routing nodes, it can be concluded that in the period before the congestion occurred, Figure 4 The data transmitted in the east output port of the source routing node at the intersection of the third row and the first column from left to right and from top to bottom mainly enter the source routing node from the input port connected to the device of the source routing node and the routing node; in the period before the congestion occurs, Figure 4 The data transmitted in the south output port of the cross routing node at the intersection of the second row and the second column from left to right and from top to bottom mainly enters the source routing node from the input port connected to the device of the source routing node and the routing node. Figure 5 , it is shown that the current limiting is performed at any one of the two source routing nodes. The current limiting at the other source routing node is similar. Specifically, the source routing node collects the back pressure signal from each output port. At the current moment, the source routing node mainly receives the back pressure signal for the aforementioned Figure 4 In the figure, the congestion back pressure signal of the device of the cross routing node at the intersection of the third row and the third column from left to right and from top to bottom and the output port connected to the routing node. If the device port corresponding to the output port of the source routing node that receives the back pressure signal only receives one back pressure signal, one token is added to the token bucket every cycle. If three back pressure signals are received, one token is added to the token bucket every three cycles. When the number of tokens in the token bucket is greater than 5, the output port of the flow limiter control device is allowed to send one data packet outward. When the back pressure state disappears, the output port of the device is not restricted from sending packets outward, and the token count in the token bucket is cleared.

[0068] It should be noted that Figure 4 The straight-through routing node in the path is just a pure beat routing node in the path, so the back pressure signal is transmitted directly in the back pressure path without being turned or extended.

[0069] In the above embodiments, first, through the establishment of the back pressure path and the rapid response of the hardware such as the back pressure signal generator, the back pressure path, and the current limiter, the congestion phenomenon can be quickly fed back to the data packet source with a low delay of 1 hop / cycle, which solves the lag of using software to adjust the congestion phenomenon; second, a distributed back pressure network is formed through the link flow table of each routing node, which can flexibly handle complex congestion perception scenarios with multiple congestion phenomena and multiple congestion sources; third, by establishing the back pressure path in advance, only 1 bit of back pressure signal is transmitted in the on-chip network, which greatly reduces the additional overhead of adding the back pressure control mechanism. At the same time, a global back pressure network is constructed through the link flow table, which can flexibly handle complex congestion perception scenarios with multiple congestion phenomena and multiple congestion sources, and can adapt to multiple topologies; the back pressure path generates an immediate congestion perception hardware response, which can transmit the back pressure signal at a speed of 1 hop / cycle, and can be used as a solution for large-scale on-chip network instant congestion flow control; the token bucket algorithm is used to limit the rate of the bus on the data packet according to the back pressure requirements in different scenarios.

[0070] Reference Figure 6 , Figure 6 The structural block diagram of an embodiment of a congestion control device of the present invention is shown, the device is applied to a network on chip, the network on chip includes: a back pressure signal generator and a plurality of routing nodes; the routing nodes include: a plurality of output ports and a plurality of input ports, and the above-mentioned related records can be referred to here. In order to avoid repetition, it will not be repeated here. The congestion control device includes: The data main input port acquisition module 301 is used for, when the first output port of the first routing node is congested, the back pressure signal generator acquires the data main input port corresponding to the first output port from the link flow table of the first routing node; A first sending module 302, configured to send a back pressure signal from the primary input port to a second routing node adjacent to the first routing node; A second sending module 303 is used to send the back pressure signal to the corresponding source routing node in sequence based on the link flow table of the second routing node and the remaining routing nodes; The current limiting module 304 is used to limit the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal based on the back pressure signal.

[0071] Optionally, the device further comprises: A times statistics module, used for counting, for each output port of each routing node, the times that the data corresponding to the output port is input from each input port within a first preset time length; The link flow table establishment module is used to establish a link flow table of the routing node based on the number of times of each input port for each output port of each routing node.

[0072] Optionally, the link flow table establishing module includes: A data main input port determination submodule is used to determine, for each output port of each routing node, an input port whose number of times corresponding to the output port is greater than or equal to the first preset number within the first preset time length as a data main input port corresponding to the output port; The link flow table establishment submodule is used to store each of the output ports and the corresponding data main input ports in the link flow table of the routing node for each of the routing nodes.

[0073] Optionally, the device further comprises: A back pressure path forming module, used for adding a preset number of connections in the link between adjacent routing nodes to form a back pressure path; The first sending module includes: A first sending submodule, configured to send a back pressure signal from the primary input port to a second routing node adjacent to the first routing node through the back pressure path; The second sending module includes: The second sending submodule is used to send the back pressure signal to the corresponding source routing node in sequence through the back pressure path based on the link flow table of the second routing node and the remaining routing nodes.

[0074] Optionally, the preset number of bits is equal to the bit width of the back pressure signal; the bit width of the back pressure signal is less than or equal to 3 bits.

[0075] Optionally, the device further comprises: A failure count statistics module, for each output port of each routing node, wherein the back pressure signal generator counts the number of consecutive failures of the input port in applying for channel authorization to the output port; The congestion determination module is used to determine that the first output port of the first routing node is congested when the number of consecutive failures of the input port of the first routing node to apply for channel authorization for the first output port is greater than or equal to a second preset number of times.

[0076] Optionally, the device further comprises: A first acquisition module, configured to acquire, from a link flow table of the source routing node, a data main input port corresponding to an output port of the source routing node receiving the back pressure signal; The current limiting module comprises: The current limiting submodule is used to use a current limiter to limit the packet sending behavior of the device connected to the main data input port corresponding to the output port of the source routing node that receives the back pressure signal based on the number of back pressure signals received within a second preset time period by the output port of the source routing node that receives the back pressure signal.

[0077] Optionally, the device further comprises: A back pressure signal generating module is used for the back pressure signal generator to generate the back pressure signal.

[0078] It should be noted that the congestion control device can refer to the relevant aspects of the aforementioned congestion control method. Both have the same or similar beneficial effects. In order to avoid repetition, they will not be described here.

[0079] Figure 7 is a structural diagram of an electronic device provided by an embodiment of the present invention. Figure 7 The present invention also provides an electronic device, see Figure 7 , including: a processor 501, a memory 502, and a computer program 5021 stored in the memory and executable on the processor, wherein the processor implements the steps of the above-mentioned congestion control embodiments when executing the program.

[0080] The present invention also provides a readable storage medium. When the instructions in the storage medium are executed by a processor of an electronic device, the electronic device can execute the steps of each embodiment of the above-mentioned congestion control method.

[0081] The present invention also provides a computer program product, comprising instructions, which, when executed by a processor in an electronic device, enable the electronic device to execute the steps of any one of the aforementioned congestion control method embodiments.

[0082] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0083] It will be appreciated by those skilled in the art that the embodiments of the present invention may be provided as methods, devices, or computer program products. Therefore, the embodiments of the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the embodiments of the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0084] The embodiments of the present invention are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of the processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data transmission terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data transmission terminal device generate instructions for implementing the process in the flowchart. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0085] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data transmission terminal device to operate in a predictable manner, so that the instructions stored in the computer readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0086] These computer program instructions can also be loaded onto a computer or other programmable data transmission terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0087] Although the preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.

[0088] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.

[0089] The congestion control method and device, an electronic device and a storage medium provided by the present invention are introduced in detail above. Specific examples are used in this article to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as limiting the present invention.

Claims

1. A congestion control method, characterized in that: Applied to a network on chip, the network on chip includes: a back pressure signal generator and a plurality of routing nodes; the routing nodes include: a plurality of output ports and a plurality of input ports, the method includes: In the case where congestion occurs at the first output port of the first routing node, the back pressure signal generator obtains the data main input port corresponding to the first output port from the link flow table of the first routing node; Sending a back pressure signal from the primary input port to a second routing node adjacent to the first routing node; Based on the link flow tables of the second routing node and the remaining routing nodes, the back pressure signal is sent to the corresponding source routing nodes in sequence; Based on the back pressure signal, current limiting is performed on the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal.

2. The congestion control method according to claim 1, characterized in that: In the case where congestion occurs at the first output port of the first routing node, before the back pressure signal generator obtains the data main input port corresponding to the first output port from the link flow table of the first routing node, the method further includes: For each output port of each routing node, counting the number of times that data corresponding to the output port is input from each input port within a first preset time length; For each output port of each routing node, a link flow table of the routing node is established based on the number of times of each input port.

3. The congestion control method according to claim 2, characterized in that: The step of establishing a link flow table of the routing node for each output port of each routing node based on the number of times of each input port includes: For each output port of each routing node, determine the input port corresponding to the output port for a number greater than or equal to the first preset number of times within the first preset time as the main data input port corresponding to the output port; For each of the routing nodes, each of the output ports and the corresponding data main input ports are stored in the link flow table of the routing node.

4. The congestion control method according to claim 1, characterized in that: Before the back pressure signal is sent out from the primary input port and reaches a second routing node adjacent to the first routing node, the method further comprises: Adding a preset number of connections in the links between adjacent routing nodes to form a back pressure path; The step of sending the back pressure signal from the primary input port to a second routing node adjacent to the first routing node comprises: Sending a back pressure signal from the primary input port to a second routing node adjacent to the first routing node through the back pressure path; The step of sending the back pressure signal to the corresponding source routing node in sequence based on the link flow table of the second routing node and the remaining routing nodes includes: Based on the link flow tables of the second routing node and the remaining routing nodes, the back pressure signal is sequentially sent to the corresponding source routing nodes through the back pressure path.

5. The congestion control method according to claim 4, characterized in that: The preset number of bits is equal to the bit width of the back pressure signal; and the bit width of the back pressure signal is less than or equal to 3 bits.

6. The congestion control method according to any one of claims 1 to 5, characterized in that: In the case where congestion occurs at the first output port of the first routing node, before the back pressure signal generator obtains the data main input port corresponding to the first output port from the link flow table of the first routing node, the method further includes: For each output port of each routing node, the back pressure signal generator counts the number of consecutive failures of the input port in applying for channel authorization for the output port; When the number of consecutive failures of the input port of the first routing node in applying for channel authorization for the first output port is greater than or equal to a second preset number, the backpressure signal generator determines that congestion occurs in the first output port of the first routing node.

7. The congestion control method according to any one of claims 1 to 5, characterized in that: Before limiting the flow of packet sending behavior of a device corresponding to the output port of the source routing node that receives the back pressure signal based on the back pressure signal, the method further includes: Acquire, from the link flow table of the source routing node, a data main input port corresponding to the output port of the source routing node receiving the back pressure signal; The limiting the flow of the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal based on the back pressure signal includes: Based on the output port of the source routing node that receives the back pressure signal and the number of back pressure signals received within a second preset time period, a current limiter is used to limit the packet sending behavior of the device connected to the main data input port corresponding to the output port of the source routing node that receives the back pressure signal.

8. The congestion control method according to any one of claims 1 to 5, characterized in that: Before the back pressure signal is sent out from the primary input port and reaches a second routing node adjacent to the first routing node, the method further comprises: The back pressure signal generator generates the back pressure signal.

9. A congestion control device, characterized in that: Applied to a network on chip, the network on chip includes: a back pressure signal generator and a plurality of routing nodes; the routing nodes include: a plurality of output ports and a plurality of input ports, the device includes: A data main input port acquisition module, configured to, when congestion occurs at the first output port of the first routing node, enable the back pressure signal generator to acquire the data main input port corresponding to the first output port from the link flow table of the first routing node; A first sending module, configured to send a back pressure signal from the primary input port to a second routing node adjacent to the first routing node; A second sending module, configured to send the back pressure signal to the corresponding source routing node in sequence based on the link flow table of the second routing node and the remaining routing nodes; The current limiting module is used to limit the packet sending behavior of the device corresponding to the output port of the source routing node that receives the back pressure signal based on the back pressure signal.

10. An electronic device, characterized in that: include: A processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor implements the congestion control method according to any one of claims 1 to 8 when executing the program.

11. A readable storage medium, characterized in that: When the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the congestion control method according to any one of claims 1 to 8.

12. A computer program product, characterized in that The invention comprises instructions, which, when executed by a processor in an electronic device, enable the electronic device to execute the congestion control method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Traffic control method and switching device

    CN108243116A

  • Queue congestion control method, device, equipment and storage medium

    CN112054964A

  • PFC deadlock detection method and device, electronic equipment and storage medium

    CN117614860A

  • Method and system for rapidly transmitting ECN congestion information

    CN119011476A

  • Port flow control method

    CN1909508A

Cited By

  • Congestion analysis method and device, electronic equipment and readable storage medium

    CN120512400A

  • Chip control method and chip

    CN122093319A