Data packet merging method and network-on-chip

By merging adjacent data packets in the on-chip network and processing them using hardware circuitry, the bandwidth waste caused by unaligned transmission is solved, thereby improving transmission efficiency and bandwidth utilization.

CN120915740APending Publication Date: 2025-11-07XIAN ZHI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510967164.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-14
Publication Date
2025-11-07

AI Technical Summary

Technical Problem

In the prior art, the transmission of unaligned data packets in on-chip networks leads to bandwidth waste, and existing merging methods either prolong the processing cycle or fail to effectively reduce the number of data packets.

Method used

By receiving multiple data packets within a preset time, determining the address interval difference between adjacent data packets, merging data packets that meet the conditions, and using hardware circuitry to merge and split them, removing padding data, and forming the target data packet for transmission.

Benefits of technology

It improves bandwidth utilization, reduces packet merging waiting time, avoids bandwidth waste caused by misaligned transmission, and improves transmission efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120915740A_ABST
    Figure CN120915740A_ABST
Patent Text Reader

Abstract

The invention provides a data packet merging method and a network-on-chip. The method comprises the following steps: receiving a plurality of data packets; judging whether the command information is greater than or equal to two or not, and if the command information is greater than or equal to two, judging whether the data packets corresponding to the plurality of pieces of command information have the condition that the interval difference between the end address of the adjacent first data packet and the initial address of the adjacent second data packet is less than or equal to a preset value or not; if yes, zero padding data of the first data packet and the second data packet are removed, first command information corresponding to the first data packet and second command information corresponding to the second data packet are combined, and first data information corresponding to the first command information and second data information corresponding to the second command information are combined; forming merging command information and merging data information; and splitting the merged data information and the merged command information to form a plurality of target data packets, and sending the plurality of target data packets to a target node. The method can improve the transmission efficiency of the network-on-chip.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data packet merging, in particular to a data packet merging method and a network on chip. BACKGROUND

[0002] In a network on chip (NoC), the merging technology of data packets is a key means to improve network performance, and the core is to optimize transmission efficiency by integrating small data packets. In the prior art, the merging method based on time window merges the arriving data packets by setting a fixed time window, which is simple to implement, but the size of the time window needs to be balanced between bandwidth utilization and transmission delay. If the size is too large, it will easily lead to delay-sensitive data transmission lag, and if the size is too small, the merging efficiency will be insufficient. The merging method based on the number of data packets triggers merging with a preset number threshold, which can adjust the timing according to the arrival of data packets, but the threshold setting needs to consider the waiting time and the merging effect. If the threshold is too high, the processing cycle will be prolonged, and if the threshold is too low, it will be difficult to effectively reduce the number of data packets.

[0003] When the existing host sends a read-write request, if the start address of the read-write request is 0x00000004, the data amount transmitted is 72 bytes, and the data capacity of each data packet is 64 bytes, the read-write request is a non-aligned transmission. At this time, when the host sends the read-write request to the network on chip for processing, the network on chip splits the read-write request into two data packets. The start address of the first data packet is 0x00000004, and the data amount transmitted is 64 bytes. The start address of the second data packet is 0x00000044, and the remaining 8 bytes of data are transmitted. After the two data packets are split, they will be transmitted to the next node. The next node will convert the data packets into corresponding burst operations, which will cause a waste of bandwidth. For example, the node will convert the data packets into fixed 64-byte read-write operations, and the invalid part will be filled with zero data. The first data packet will be split into two burst transmission data packets at the next node. The start address of the first burst transmission data packet is 0x00000000, and the data amount transmitted is 64 bytes. The start address of the second burst transmission data packet is 0x00000040, and the data amount transmitted is also 64 bytes. The second data packet transmitted by the previous node will also be converted into a third burst transmission data packet at the node. The start address of the third burst transmission data packet is 0x00000040, and the data amount transmitted is also 64 bytes. The data transmitted by the second data packet and the data transmitted by the third data packet are repeated, resulting in a waste of bandwidth.

[0004] The prior eMMC read-write control method comprises the following steps: receiving a data read-write command request sent by a host end, and sending feedback information to the host end; receiving a next read-write command request sent by the host end, judging whether the address contained in the read-write command request and the address contained in a previous read-write command request are continuous, if yes, merging the read-write command request and the previous read-write command request to obtain a command request group, and sending feedback information to the host end; and if not, sending a read command request or a read command request group read-write command request before the read-write command request to an eMMC particle. In the method, after receiving a read-write command request each time, the continuity of the address is judged by the software processing of the driver, and then the read-write command request is merged, so that the processing time is relatively long. Moreover, the method cannot solve the problem of bandwidth waste caused by non-aligned data packets in the network-on-chip. SUMMARY

[0005] The first object of the present application is to provide a data packet merging method for reducing bandwidth waste of data packets.

[0006] The second object of the present application is to apply the network-on-chip of the data packet merging method.

[0007] To achieve the first object of the present application, the data packet merging method comprises the following steps: receiving a plurality of data packets within a preset time, wherein each data packet comprises a command information and a data information; judging whether the command information is greater than or equal to two, and if yes, judging whether there exists a case that the interval difference between the end address of a first data packet and the start address of a second data packet of the data packets corresponding to the command information is less than or equal to a preset value; if yes, removing the zero padding data in the first data packet and the second data packet, merging the first command information corresponding to the first data packet and the second command information corresponding to the second data packet, merging the first data information corresponding to the first command information and the second data information corresponding to the second command information, forming a merged command information and a merged data information, splitting the merged data information and the merged command information according to a target data packet format of a target node, and forming a plurality of target data packets, and sending the plurality of target data packets to the target node.

[0008] As can be seen from the above scheme, the network-on-chip can perform a merging operation on the data packets after receiving the data packets to increase the utilization rate of bandwidth. When the data packets are merged, it is judged whether there exists a case that the interval difference between the start address of a first data packet and the end address of a second data packet is less than or equal to a preset value, so that the data packets are merged, thereby reducing the waiting time of data packet merging. When the data packets are merged, the zero padding data of the data packets is removed and is sent after splitting, so that the situation that two data packets are split into three data packets when transmitted at the second node is avoided, the transmission efficiency is improved, and bandwidth waste is avoided. Moreover, the method uses a hardware circuit to perform merging when the data packets are merged, thereby improving the transmission efficiency.

[0009] In a further aspect, the preset value is one; and the step of judging whether the plurality of command information exists a case that the ending address of the first command information and the starting address of the second command information are adjacent and the interval difference is less than or equal to the preset value comprises: judging whether the plurality of command information exists a case that the starting address of the first command information and the ending address of the second command information are adjacent.

[0010] Therefore, when the network load is light, the preset value is set to one, the merging condition is changed to be more stringent, and the complexity of subsequent splitting is reduced.

[0011] In a further aspect, after receiving the plurality of data packets, the following steps are further performed: storing the command information in the command cache queue and buffering the data information in the data cache queue; and the step of judging whether the command information is greater than or equal to two comprises: judging whether the command information in the command cache queue is greater than or equal to two.

[0012] Therefore, by parallelly setting the data cache queue and the command cache queue and separately monitoring the command cache queue, different network environments and data transmission requirements can be better adapted to, and higher adaptability and flexibility are achieved.

[0013] In a further aspect, after receiving the plurality of data packets, the following steps are further performed: judging whether the command information and the data information of the data packet are in parallel format; if the command information and the data information of the data packet are in parallel format, storing the command information in the command cache queue and buffering the data information in the data cache queue; and if the command information and the data information of the data packet are not in parallel format, converting the data packet into a data packet in parallel format.

[0014] Therefore, by parallelly setting the command information and the data information, the data packet merging and splitting are more convenient, and higher flexibility is achieved.

[0015] In a further aspect, before receiving the plurality of data packets, the following steps are further performed: receiving read-write data information sent by a host, splitting the read-write data information according to the format of a receiving node to obtain a plurality of transmission data packets, and the transmission data packet comprising transmission command information and transmission data information.

[0016] Therefore, the network-on-chip can also receive read-write data information sent by a host, split the read-write data information according to the format of a receiving node to obtain a transmission data packet, and transmit the transmission data packet to a next node.

[0017] In a further aspect, the transmission data packet is provided with a plurality of transmission data units; after the read-write data information is split according to the format of the receiving node, the read-write data information is filled into the transmission data units; when the read-write data information is filled, it is determined whether there is a remaining space in the transmission data units; if yes, the remaining space is filled with transmission zero data.

[0018] Therefore, filling the first zero data can ensure the integrity of the data packet transmission and the effectiveness of the data frame check.

[0019] In a further aspect, the transmission data packet includes a plurality of transmission data groups, the width of the transmission data group is the transmission bit width of the transmission data packet; one transmission data group includes a plurality of transmission data units; and the transmission data packet includes a plurality of flow control units.

[0020] In a further aspect, one flow control unit includes a handshake receiving signal, a handshake sending signal, a transmission data packet header signal and a transmission data packet tail signal; and one transmission data group corresponds to one flow control unit.

[0021] Therefore, by setting the flow control unit, the header and tail of the data packet are identified, and it is confirmed whether the receiving node has received the data packet.

[0022] In a further aspect, the step of determining whether the data packets corresponding to the plurality of command information exist a case that the interval difference between the end address of the first data packet and the start address of the second data packet is less than or equal to the preset value includes: using a subtracter and a comparator to determine whether the data packets corresponding to the plurality of command information exist a case that the interval difference between the end address of the first data packet and the start address of the second data packet is less than or equal to the preset value.

[0023] Therefore, the subtracter and the comparator are hardware circuits, and the transmission efficiency is improved by determining through the hardware circuit.

[0024] In a further aspect, the network on chip includes a hardware circuit, and the hardware circuit implements the data packet merging method. BRIEF DESCRIPTION OF DRAWINGS

[0025] Figure 1 is a system structure block diagram of an embodiment of the network on chip of the present application.

[0026] Figure 2 is a flow chart of an embodiment of the data packet merging method of the present application.

[0027] Figure 3 is a structure schematic diagram of a data unit of an embodiment of the data packet merging method of the present application.

[0028] Figure 4is a structural diagram of a data group of an embodiment of the data packet merging method of the application.

[0029] Figure 5 is a structural diagram of a data packet in serial format of an embodiment of the data packet merging method of the application.

[0030] Figure 6 is a structural diagram of a data packet in parallel format of an embodiment of the data packet merging method of the application.

[0031] Figure 7 is a structural diagram of a data cache queue and a command cache queue of an embodiment of the data packet merging method of the application.

[0032] The application is further described below in combination with the drawings and embodiments. DETAILED DESCRIPTION

[0033] In the data packet merging method provided by the application, after receiving a data packet, the data packet is merged by setting a merging condition, a new target data packet is formed according to the format of the data packet, and the target data packet is sent to a target node. When the data packet is merged, the zero padding data of the data packet is removed, and the data packet is sent after splitting, so as to avoid the case that two data packets are split into three data packets after the second transmission when there is misaligned transmission, improve the transmission efficiency, and avoid bandwidth waste.

[0034] Network-on-chip embodiment: Referring to Figure 1 , the network-on-chip 12 can send data of the sending node 11, and send the data information to the target node 13 after processing. The network-on-chip includes a hardware circuit, and the hardware circuit can implement the data packet merging method of the data packet merging method embodiment. The hardware circuit includes at least one of a subtracter, a comparator, a state machine, and a cache controller. The sending node 11 can be a plurality of nodes, and the node can be a host or a previous router. If the node is a host, the network-on-chip converts the read-write data information sent by the host into a data packet and sends the data packet to the receiving node 13. If the sending node 11 is a router, the receiving data packet is merged after judging whether the data packet meets the merging condition, and is transmitted according to the format of the receiving node 13. The receiving node 13 can be a target host or a next router. Each router sends the data packet to the next node according to the routing information in the command information of the data packet. In order to reduce conflicts and improve throughput, the router is provided with a virtual channel, and the data packet is distributed in the available virtual channel. When transmitting data, the network-on-chip adopts Credit or Ack / Nack-based flow control to ensure that the resources in the network are reasonably allocated, and to avoid congestion and deadlock.

[0035] Data packet merging method embodiment: The data packet merging method of the application is executed by the network on chip in the above embodiment. The host can send read-write data information to the network on chip, and the network on chip transmits the read-write data information. The network on chip receives the read-write data information sent by the host, splits the read-write data information according to the format of the receiving node, and obtains a plurality of transmission data packets. The transmission data packet includes transmission command information and transmission data information. The transmission data packet can be transmitted on the network on chip. The network on chip can fill the read-write data information into the transmission data unit. When the read-write data information filling is completed, it is judged whether there is remaining space in the transmission data unit. If yes, the transmission zero padding data is filled into the remaining space. The filled transmission zero padding data is invalid data.

[0036] The transmission data packet is provided with a plurality of transmission data units, and the transmission data packet includes a plurality of transmission data groups. The width of the transmission data group is the transmission bit width of the transmission data packet. One transmission data group includes a plurality of transmission data units. The transmission data packet includes a plurality of flow control units. One flow control unit includes a handshake receiving signal, a handshake sending signal, a packet header signal and a packet tail signal. One transmission data group corresponds to one flow control unit. That is, the data packet is provided with a plurality of data units, and the data packet includes a plurality of data groups.

[0037] Referring to Figure 3 The data unit of the embodiment has a plurality of formats, and the network on chip can confirm the data unit of the data packet according to the transmission bit width of the data packet. The data information includes entity data information and gating information. Specifically, one data unit has one gating information and one entity data information. In the embodiment, one format of the data unit is 4-bit gating information and 4-byte entity data information, another format is 8-bit gating information and 8-byte entity data information, and another format is 16-bit gating information and 16-byte entity data information. Of course, the format of the data unit is not limited to these formats, and can be expanded according to the actual situation. When the gating information is a binary number "1", it means that the entity data information corresponding to the gating information is valid. When the gating information is a binary number "0", it means that the entity data information corresponding to the gating information is invalid. The zero padding data can be removed through the gating information.

[0038] Referring to Figure 4 The data packet includes a plurality of data groups, one data group includes a plurality of data units, and the width of the data group is the transmission bit width of the transmission data packet. One data group has a group of flow control units, one handshake receiving signal, one handshake sending signal, one packet header signal and one packet tail signal. Among them, the handshake receiving signal, the handshake sending signal, the packet header signal and the packet tail signal are high level effective.

[0039] Referring to Figure 5The data packet includes a command information and a data information, the command information includes at least one of data length, source identification, destination identification and destination address, the data packet includes a plurality of data groups and the command information, the data packet includes a plurality of flow control units, and one data group corresponds to one flow control unit. Figure 5 In the data packet, the command information and the data information are in series. Figure 6 Figure 6 In the data packet, the data group information and the command information are in parallel.

[0040] In the data packet, the data group information and the command information are in parallel. Figure 2 After a node of the network on chip transmits the data packet to the network on chip, the network on chip performs step S1, receives the data packet. A preset time can be set to receive the data packet to avoid delay of data. After receiving a plurality of data packets, the following steps are further performed: judging whether the command information and the data information of the data packet are in parallel format; if the command information and the data information of the data packet are in parallel format, storing the command information in a command cache queue and caching the data information in a data cache queue; if the command information and the data information of the data packet are not in parallel format, converting the data packet into a data packet in parallel format.

[0041] After receiving the data packet, the network on chip caches the data packet. The network on chip stores the command information in a command cache queue and caches the data information in a data cache queue. However, since the command information and the data information of some data packets are in series, the network on chip judges whether the command information and the data information of the data packet are in parallel format before caching. If the command information and the data information of the data packet are in parallel format, the command information is stored in a command cache queue and the data information is cached in a data cache queue. If the command information and the data information of the data packet are not in parallel format, the data packet is converted into a data packet in parallel format, and then the command information is stored in a command cache queue and the data information is cached in a data cache queue.

[0042] ​After the data packets are buffered, step S2 is performed to determine whether the command information is greater than or equal to two, wherein it is determined whether the command information of the command buffer queue is greater than or equal to two. Only two or more data packets can be merged. If the command information is greater than or equal to two, step S3 is performed to determine whether the interval difference between the end address of the first data packet and the start address of the second data packet corresponding to the command information is less than or equal to a preset value. The interval value between the end address of the first data packet and the start address of the second data packet is determined using a subtracter and a comparator, wherein the subtracter subtracts the end address of the first data packet from the start address of the second data packet to obtain the interval difference. Then, the comparator compares the interval difference with the preset value to determine whether the interval difference is less than or equal to the preset value. The determination is performed by the subtracter and the comparator, i.e., using a hardware circuit to improve transmission efficiency.

[0043] The preset value can be set to one, and in step S3, it is determined whether the interval difference between the end address of the first data packet and the start address of the second data packet corresponding to the command information is less than or equal to the preset value, i.e., whether the end address of the first data packet and the start address of the second data packet corresponding to the command information are adjacent.

[0044] If the interval difference between the end address of the first data packet and the start address of the second data packet is less than or equal to the preset value, step S4 is performed to remove the zero padding data of the first data packet and the second data packet, merge the first command information corresponding to the first data packet and the second command information corresponding to the second data packet, and simultaneously merge the first data information corresponding to the first command information and the second data information corresponding to the second command information to form merged command information and merged data information.

[0045] When the on-chip network is merged, the hardware circuit is used for merging. The hardware circuit can be at least one of a state machine and a buffer controller, and the processor does not need to intervene, thereby improving transmission efficiency.

[0046] After the merged command information and the merged data information are formed, step S5 is performed to split the merged command information and the merged data information to obtain a plurality of target data packets, and the plurality of target data packets are sent to a target node.

[0047] When the target node receives the target data packet, the target node identifies whether the data packet is for the target node itself through the command information of the target data packet, and if so, processes the target data packet. At this time, the target node sends response information to the node that sends the target data packet to ensure correct reception of the data.

[0048] The combined command information and the combined data information are split according to the format of the target node when the combined data packet needs to be transmitted, so that multiple target data packets are obtained, the situation that two data packets are split into three data packets for transmission after being transmitted at the second node when there is misalignment transmission can be avoided, the transmission efficiency is improved, and bandwidth waste is avoided.

[0049] The above are only the preferred embodiments of the present application, but the design concept of the application is not limited thereto, and more other equivalent embodiments can be included without departing from the concept of the application, and various obvious changes, re-adjustments and substitutions can be made by those skilled in the art without departing from the protection scope of the application.

Claims

1. A data packet merging method, comprising: receiving a plurality of data packets, each of the data packets comprising a command information and a data information; determining whether the command information is greater than or equal to two; if the command information is greater than or equal to two, determining whether there is a case that a gap between an end address of a first data packet and a start address of a second data packet corresponding to the plurality of command information is less than or equal to a preset value; if yes, removing zero padding data in the first data packet and the second data packet, merging a first command information corresponding to the first data packet with a second command information corresponding to the second data packet, and merging a first data information corresponding to the first command information with a second data information corresponding to the second command information, to form a merged command information and a merged data information; and splitting the merged data information and the merged command information according to a target data packet format of a target node, to form a plurality of target data packets, and sending the plurality of target data packets to the target node. 2.The data packet merging method of claim 1, wherein: the preset value is one; and the step of determining whether there is a case that a gap between an end address of a first command information and a start address of a second command information corresponding to the plurality of command information is less than or equal to a preset value comprises: determining whether there is a case that a start address of a first command information and an end address of a second command information corresponding to the plurality of command information are adjacent. 3.The data packet merging method of claim 1, wherein: after receiving the plurality of data packets, further performing: storing the command information in a command cache queue and caching the data information in a data cache queue; and the step of determining whether the command information is greater than or equal to two comprises: determining whether the command information in the command cache queue is greater than or equal to two. 4.The data packet merging method of claim 3, wherein: after receiving the plurality of data packets, further performing: determining whether the command information and the data information of the data packet are in a parallel format; if the command information and the data information of the data packet are in the parallel format, storing the command information in the command cache queue and caching the data information in the data cache queue; and if the command information and the data information of the data packet are not in the parallel format, converting the data packet into a data packet in the parallel format. 5.The data packet merging method of any one of claims 1 to 4, wherein: before receiving the plurality of data packets, further performing: receiving read-write data information sent by a host, and splitting the read-write data information according to a format of a receiving node to obtain a plurality of transmission data packets, each of the transmission data packets comprising a transmission command information and a transmission data information. 6.The data packet merging method of claim 5, wherein: each of the transmission data packets comprises a plurality of transmission data units; after splitting the read-write data information according to the format of the receiving node, further performing: filling the read-write data information into the transmission data units; when the filling of the read-write data information is completed, determining whether there is a remaining space in the transmission data units; and if yes, filling transmission zero padding data into the remaining space. ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ ​ 7. The data packet merging method of claim 6, wherein: the transmission data packet comprises a plurality of transmission data groups, a width of the transmission data group is a transmission bit width of the transmission data packet; one of the transmission data groups comprises a plurality of transmission data units; and the transmission data packet comprises a plurality of flow control units.

8. The data packet merging method of claim 7, wherein: one of the flow control units comprises a handshake receiving signal, a handshake sending signal, a packet header signal, and a packet tail signal; and one of the transmission data groups corresponds to one of the flow control units.

9. The data packet merging method of any one of claims 1 to 4, wherein: the step of determining whether the data packets corresponding to the command information exist in a case where an interval difference between an end address of a first data packet and a start address of a second data packet is less than or equal to a preset value comprises: using a subtracter and a comparator to determine whether the data packets corresponding to the command information exist in the case where the interval difference between the end address of the first data packet and the start address of the second data packet is less than or equal to the preset value.

10. A network-on-chip, comprising a hardware circuit, wherein the hardware circuit implements the data packet merging method of any one of claims 1 to 9. ​ ​ ​ ​ ​ ​ ​