Data transmission method based on UCIe protocol, processor, medium and product

By introducing a virtual channel mechanism at the UCIe protocol layer, the latency and low efficiency issues of the UCIe protocol when transmitting multiple independent AXI signals across chips are solved, realizing efficient point-to-point transmission of AXI data and improving the efficiency and stability of data transmission between chips.

CN121187992APending Publication Date: 2025-12-23SHANGHAI BIREN TECH CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202511278406.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-09-08
Publication Date
2025-12-23

AI Technical Summary

Technical Problem

The existing UCIe protocol suffers from data latency and low transmission efficiency when transmitting multiple independent AXI signals across chips. In particular, when there are two or more independent AXI service data mixed in the AXI channel, the sending side experiences significant delay in sending data, which affects the transmission efficiency.

Method used

The data transmission method based on the UCIe protocol is adopted. By introducing a virtual channel mechanism at the UCIe protocol layer, multiple sets of AXI data with different service attributes between the multiplexed AXI bus and the physical channel of the UCIe protocol layer are stored in the buffer area of ​​the corresponding virtual channel through multiple virtual channels. Independent flow control and credit counting operations are performed to ensure that the data of different AXI services and channels are transmitted point-to-point through independent virtual channels.

Benefits of technology

It effectively improves the efficiency of AXI data transmission between chips, avoids transmission timing disorder and delay caused by data mixing between different AXI services and channels, and improves transmission stability and efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121187992A_ABST
    Figure CN121187992A_ABST
Patent Text Reader

Abstract

The invention discloses a UCIe protocol-based data transmission method, a processor, a medium and a product. The method comprises the following steps of: storing a plurality of groups of AXI data with different service attributes of a physical channel between a multiplexing AXI bus and a UCIe protocol layer into cache regions of corresponding virtual channels through a plurality of virtual channels; wherein each virtual channel is used for storing data of one AXI channel attribute in the AXI data of one service attribute into a cache region of the corresponding virtual channel; reading data from the plurality of cache regions, and transmitting the data to a receiving side through an adaptation layer and a physical layer of the UCIe; according to the embodiment of the invention, a virtual channel mechanism is introduced into the UCIe protocol layer, so that data of different AXI services and different AXI channels are transmitted in a point-to-point manner through independent virtual channels, and the AXI data transmission efficiency between chips can be effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence chip technology, and in particular to a data transmission method, processor, medium, and product based on the UCIe protocol. Background Technology

[0002] UCIe (Universal Chiplet Interconnect Express) is a technology for connecting multiple chips within the same package. It provides high-bandwidth, low-latency, and high-energy-efficiency intra-package interconnects, enabling integration within the chip package. Transmitting AXI bus signals via UCIe is one of the main applications of UCIe today.

[0003] Currently, the relevant technology utilizes UCIe to transmit AXI bus signals between dies. The typical approach for a set of AXI service interfaces is as follows: 1. The UCIe protocol layer receives the AXI bus signal and stores all AXI channel data in a buffer; 2. Data is read from the buffer; 3. The data read from the buffer is either packaged or transmitted directly to the adapter layer without packaging. This existing solution is feasible for applications with only one set of AXI interfaces. However, if multiple sets of independent AXI signals need to be transmitted across dies, or if two or more independent AXI service data sets are mixed within an AXI channel, the current solution, which only allocates different buffers according to AXI channel type, may cause interference between the send-return logic of multiple AXI services. This results in significant delays in data transmission on the sending side, reducing transmission efficiency. Summary of the Invention

[0004] To address the problems existing in the prior art, embodiments of the present invention provide a data transmission method, processor, medium, and product based on the UCIe protocol, which can effectively improve the efficiency of AXI data transmission between chips.

[0005] In a first aspect, embodiments of the present invention provide a data transmission method based on the UCIe protocol, comprising:

[0006] Multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffer area of ​​the corresponding virtual channel through multiple virtual channels; wherein, each of the virtual channels is used to store data of one AXI channel attribute from the AXI data of one service attribute into the buffer area of ​​the corresponding virtual channel.

[0007] Data is read from the multiple buffers and transmitted to the receiving side through the adaptation layer and the physical layer.

[0008] As an improvement to the above solution, the step of storing multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer into the buffer area of ​​the corresponding virtual channel through multiple virtual channels includes:

[0009] The multiple sets of AXI data are split according to AXI channel attributes, and corresponding virtual channels are created for each type of AXI channel attribute for transmission;

[0010] Data of various AXI channel attributes are split according to business attributes, and corresponding virtual channels are created for each business attribute for transmission, so as to store data of different business attributes and different AXI channel attributes in multiple sets of AXI data into different buffers.

[0011] As an improvement to the above solution, the step of reading data from multiple buffers and transmitting it to the receiving side through an adaptation layer and a physical layer includes:

[0012] The multiple cache areas are polled and arbitrated, and two cache areas are selected in each round of arbitration;

[0013] Data is read from the two buffers determined according to the first-in-first-out rule and packaged to obtain the data packet to be transmitted in this round;

[0014] The data packet is transmitted to the receiving side through the adaptation layer and the physical layer.

[0015] As an improvement to the above scheme, the step of polling and arbitrating multiple cache areas, and deciding on two cache areas in each round of arbitration, includes:

[0016] The buffers of the read data channel, write address channel and the virtual channel corresponding to the write data channel are polled and arbitrated by the first arbitrator, and a buffer is determined in each round of arbitration;

[0017] The buffers of the virtual channels corresponding to the read address channel and the write return channel are polled and arbitrated by a second arbitrator, and one buffer is determined in each round of arbitration, so that two buffers are determined in each round of arbitration by the first arbitrator and the second arbitrator.

[0018] As an improvement to the above solution, the method further includes:

[0019] Perform independent flow control on each of the aforementioned virtual channels;

[0020] Each of the virtual channels has a buffer on both the sending and receiving sides. Data read from the buffer of one of the virtual channels on the sending side is transmitted to the buffer of the corresponding virtual channel on the receiving side.

[0021] As an improvement to the above solution, the independent flow control for each virtual channel includes:

[0022] For each of the virtual channels, at least one of the following credit counting operations is performed to update the credit value of the target side's buffer on the opposite side; wherein the target side is the sending side or the receiving side;

[0023] First credit counting operation: Reset the credit value on the target side;

[0024] Second credit counting operation: Initialize the credit value of the target side;

[0025] Third credit counting operation: When the credit value of the buffer on the other side is received, the credit value of the target side is updated to the received credit value;

[0026] Fourth credit counting operation: When data is transmitted from the buffer on the target side to the buffer on the opposite side, the credit value on the target side is reduced by a preset step size.

[0027] As an improvement to the above scheme, the priority of the first credit counting operation is higher than the priority of the second credit counting operation, the priority of the second credit counting operation is higher than the priority of the third credit counting operation, and the priority of the third credit counting operation is higher than the priority of the fourth credit counting operation.

[0028] The first credit counting operation and the second credit counting operation are executed during the corresponding buffer unreset and initialization phase; the third credit counting operation and the fourth credit counting operation are executed during the corresponding buffer data transmission phase.

[0029] As an improvement to the above solution, the method further includes:

[0030] For each of the virtual channels, a virtual channel traffic counter is set on both the sending side and the receiving side;

[0031] The virtual channel counter on the sending side is used to record the total number of data transmitted in the buffer of the sending side of the corresponding virtual channel, and the virtual channel counter on the receiving side is used to record the total number of data received in the buffer of the receiving side of the corresponding virtual channel.

[0032] As an improvement to the above scheme, the transmission of the data packet to the receiving side through the adaptation layer and the physical layer includes:

[0033] The data packet is converted into a Flit data packet in a preset Flit format; wherein, the setting field of the Flit data packet is written into the credit value of the buffer of one of the virtual channels;

[0034] The Flit data packet is transmitted to the receiving side through the adaptation layer and the physical layer.

[0035] As an improvement to the above scheme, the setting field is located in the third data block of the Flit data packet: the setting field is used to indicate the type information of the setting field, the credit value of the corresponding virtual channel's buffer, and the virtual channel to which the information content of the setting field belongs.

[0036] As an improvement to the above scheme, the credit values ​​of the buffers of each virtual channel are cyclically inserted into the setting field of the Flit data packets transmitted in each round according to a set order.

[0037] As an improvement to the above solution, the method further includes:

[0038] The receiving side parses and unpacks the received Flit data packets to obtain the data transmitted in several buffers on the sending side;

[0039] The data transmitted by the several buffers on the sending side are respectively stored in the buffers of the corresponding virtual channels on the receiving side.

[0040] In a second aspect, embodiments of the present invention provide a processor, including: a first chip and a second chip, wherein the first chip and the second chip are interconnected via the UCIe protocol;

[0041] The UCIe protocol layer of the first chip is configured as follows:

[0042] Multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffer area of ​​the corresponding virtual channel through multiple virtual channels; wherein, each of the virtual channels is used to store data of one AXI channel attribute from the AXI data of one service attribute into the buffer area of ​​the corresponding virtual channel.

[0043] Data is read from the multiple buffers and transmitted to the second core through the adaptation layer and the physical layer.

[0044] Thirdly, embodiments of the present invention provide a non-volatile computer-readable storage medium storing a computer program, wherein the computer program, when running, controls the device where the non-volatile computer-readable storage medium is located to execute the data transmission method based on the UCIe protocol as described in any one of the first aspects.

[0045] Fourthly, embodiments of the present invention provide a computer program product, including a computer program / instruction, which, when executed by a processor, implements the data transmission method based on the UCIe protocol as described in any one of the first aspects.

[0046] Compared to existing technologies, this invention provides a data transmission method, processor, medium, and product based on the UCIe protocol. On the transmitting side, multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffers of corresponding virtual channels through multiple virtual channels. Each virtual channel stores data of one AXI channel attribute from the AXI data of one service attribute into the buffer of the corresponding virtual channel. Data is then read from the multiple buffers and transmitted to the receiving side through the adaptation layer and physical layer. This invention, by introducing a virtual channel mechanism at the UCIe protocol layer, enables data from different AXI services and different AXI channels to be transmitted point-to-point through independent virtual channels, thereby effectively improving the efficiency of AXI data transmission between chips. Attached Figure Description

[0047] To more clearly illustrate the technical solution of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0048] Figure 1 This is a flowchart of a data transmission method based on the UCIe protocol provided in an embodiment of the present invention;

[0049] Figure 2 This is a schematic diagram of the protocol layer for transmitting two sets of AXI services through UCIe via multiplexed physical channels, as provided in an embodiment of the present invention.

[0050] Figure 3 This is a schematic diagram of the flow control process for a single virtual channel provided in an embodiment of the present invention;

[0051] Figure 4 This is a schematic diagram of the Flit format as defined by the existing UCIe protocol;

[0052] Figure 5 This is a schematic diagram of the header components in the Flit format specified by the existing UCIe protocol;

[0053] Figure 6 This is a schematic diagram of the DLP field composition provided in the embodiments of the present invention;

[0054] Figure 7This is a structural block diagram of a processor provided in an embodiment of the present invention. Detailed Implementation

[0055] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0056] It is understood that the various numerical designations used in the embodiments of this invention are merely for descriptive convenience and are not intended to limit the scope of this application. The order of the process numbers does not imply the order of execution; the execution order of each process should be determined by its function and internal logic.

[0057] In embodiments of the invention, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, without necessarily requiring or implying any such actual relationship or order between these entities or operations. The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes said element.

[0058] The following explains some terms and concepts involved in the embodiments of the present invention.

[0059] UCIe is a hierarchical chip interconnect protocol, mainly consisting of three layers, each performing different functions. The main functions of each layer, from top to bottom, are as follows:

[0060] Protocol Layer: As the connection layer between the bus and the UCIe adapter layer, it provides a variety of data format options and converts raw data into data packets of a specific length to meet the data bit width requirements of the FDI interface between the Protocol Layer and the adapter layer, making it easier to send to the lower layer.

[0061] Adapter: As the connection layer between the UCIe protocol layer and the physical layer, it ensures the correctness and integrity of data transmission. When the protocol layer supports multiple different protocols, it is responsible for arbitration and multiplexing, link state management, and parameter negotiation with remote link partners.

[0062] Physical Layer: As the bottom layer of the UCIe protocol, it is responsible for link training, transmission channel repair, inversion, and implementation of scrambling decoding logic. The analog front-end in the physical layer is responsible for data transmission and clock transmission.

[0063] AXI (Advanced eXtensible Interface) is a bus protocol designed for high performance, high bandwidth, and low latency on-chip bus protocols.

[0064] AXI Channel: The channel defined by the AXI protocol. In AXI4, it is divided into AW (Address Write) channel, W (Write Data) channel, B (Completion) channel, AR (Address Read) channel, and R (Read Response) channel.

[0065] FDI (Flit-Aware Die-to-Die Interface) is the standard interface between the protocol layer and the adaptation layer specified by the UCIe protocol.

[0066] Credit indicates the current usage of the receiver's buffer depth, i.e., the available space in the receiver's buffer, and is often used for flow control.

[0067] Please see Figure 1 , Figure 1 This is a flowchart illustrating a data transmission method based on the UCIe protocol provided in an embodiment of the present invention. The data transmission method based on the UCIe protocol specifically includes:

[0068] S11: Multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffer of the corresponding virtual channel (VC) through multiple virtual channels; wherein, each of the virtual channels is used to store data of one AXI channel attribute from the AXI data of one service attribute into the buffer of the corresponding virtual channel.

[0069] AXI data includes, but is not limited to, AXI bus signals and AXI service data.

[0070] S12: Read data from the multiple buffers and transmit it to the receiving side through the adaptation layer and the physical layer.

[0071] In this embodiment of the invention, when multiple sets of AXI data with different service attributes reuse the physical channel between the AXI bus and the UCIe protocol layer, the transmitting side constructs multiple virtual channels on the physical channel. Data with different service attributes and different AXI channel attributes are stored in the buffer of each virtual channel through an independent virtual channel. Then, data with different service attributes and different AXI channel attributes are read from the buffers of each virtual channel and transmitted sequentially through the adaptation layer and physical layer to the receiving side. This embodiment of the invention introduces a virtual channel mechanism at the UCIe protocol layer, enabling data from different AXI services and different AXI channels to be transmitted point-to-point through independent virtual channels, thereby effectively improving the AXI data transmission efficiency between chips.

[0072] It should be noted that the term "receiving side" can also be described as receiving end, receiving chip, or receiving core, and the four terms can be used interchangeably. Similarly, the term "transmitting side" can also be described as transmitting end, transmitting chip, or transmitting core, and the four terms can be used interchangeably. This invention does not impose any specific limitations on these terms.

[0073] In an optional embodiment, storing multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer into the buffer of the corresponding virtual channel through multiple virtual channels includes:

[0074] The multiple sets of AXI data are split according to AXI channel attributes, and corresponding virtual channels are created for each type of AXI channel attribute for transmission;

[0075] Data of various AXI channel attributes are split according to business attributes, and corresponding virtual channels are created for each business attribute for transmission, so as to store data of different business attributes and different AXI channel attributes in multiple sets of AXI data into different buffers.

[0076] It is understandable that by splitting multiple sets of AXI data according to AXI channel attributes, and then further splitting the resulting data of various AXI channel attributes according to service attributes, multiple data sets with different AXI channel attributes and different service attributes can be obtained. Then, a virtual channel is created for each data set with different AXI channel attributes and different service attributes to transmit the corresponding data. This virtual channel has buffers on both the sending and receiving sides.

[0077] Since the AXI bus interface with the UCIe protocol layer has only three physical channels: AW&W&R channels (physical channel 0), AR channel (physical channel 1), and B channel (physical channel 2), these three physical channels transmit multiple independent sets of AXI data. This means that these three physical channels are multiplexed by multiple AXI services to reduce circuit resource consumption. Therefore, the AW, W, R, AR, and B AXI channels can all be divided into logically unrelated channels. Based on this, these three physical channels can be divided into multiple virtual channels according to AXI channel attributes and service attributes. For example, first, the three physical channels can be divided into virtual channels according to AXI channel attributes, such as virtual channels corresponding to AW, W, R, AR, and B channels, or virtual channels corresponding to AW&W, R, AR, and B channels. Then, according to service attributes, the virtual channels corresponding to different AXI channels can be divided, with each service attribute corresponding to one virtual channel. This separates multiple sets of AXI data according to service attributes and AXI channel attributes.

[0078] Furthermore, virtual channels can be divided according to business needs. For example, is it required that the write address be transmitted first and the write data be transmitted later, or that the write address and write data be transmitted together on the AW channel, and whether the data on the W channel needs to be transmitted together? If the write address is required to be transmitted first and the write data is transmitted later, then the AW channel and the W channel need to be split separately, and the AW channel and the W channel need to be divided into virtual channels respectively. If the write address and the write data are transmitted together, then it is not necessary to split the AW channel and the W channel. It is only necessary to divide the physical channel 0 shared by the AW channel and the W channel into virtual channels.

[0079] Each virtual channel has independent buffers on both the sending and receiving sides. Data transmitted from a virtual channel will be stored in the sending buffer of that virtual channel, and data read from the sending buffer of that virtual channel will be transmitted to the receiving buffer of that virtual channel.

[0080] For example, such as Figure 2 As shown, taking two sets of AXI data transmissions, requiring the simultaneous transmission of write address and write data, as an example, physical channel 0 can transmit AW and W data from service 1's AXI data, R data from service 1's AXI data, AW and W data from service 2's AXI data, and R data from service 2's AXI data. To maintain the independence of AXI channels for the same service, the AW, W data, and R data are first separated, that is... Figure 2 At the first fork in the data structure; further separate the R data and AW / W data according to their business attributes, that is, divide them into R data for business 1, R data for business 2, AW / W data for business 1, and AW / W data for business 2. Figure 2At the second fork, virtual channels are established for the transmission of these four data streams. The four data streams are then separated according to AXI channels and business attributes and stored in the corresponding buffers VC0, VC1, VC2, and VC3 of the four virtual channels.

[0081] Physical Channel 1 and Physical Channel 2 only transmit data from the same AXI channel for different services. Therefore, unlike Physical Channel 0, they do not need to distinguish AXI channel attributes. Data can be separated simply according to different service attributes. The final data separation result is as follows: Figure 2 As shown, the data on physical channel 1 is divided into AR data in the AXI data of service 1 and AR data in the AXI data of service 2. The data on physical channel 2 is divided into B data in the AXI data of service 1 and B data in the AXI data of service 2. Virtual channels are established for these four data streams for transmission, and these four data streams are stored in the corresponding virtual channel buffers VC4, VC5, VC6, and VC7 respectively.

[0082] For cases requiring the splitting of AW and W channels, physical channel 0 can transmit the AW and W data (transmitted separately) from the AXI data of services 1 and 2, as well as the R data from the AXI data of services 1 and 2. Virtual channels are established for each of these six data streams for transmission. The data streams, after being separated according to AXI channel and service attributes, are stored in the corresponding buffers VC0, VC1, VC2, VC3, VC4, and VC5 of the six virtual channels. Data on physical channel 1 is divided into AR data from the AXI data of services 1 and 2, and data on physical channel 2 is divided into B data from the AXI data of services 1 and 2 and B data from the AXI data of service 2. Virtual channels are established for each of these four data streams for transmission, and the data streams are stored in the corresponding buffers VC6, VC7, VC8, and VC9 of the virtual channels.

[0083] It should be noted that during the virtual channel establishment process, for cases where three or more AXI services are reused, the AXI channel attribute division stage and... Figure 2The two AXI service multiplexing scenarios shown are the same, but in the service attribute division stage, an AXI channel can be divided into virtual channels with the same number of services to separate data with different service attributes. For example, when transmitting three sets of AXI data, based on the above principle, physical channel 0 can transmit AW and W data from the AXI data of services 1, 2, and 3, and R data from the AXI data of services 1, 2, and 3. Virtual channels are established for these six data streams for transmission, and the buffers VC0, VC1, VC2, VC3, VC4, and VC5 of the corresponding six virtual channels are stored after the six data streams are separated according to the AXI channel and service attributes. The data on physical channel 1 is divided into AR data in the AXI data of services 1, 2, and 3. The data on physical channel 2 is divided into B data in the AXI data of services 1, 2, and 3 and B data in the AXI data of service 2. Virtual channels are established for these six data streams for transmission, and these six data streams are stored in the corresponding virtual channel buffers VC6, VC7, VC8, VC9, VC10, and VC11, and so on.

[0084] Furthermore, the distinction between data on the physical channel can be achieved by parsing the information attached to the inserted data at the UCIe protocol layer, or by directly following the data transmission on the physical channel with the identifier (i.e., ID number) of the virtual channel to which it should belong; preferably, in this embodiment of the invention, the distinction between data on the physical channel is achieved by using the identifier of the virtual channel to which the data is transmitted.

[0085] For example, when dividing AXI data on a physical channel into virtual channels for transmission, the data transmitted on each virtual channel carries the identifier of that virtual channel. It's understandable that the identifier of a virtual channel is unique, mapping the service attributes and AXI channel attributes of the data transmitted on that virtual channel. Therefore, the identifier of a virtual channel can determine the service to which the transmitted data belongs and the AXI channel it belongs to.

[0086] After the above data segmentation, it can be found that data of the same AXI channel for the same service is stored in the same buffer. Furthermore, in this embodiment of the invention, the buffer is implemented using a FIFO (first in first out) component. The characteristic of the FIFO component is that the data written first will be read first, thereby ensuring that the data transmitted in a fixed order within a buffer will not be disrupted and avoiding the problem of data transmission order errors. At the same time, the written data and read data of different buffers can be controlled separately and do not affect each other. This ensures that the data of the same AXI channel for different services remains under independent control.

[0087] If data from the same AXI channel of different services is stored in the same buffer, for example, if services 1 and 2 both need to write multiple data entries, service 1 needs to wait for the write response, i.e., after the B channel information of service 1 is received, before it can continue to send data. However, if the B channel data of services 1 and 2 is written to the same buffer, it will wait for all the B channel data of service 2 preceding the data of service 1 to be sent before it can be sent. This will cause significant transmission delay and reduce transmission efficiency.

[0088] In this embodiment of the invention, by storing data from the same AXI channel of different services in the same buffer and transmitting them based on the first-in-first-out principle while maintaining independent control, the separation of data between the two types of AXI services is achieved. The sending and returning of one type of service will not affect the sending and returning of the other type of service. This avoids the transmission timing disorder and transmission delay caused by the mixing of data from the same AXI channel across services, thereby effectively reducing transmission delay and improving the transmission efficiency of UCIe AXI data transmission.

[0089] Furthermore, the method also includes:

[0090] Perform independent flow control on each of the aforementioned virtual channels;

[0091] Each of the virtual channels has a buffer on both the sending and receiving sides. Data read from the buffer of any virtual channel on the sending side is transmitted to the buffer of the corresponding virtual channel on the receiving side.

[0092] Specifically, the independent flow control for each of the virtual channels includes:

[0093] For each of the virtual channels, at least one of the following credit counting operations is performed to update the credit value of the target side's buffer on the opposite side; wherein the target side is the sending side or the receiving side;

[0094] First credit counting operation: Reset the credit value on the target side;

[0095] Second credit counting operation: Initialize the credit value of the target side;

[0096] Third credit counting operation: When the credit value of the buffer on the other side is received, the credit value of the target side is updated to the received credit value;

[0097] Fourth credit counting operation: When data is transmitted from the buffer on the target side to the buffer on the opposite side, the credit value on the target side is reduced by a preset step size.

[0098] Wherein, the priority of the first credit counting operation is higher than the priority of the second credit counting operation, the priority of the second credit counting operation is higher than the priority of the third credit counting operation, and the priority of the third credit counting operation is higher than the priority of the fourth credit counting operation.

[0099] The first credit counting operation and the second credit counting operation are executed during the corresponding buffer unreset and initialization phase; the third credit counting operation and the fourth credit counting operation are executed during the corresponding buffer data transmission phase.

[0100] It should be noted that the flow control and credit value update processes of the virtual channel are the same on both the sending and receiving sides. To avoid repetition, this embodiment of the invention uses the sending side as the target side and the receiving side as the counterpart side to provide a detailed description of the flow control and credit value update processes of the virtual channel.

[0101] Flow control is a core mechanism in communication and data transmission. By coordinating the data transmission intervals between the sending and receiving sides, it avoids data loss caused by exceeding the receiving end's processing capacity, such as when the buffer is full or overflowing. This invention, through independent flow control of the virtual channel, further enhances the independence of the virtual channel, avoids cross-service and cross-AXI channel traffic interference, and improves transmission stability.

[0102] For example, such as Figure 3 Flowchart of flow control for a single virtual channel. Figure 3 The two interconnected chips are referred to as Die0 (transmitter side) and Die1 (receiver side). In this embodiment of the invention, all virtual channels are independently flow-controlled. Each virtual channel has an independent buffer (also called a BUFFER) on both Die0 (transmitter side) and Die1 (transmitter side). The credit value of each virtual channel is inserted into specific bits of the data sent by the UCIe protocol layer, and sent to the other side sequentially according to the order of buffer VC0 to VC7. This is done cyclically throughout the data transmission process, keeping the credit value of each virtual channel continuously updated. This ensures that when the buffer on the receiving side of one or more virtual channels is about to be full and its transmitting side can no longer send service data, it will not affect the transmission and reception of other virtual channels.

[0103] Specifically, the execution logic of the local credit counter on the sending side in this embodiment of the invention is as follows:

[0104] "if (reset valid) credit_local_count = 0; / / Reset the credit value, the reset value of the credit value is 0; "

[0105] else if (credit value initialization) credit_local_count = initial_credit_value; / / Initialize the credit value;

[0106] else if (a valid credit value is received) credit_local_count = received and parsed credit value; / / Update the credit value to the currently received credit value;

[0107] else if (a piece of data is sent from the sending buffer), decrement credit_local_count by 1. / / When a piece of data is sent from the sending buffer, the credit value is decremented by 1.

[0108] The initial value of the credit value is generally preset and can be determined based on the size of the buffer on the other side, or in combination with the computing resources and bandwidth on the other side. In this embodiment of the invention, no specific limitation is made.

[0109] like Figure 3 As shown, in this embodiment of the invention, a local credit counter (Local CreditCount) is added to the sending side. When a data interruption occurs between Die0 (sending side) and Die1 (receiving side), and Die0 (sending side) does not receive the credit value sent by Die1 (receiving side) for a long time, Die0 (sending side) can manage the maximum number of data (DATA) that can be sent based on the credit value currently recorded by the local credit counter, and will not cause the buffer of Die1 (receiving side) to overflow.

[0110] Understandably, the reset and initialization of credit values ​​are generally performed during the buffer de-reset and initialization phase. First, the credit value recorded in the local credit counter is reset, and then the credit value is initialized. Subsequently, during data transmission, if the sending side receives a credit value sent by the receiving side, the credit value recorded in the local credit counter is updated to the currently received credit value. If the sending side's buffer sends data, the credit value recorded in the local credit counter is decremented by 1. If receiving a credit value sent by the receiving side and sending data by the sending side's buffer occur simultaneously, the credit value recorded in the local credit counter is updated to the currently received credit value first. Through this credit value update mechanism, the consistency of credit values ​​in the sending and receiving side's buffers can be ensured, preventing data overflow and maximizing data transmission efficiency, while avoiding congestion and data loss.

[0111] Furthermore, the method also includes:

[0112] For each of the virtual channels, a virtual channel traffic counter is set on both the sending side and the receiving side;

[0113] The virtual channel counter on the sending side is used to record the total number of data transmitted in the buffer of the sending side of the corresponding virtual channel, and the virtual channel counter on the receiving side is used to record the total number of data received in the buffer of the receiving side of the corresponding virtual channel.

[0114] In this embodiment of the invention, each virtual channel has a virtual channel counter (VC counter) in both its transmitting and receiving buffers, such as... Figure 2 As shown, on the transmitting side, there are eight VC counters corresponding to each virtual channel. These counters record the total amount of AXI data transmitted through each virtual channel and write it to the system register. These VC counters are controlled by the upper-layer software, and the counting window can be arbitrarily selected. By using these VC counters, it is possible to easily monitor the data transmission traffic of each AXI channel for each service within a certain time window, thereby achieving precise control of data traffic and reducing monitoring complexity. Similarly, on the receiving side, there are also eight VC counters corresponding to each virtual channel to count the received data traffic. Under normal operating conditions, the transmission traffic on the transmitting side of each virtual channel is the same as the reception traffic.

[0115] In an optional embodiment, the step of reading data from the plurality of said buffers and transmitting it to the receiving side through an adaptation layer and a physical layer includes:

[0116] The multiple cache areas are polled and arbitrated, and two cache areas are selected in each round of arbitration;

[0117] Data is read from the two buffers determined according to the first-in-first-out rule and packaged to obtain the data packet to be transmitted in this round;

[0118] The data packet is transmitted to the receiving side through the adaptation layer and the physical layer.

[0119] Specifically, the step of polling and arbitrating multiple cache areas, and determining two cache areas in each round of arbitration, includes:

[0120] The buffers of the read data channel, write address channel and the virtual channel corresponding to the write data channel are polled and arbitrated by the first arbitrator, and a buffer is determined in each round of arbitration;

[0121] The buffers of the virtual channels corresponding to the read address channel and the write return channel are polled and arbitrated by a second arbitrator, and one buffer is determined in each round of arbitration, so that two buffers are determined in each round of arbitration by the first arbitrator and the second arbitrator.

[0122] In this embodiment of the invention, the virtual channel's buffer uses two arbiters to decide which buffer to read in each round, for example, deciding from which buffer to read data in the current clock cycle according to certain rules. Specifically, multiple buffers on the sending side can be grouped based on the data width of the sending side's buffer, with each group using an arbiter for decision-making; the same applies to the receiving side.

[0123] Specifically, an arbitrator can be used for the buffer of the virtual channel corresponding to the AW&W&R channel to decide which buffer to read data from in the current clock cycle, and another arbitrator can be used for the buffer of the virtual channel corresponding to the AR&B channel to decide which buffer to read data from in the current clock cycle.

[0124] like Figure 2 As shown, there are arbiters Arbiter0 and Arbiter1. Arbiter0 manages buffers VC0, VC1, VC2, and VC3, while Arbiter1 manages buffers VC4, VC5, VC6, and VC7. The arbiters use a no-priority round-robin arbitration method. Arbiter0 can read data from the buffer of at most one virtual channel from VC0, VC1, VC2, and VC3 per clock cycle, while Arbiter1 can read data from the buffer of at most one virtual channel from VC4, VC5, VC6, and VC7 per clock cycle.

[0125] In this embodiment of the invention, two arbitrators are chosen because the data widths buffered in buffers VC0, VC1, VC2, and VC3 are relatively large, around 1000 bits, while the data widths buffered in buffers VC4, VC5, VC6, and VC7 are relatively small, around 100 bits. The subsequent data packet module packages the data read in each clock cycle into a 1024-bit data packet. Therefore, adding one data point read from VC0, VC1, VC2, and VC3 to one data point read from VC4, VC5, VC6, and VC7 achieves a rough matching of data widths. Simultaneously, using two arbitrators ensures that a maximum of two data points are processed per clock cycle. This reduces the complexity of the packetization method on the transmitting side and the unpacking method on the receiving side, reduces the path length of the combinational logic implemented in the digital circuit, and improves timing convergence, allowing operation at high-frequency clocks, such as those above 1 GHz. The choice of a no-priority round-robin arbitration method is based on the fact that the two types of AXI services and the buffers of each virtual channel are treated equally, with no distinction in priority. The buffers of virtual channels that already have cached data will be arbitrated in a no-priority round-robin manner, so that the data in the buffers of each type of AXI service and each virtual channel has an equal chance to be read. This avoids the situation where only one type of service data is transmitted for a period of time, causing the transmission of another type of service data to stagnate, resulting in uneven distribution of UCIe transmission bandwidth. It ensures the fairness, reliability and overall efficiency of transmission in multi-service scenarios, and supports the stability of chiplet collaboration at the underlying interconnection level.

[0126] In an optional embodiment, transmitting the data packet to the receiving side through the adaptation layer and the physical layer includes:

[0127] The data packet is converted into a Flit data packet in a preset Flit format; wherein, the setting field of the Flit data packet is written into the credit value of the buffer of one of the virtual channels;

[0128] The Flit data packet is transmitted to the receiving side through the adaptation layer and the physical layer.

[0129] The setting field is located in the third data block of the Flit data packet: the setting field is used to indicate the type information of the setting field, the credit value of the corresponding virtual channel's buffer, and the virtual channel to which the information content of the setting field belongs.

[0130] The credit values ​​of the buffers of each virtual channel are cyclically inserted into the setting fields of the Flit data packets transmitted in each round, according to a set order.

[0131] It supports the 256B FlitFormat (Stream Control Unit Format, or Flit for short) under the streaming protocol specified in the UCIe protocol. The UCIe protocol specifies that its Flit format (a fixed-length packet format) consists of the following: Figure 4 As shown, a 256-byte Flit format consists of four data blocks: 62-byte Flit Chunk 0 (also known as the first data block), 62-byte Flit Chunk 1 (also known as the second data block), 64-byte Flit Chunk 2 (also known as the third data block), and 62-byte Flit Chunk 3 (also known as the fourth data block). In Flit Chunk 0, the lower two bytes are the Flit Header; the higher two bytes of Flit Chunks 1 and 3 are CRC (Cyclic Redundancy Check) fields; and Flit Chunk 2 primarily carries the data content. The specific data arrangement of the Flit Header is as follows... Figure 5 As shown.

[0132] Based on the UCIe protocol, this embodiment of the invention adds a custom setting field (also called a specific bit) to the lower 2 bytes of data block 2 (i.e., the third data block), such as the DLP (Data Link Packet) field. Figure 6 As shown.

[0133] The DLP field includes flow control information, including: the type information of the DLP field, the credit value of the virtual channel, and which virtual channel the information in this DLP field belongs to (e.g., the virtual channel identifier). For example, bits 0-3 of the first byte of the DLP field (DLP B1) record which virtual channel (VC) the information in this DLP field belongs to, bits 4-7 record the type information (Type) of the DLP field, and bits 0-7 of the second byte of the DLP field (DLP B2) record the credit value of the virtual channel. By inserting the above information into the DLP field of the Flit data packet generated based on the Flit format, flow control information can be transmitted between two dies. After receiving the Flit data packet, the receiving dies parse the information content of the DLP field, obtain the credit value, and identify the virtual channel to which the credit value belongs based on the virtual channel identifier. They can then update the credit value in the buffer of the corresponding virtual channel, thereby implementing flow control for the corresponding virtual channel.

[0134] This invention, based on the UCIe protocol, defines a custom DLP field to transmit flow control information for each virtual channel, ensuring continuous transmission and thus enabling the flow control information to be updated more frequently.

[0135] In this embodiment of the invention, each Flit data packet carries only the flow control information of one virtual channel. With eight virtual channels, the flow control information of each virtual channel needs to be sent continuously in turn. On the one hand, this reduces the bandwidth occupation of the flow control information and improves the transmission efficiency. On the other hand, it ensures that the flow control information of each virtual channel is sent regularly, thus ensuring the accuracy of flow control.

[0136] Furthermore, the method also includes:

[0137] The receiving side parses and unpacks the received Flit data packets to obtain the data transmitted in several buffers on the sending side;

[0138] The data transmitted by the several buffers on the sending side are respectively stored in the buffers of the corresponding virtual channels on the receiving side.

[0139] like Figure 2 As shown, for data read from the buffer of one virtual channel (VC0, VC1, VC2, VC3, VC0) on the sending side, and data read from the buffer of one virtual channel (VC4, VC5, VC6, VC7, VC4) on the receiving side, the data is first packaged and generated by the protocol layer to obtain Flit data packets. Then, it is transmitted to the receiving side through the adaptation layer and physical layer. Similarly, after passing through the physical layer and adaptation layer, the Flit data packets are transmitted to the protocol layer on the sending side. After Flit parsing and data unpacking on the protocol side, the data of the two virtual channels in the buffers (VC0, VC4) on the sending side are obtained. Then, these two data are stored into the corresponding buffers (VC0, VC4) on the receiving side, respectively, to realize point-to-point data transmission.

[0140] It is understandable that the data transmission principle on the receiving side is the same as that described above, and will not be explained in detail here to avoid repetition.

[0141] Compared with the prior art, the beneficial effects of the embodiments of the present invention are as follows:

[0142] (1) In the scenario where multiple AXI services using multiple physical channels are transmitted through UCIe, a virtual channel mechanism is added to the UCIe protocol layer to separate the signals between different AXI services. Data from different AXI services and different AXI channels are transmitted point-to-point through independent virtual channels. The sending and returning of one type of service will not affect the sending and returning of another type of service, thus improving the transmission efficiency of AXI data in UCIe in this scenario.

[0143] (2) Each virtual channel performs flow control between the sending and receiving sides independently. At the same time, a fair polling arbitration mechanism is applied on the sending side to ensure that the data buffered by each virtual channel has an equal chance to be read out. This realizes independent flow control of all virtual channels in the UCIe protocol layer. When the receiving buffer of one or several virtual channels is full, it will not affect the transmission of other virtual channels, further improving the transmission efficiency of UCIe AXI data in this scenario.

[0144] (3) Based on the UCIe protocol, the DLP field is customized to transmit the flow control information of each virtual channel, ensuring continuous transmission so that the flow control information is updated more frequently. It is compatible with the standardized interconnection framework of the UCIe protocol and solves the timeliness problem of flow control of virtual channels through high-frequency dynamic feedback.

[0145] See Figure 7 , Figure 7 This invention provides a structural block diagram of a processor, which includes a first chip 11 and a second chip 12, wherein the first chip 11 and the second chip 12 are interconnected via the UCIe protocol.

[0146] The UCIe protocol layer of the first chip 11 is configured as follows:

[0147] Multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffer area of ​​the corresponding virtual channel through multiple virtual channels; wherein, each of the virtual channels is used to store data of one AXI channel attribute from the AXI data of one service attribute into the buffer area of ​​the corresponding virtual channel.

[0148] Data is read from the multiple buffers and transmitted to the second core 12 via the adaptation layer and the physical layer.

[0149] The processor can be any one of GPU (Graphics Processing Unit), TPU (Tensor Processing Unit), NPU (Neural Network Processing Unit), DPU (Deep Learning Processing Unit), APU (Accelerated Processing Unit), and GPGPU (General-Purpose Graphics Processing Unit), and this invention does not impose any specific limitation.

[0150] It should be noted that the working process of the first chip in the processor described in the embodiments of the present invention can refer to the working process of the transmitting side in the data transmission method based on the UCIe protocol described in the above embodiments, and the working process of the second chip can refer to the working process of the receiving side in the data transmission method based on the UCIe protocol described in the above embodiments. The technical effects achieved are also the same as those of the data transmission method based on the UCIe protocol described in the above embodiments, and will not be repeated here.

[0151] This invention also provides a non-volatile computer-readable storage medium storing a computer program, wherein the computer program, when running, controls the device where the non-volatile computer-readable storage medium is located to execute the data transmission method based on the UCIe protocol as described in the above embodiments.

[0152] This invention also provides a computer program product, including a computer program / instruction, which, when executed by a processor, implements the data transmission method based on the UCIe protocol as described in the above embodiments.

[0153] For example, the non-volatile computer-readable storage medium can be used to store the computer program and / or modules. The processor executes the data transmission method based on the UCIe protocol by running or executing the computer program and / or modules stored in the non-volatile computer-readable storage medium and calling data stored in the non-volatile computer-readable storage medium. The non-volatile computer-readable storage medium may mainly include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the mobile phone (such as audio data, phonebook, etc.). In addition, the non-volatile computer-readable storage medium may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, memory, plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.

[0154] It should be noted that the device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Furthermore, in the accompanying drawings of the device embodiments provided by this invention, the connection relationships between modules indicate that they have communication connections, which can be specifically implemented as one or more communication buses or signal lines. Those skilled in the art can understand and implement this without any creative effort.

[0155] The above description represents the preferred embodiments of the present invention. It should be noted that, for those skilled in the art, various improvements and modifications can be made without departing from the principles of the present invention, and these improvements and modifications are also considered to be within the scope of protection of the present invention.

Claims

1. A data transmission method based on the UCIe protocol, characterized in that, include: Multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffer area of ​​the corresponding virtual channel through multiple virtual channels; wherein, each of the virtual channels is used to store data of one AXI channel attribute from the AXI data of one service attribute into the buffer area of ​​the corresponding virtual channel. Data is read from the multiple buffers and transmitted to the receiving side through the adaptation layer and the physical layer.

2. The data transmission method based on the UCIe protocol as described in claim 1, characterized in that, The process of storing multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer into the buffer area of ​​the corresponding virtual channel through multiple virtual channels includes: The multiple sets of AXI data are split according to AXI channel attributes, and corresponding virtual channels are created for each type of AXI channel attribute for transmission; Data of various AXI channel attributes are split according to business attributes, and corresponding virtual channels are created for each business attribute for transmission, so as to store data of different business attributes and different AXI channel attributes in multiple sets of AXI data into different buffers.

3. The data transmission method based on the UCIe protocol as described in claim 1, characterized in that, The process of reading data from multiple buffers and transmitting it to the receiving side through an adaptation layer and a physical layer includes: The multiple cache areas are polled and arbitrated, and two cache areas are selected in each round of arbitration; Data is read from the two buffers determined according to the first-in-first-out rule and packaged to obtain the data packet to be transmitted in this round; The data packet is transmitted to the receiving side through the adaptation layer and the physical layer.

4. The data transmission method based on the UCIe protocol as described in claim 3, characterized in that, The step of polling and arbitrating multiple cache areas, and determining two cache areas in each round of arbitration, includes: The buffers of the read data channel, write address channel and the virtual channel corresponding to the write data channel are polled and arbitrated by the first arbitrator, and a buffer is determined in each round of arbitration; The buffers of the virtual channels corresponding to the read address channel and the write return channel are polled and arbitrated by a second arbitrator, and one buffer is determined in each round of arbitration, so that two buffers are determined in each round of arbitration by the first arbitrator and the second arbitrator.

5. The data transmission method based on the UCIe protocol as described in claim 4, characterized in that, The method further includes: Perform independent flow control on each of the aforementioned virtual channels; Each of the virtual channels has a buffer on both the sending and receiving sides. Data read from the buffer of one of the virtual channels on the sending side is transmitted to the buffer of the corresponding virtual channel on the receiving side.

6. The data transmission method based on the UCIe protocol as described in claim 5, characterized in that, The independent flow control for each of the virtual channels includes: For each of the virtual channels, at least one of the following credit counting operations is performed to update the credit value of the target side's buffer on the opposite side; wherein the target side is the sending side or the receiving side; First credit counting operation: Reset the credit value on the target side; Second credit counting operation: Initialize the credit value of the target side; Third credit counting operation: When the credit value of the buffer on the other side is received, the credit value of the target side is updated to the received credit value; Fourth credit counting operation: When data is transmitted from the buffer on the target side to the buffer on the opposite side, the credit value on the target side is reduced by a preset step size.

7. The data transmission method based on the UCIe protocol as described in claim 6, characterized in that, The first credit counting operation has a higher priority than the second credit counting operation, the second credit counting operation has a higher priority than the third credit counting operation, and the third credit counting operation has a higher priority than the fourth credit counting operation. The first credit counting operation and the second credit counting operation are executed during the corresponding buffer unreset and initialization phase; the third credit counting operation and the fourth credit counting operation are executed during the corresponding buffer data transmission phase.

8. The data transmission method based on the UCIe protocol as described in claim 6, characterized in that, The method further includes: For each of the virtual channels, a virtual channel traffic counter is set on both the sending side and the receiving side; The virtual channel counter on the sending side is used to record the total number of data transmitted in the buffer of the sending side of the corresponding virtual channel, and the virtual channel counter on the receiving side is used to record the total number of data received in the buffer of the receiving side of the corresponding virtual channel.

9. The data transmission method based on the UCIe protocol as described in claim 3, characterized in that, The transmission of the data packet to the receiving side through the adaptation layer and the physical layer includes: The data packet is converted into a Flit data packet in a preset Flit format; wherein, the setting field of the Flit data packet is written into the credit value of the buffer of one of the virtual channels; The Flit data packet is transmitted to the receiving side through the adaptation layer and the physical layer.

10. The data transmission method based on the UCIe protocol as described in claim 9, characterized in that, The setting field is located in the third data block of the Flit data packet: the setting field is used to indicate the type information of the setting field, the credit value of the corresponding virtual channel's buffer, and the virtual channel to which the information content of the setting field belongs.

11. The data transmission method based on the UCIe protocol as described in claim 9, characterized in that, The credit values ​​of the buffers of each virtual channel are cyclically inserted into the setting fields of the Flit data packets transmitted in each round, according to a set order.

12. The data transmission method based on the UCIe protocol as described in claim 9, characterized in that, The method further includes: The receiving side parses and unpacks the received Flit data packets to obtain the data transmitted in several buffers on the sending side; The data transmitted by the several buffers on the sending side are respectively stored in the buffers of the corresponding virtual channels on the receiving side.

13. A processor, characterized in that, include: A first core and a second core are interconnected via the UCIe protocol; The UCIe protocol layer of the first chip is configured as follows: Multiple sets of AXI data with different service attributes from the physical channel between the multiplexed AXI bus and the UCIe protocol layer are stored in the buffer area of ​​the corresponding virtual channel through multiple virtual channels; wherein, each of the virtual channels is used to store data of one AXI channel attribute from the AXI data of one service attribute into the buffer area of ​​the corresponding virtual channel. Data is read from the multiple buffers and transmitted to the second core through the adaptation layer and physical layer of the first core.

14. A non-volatile computer-readable storage medium, characterized in that, The non-volatile computer-readable storage medium stores a computer program, wherein, when the computer program is executed, it controls the device where the non-volatile computer-readable storage medium is located to perform the data transmission method based on the UCIe protocol as described in any one of claims 1 to 12.

15. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instruction is executed by the processor, it implements the data transmission method based on the UCIe protocol as described in any one of claims 1 to 12.

Citation Information

Patent Citations

  • Methods for establishing virtual channels, data transmission methods, and line cards.

    CN102263698A

  • Data transmission system and method based on FPGA

    CN108259368A

  • Data processing method of single-channel SPI (Serial Peripheral Interface) and related device

    CN117076368A

  • Network-on-chip, data transmission method, chip and equipment

    CN117176674A

  • Data processing method, data transmission system, electronic equipment and storage medium

    CN118069578A