Circuit and method for multi-core communication

By designing interrupt trigger mechanisms and instruction-driven multi-core communication circuits in multi-core processor systems, the problems of poor configuration flexibility and insufficient scalability in the existing technology are solved, efficient and flexible multi-core communication is achieved, and data throughput is improved. Reduces hardware overhead.

CN119025467APending Publication Date: 2024-11-26NANJING UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411069936.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-08-06
Publication Date
2024-11-26

AI Technical Summary

Technical Problem

The communication methods in existing multi-core processor systems have problems such as poor configuration flexibility, insufficient scalability and high hardware complexity, and cannot adapt to the needs of complex application scenarios.

Method used

A multi-core communication circuit including a receiving unit, a sending unit and a global register is designed. The interrupt triggering mechanism and instruction driving method are used to process and transmit data through unpacking buffer circuit, program address conversion circuit, program execution circuit and channel to realize data processing and transmission. Flexible packet processing and transmission.

Benefits of technology

It improves the flexibility and efficiency of multi-core communication, can adapt to various complex data transmission needs, improves data throughput and reduces hardware overhead.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119025467A_ABST
    Figure CN119025467A_ABST
Patent Text Reader

Abstract

The invention discloses a circuit and a method for multi-core communication. The circuit is deployed on each core as an inter-core communication module and is used for transmitting information among different cores in the form of data packets; the circuit comprises a receiving unit, a sending unit and a global register, the receiving unit is used for receiving data from the outside of the core, analyzing and processing the data and then transmitting the data to the inside of the core; the sending unit is used for receiving data from the interior of the core, analyzing and processing the data in the core and then transmitting the data to the exterior of the core; and the global register is used for recording the current working mode and working state and is respectively connected with the receiving unit and the sending unit. The circuit has the advantages of being high in configuration flexibility, simple in structure and high in expandability, a mode of interrupting a trigger program is adopted, the configurability is higher, and various complex data transmission requirements can be met.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of integrated circuit design and communication technology, and in particular to a circuit and method for realizing efficient and flexible multi-core communication in a multi-core processor system. Background Art

[0002] With the development of integrated circuit technology, multi-core processor systems have become the mainstream architecture for high-performance computing. In a multi-core processor system, communication between cores is the key to ensuring efficient operation of the system. The traditional multi-core communication method uses the NOC interface to connect each core, which can only meet simple communication needs and cannot cope with complex application scenarios.

[0003] Implementing multi-core communication at the hardware level, especially through customized circuit design, can significantly improve the efficiency and real-time performance of communication. However, existing hardware multi-core communication solutions often have problems such as poor configuration flexibility, insufficient scalability, or high hardware complexity. For example, some hardware communication modules with fixed structures may not be able to adapt to the communication requirements in different application scenarios; and some hardware communication solutions based on complex network structures may introduce excessive hardware overhead and power consumption.

[0004] Therefore, developing a circuit and method that has high configuration flexibility, strong scalability, and can achieve efficient multi-core communication at the hardware level has important practical application value. Summary of the invention

[0005] In response to the challenges of data processing in existing communication systems, the present invention provides a circuit and method for multi-core communication, aiming to achieve efficient and reliable data transmission and processing.

[0006] To achieve the above objectives, the technical solution adopted by the present invention is as follows:

[0007] A circuit for multi-core communication, the circuit comprising a receiving unit, a sending unit and a global register;

[0008] The receiving unit is used to receive data from outside the core, parse and process the data, and then transmit it to the core;

[0009] The sending unit is used to receive data from the core, parse and process the data in the core, and then transmit it to the outside of the core;

[0010] The global register is used to record the current working mode and working status and is connected to the receiving unit and the sending unit respectively.

[0011] Furthermore, the receiving unit includes an unpacking cache circuit, a first interrupt-to-program address conversion circuit, a first program execution circuit, a first program memory and an output channel. The unpacking cache circuit is used to receive data from outside the core. The unpacking cache circuit is connected to the first interrupt-to-program address conversion circuit, the first program execution circuit and the output channel in sequence. The first program execution circuit is also connected to the first program memory and the global register respectively.

[0012] Furthermore, the sending unit includes an input channel, a second interrupt-to-program address conversion circuit, a program address queue, a second program execution circuit, a second program memory and a package sending circuit. The input channel is connected to the second interrupt-to-program address conversion circuit, the program address queue, the second program execution circuit and the package sending circuit in sequence. The second program execution circuit is also connected to the second program memory and the global register respectively.

[0013] The present invention also provides a communication method using the above circuit, the method uses the receiving unit to receive data, and the specific steps include:

[0014] Step 11, the receiving unit classifies and caches the received out-of-core data, and the data is divided into control packets and data packets;

[0015] Step 12, unpacking the control packet, generating an interrupt signal, and generating a corresponding program address according to the interrupt signal;

[0016] Step 13, the receiving unit executes the corresponding program according to the program address, and the instructions in the program are decoded to generate corresponding control signals;

[0017] In step 14, the receiving unit processes the data packet and the control signal obtained in step 13 and sends them to the core.

[0018] Furthermore, the method uses the sending unit to send data, and the specific steps include:

[0019] Step 21, the sending unit receives control information and data information in the core, the control information is the control information required by another AI core, and the data information is the data required for calculation by another AI core;

[0020] Step 22, the control information triggers a corresponding interrupt signal, and the interrupt signal is converted into the first address of the program;

[0021] Step 23, the sending unit executes the corresponding program according to the first address of the program, and the instructions in the program are decoded to generate corresponding control signals;

[0022] In step 24, the sending unit packages the data information and the control signal obtained in step 23 and sends them out of the core.

[0023] The present invention provides a multi-core communication circuit and method based on instruction drive and interrupt trigger mechanism to meet the demand for efficient and flexible multi-core communication in a multi-core processor system. Compared with the prior art, the present invention has the following beneficial effects:

[0024] (1) The present invention adopts an interrupt triggering program, which is more configurable and can cope with various complex data transmission requirements;

[0025] (2) The data throughput rate of the present invention through data packet transmission is higher than that through interface handshake transmission;

[0026] (3) The present invention can be applied to communications between various types of cores or nodes. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] Figure 1 is a diagram of the implementation structure of the multi-core communication circuit of the present invention;

[0028] Figure 2 is a flow chart of a receiving unit of the present invention;

[0029] Figure 3 It is a flow chart of the sending unit of the present invention. DETAILED DESCRIPTION

[0030] In order to better understand the present invention, the present invention is further described below in conjunction with specific embodiments.

[0031] An embodiment of the present invention is used for communication between multiple nodes of a NOC, each node is an AI engine core for performing AI calculations, and communication data flows and control flows are required between the cores. The multi-core communication circuit of this embodiment is deployed as a communication module on multiple cores for transmitting information in the form of data packets between different cores, including: a receiving unit, a sending unit, and a global register.

[0032] The receiving unit includes an unpacking cache circuit, a first interrupt to program address conversion circuit, a first program execution circuit, a first program memory and an output channel.

[0033] The unpacking cache circuit includes a control packet FIFO, a data packet FIFO and a control parsing module. The unpacking cache circuit receives data from the NOC Router, and then stores the data in the control packet FIFO and the data packet FIFO after identification. The FIFO is used to cache the data packet and the control packet to prevent too many bubbles from being generated in the data path. The control parsing module is connected after the control packet FIFO and parses the corresponding control packet. The parsed control information and the data packet are sent to the first program execution circuit together, and the parsed control interrupt signal is sent to the first interrupt program address conversion circuit.

[0034] After receiving the interrupt signal from the unpacking buffer circuit, the first interrupt-to-program address conversion circuit converts the interrupt signal into a corresponding program address and sends it to the first program execution circuit.

[0035] The first program execution circuit includes: a first addressing circuit, a first decoding circuit, a first register channel execution unit, a first data channel execution unit and a first global register execution unit. The first addressing circuit is connected to the first interrupt program address conversion circuit and the first program memory respectively, the first decoding circuit is connected to the first addressing circuit, and the first decoding circuit is also connected to the first register channel execution unit, the first data channel execution unit and the first global register execution unit respectively, and the first register channel execution unit, the first data channel execution unit and the first global register execution unit are respectively connected to the output channel and the global register. The first register channel execution unit transmits the data packet or control packet to the first register channel in the core after processing, the first data channel execution unit transmits the data packet or control packet to the first data channel in the core after processing, and the first global register execution unit transmits the data packet or control packet to the global register after processing. After receiving the program address, the first program execution circuit uses the first addressing circuit as the first address to address the first program memory, and the fetched instruction is decoded by the first decoding circuit to obtain the corresponding control signal, and then the execution unit specified by the control signal is operated to perform calculations and operations, and finally the data packet or control packet is processed and sent to the corresponding channel or global register.

[0036] The first program memory is used to store programs for the receiving unit to implement required functions.

[0037] The output channel includes a first register channel and a first data channel. The first register channel receives control information from the first register channel execution unit, which is used to control the AI ​​calculation in the core; the first data channel receives data from the first data channel execution unit and transmits the data to the AI ​​engine in the core.

[0038] The sending unit includes an input channel, a second interrupt to program address conversion circuit, a program address queue, a second program execution circuit, a second program memory and a packing and sending circuit.

[0039] The input channel includes a second register channel and a second data channel, the second register channel receives control information from the AI ​​engine in the core that needs to perform operations on other cores, and the second data channel receives data used by the next core of the AI ​​engine in the core. The input channel is connected to the second program execution circuit via the second interrupt program address conversion circuit and the program address queue.

[0040] After receiving the interrupt signal from the AI ​​engine in the core, the second interrupt to program address conversion circuit converts it into the corresponding program address and sends it to the program address queue. The program address queue is a FIFO, which is used to receive and cache the program address from the second interrupt to program address conversion circuit, and then transmit it to the second program execution circuit.

[0041] The second program execution circuit includes: a second addressing circuit, a second decoding circuit, a second register channel execution unit, a second data channel execution unit and a second global register execution unit. The second addressing circuit is connected to the program address queue and the second program memory respectively, the second decoding circuit is connected to the second addressing circuit, and the second decoding circuit is also connected to the second register channel execution unit, the second data channel execution unit and the second global register execution unit respectively, and the second register channel execution unit, the second data channel execution unit and the second global register execution unit are respectively connected to the packaging and sending circuit and the global register. The second register channel execution unit transmits the data packet or control packet to the second register channel in the core after processing, the second data channel execution unit transmits the data packet or control packet to the second data channel in the core after processing, and the second global register execution unit transmits the data packet or control packet to the global register after processing. After receiving the program address from the program address queue, the second program execution circuit uses the second addressing unit as the first address to address the second program memory, and the fetched instruction is decoded by the second decoding circuit to obtain the corresponding control signal, and then the execution unit specified by the control information is run to perform calculations and operations, and finally the data packet or control packet is processed and sent to the packaging and sending circuit.

[0042] The second program memory is used to store the program required by the second program execution unit.

[0043] The packet sending circuit receives the data packet or control packet from the second program execution circuit, packages it and sends it to the interface of the NOC, and then sends it to other NOC nodes.

[0044] The global register is a register group used to record the current working mode and working status. Both the receiving module and the sending module can read and write it, thereby recording the current working mode and working status and communicating the receiving unit and the sending unit.

[0045] The circuit of this embodiment adopts an event-driven approach, where a specified program is triggered by an event inside or outside the core, thereby generating different circuit behaviors, and the specific behaviors can be programmed by the user, thereby upgrading the multi-core communication protocol online according to user needs. This embodiment has the advantages of strong configuration flexibility, simple structure, and strong scalability.

[0046] Furthermore, an embodiment of the present invention provides a communication method based on the multi-core communication circuit. The communication method specifically comprises the following steps:

[0047] Data reception:

[0048] Step 1: input the out-of-core data received in the NOC Router into the depacketization circuit and classify and cache it, wherein the control packets in the data are stored in the control packet FIFO, and the data packets in the data are stored in the data FIFO;

[0049] Step 2, in the unpacking circuit, unpacking the control packet to generate an interrupt signal, further transmitting the interrupt signal to the subsequent first interrupt to program address conversion circuit, and at the same time directly sending the data packet to the first program execution circuit;

[0050] Step 3, the interrupt signal generates a corresponding program address in the first interrupt to program address conversion circuit and transmits it to the first program execution circuit;

[0051] Step 4: The first program execution circuit finds the corresponding program execution in the first program memory according to the program address, and the instructions in the program are decoded by the first decoding module to generate corresponding control signals. The control signals are respectively given to the corresponding first register channel execution unit, the first data channel execution unit and the first global register execution unit;

[0052] Step 5: Each execution unit processes the input data and control information and sends them to the corresponding channels or global registers. The core receives the respective information through the corresponding channels.

[0053] Data transmission:

[0054] Step 1: The core sends corresponding control information and data information to the sending unit through the second register channel and the second data channel, where the control information is the control information required by another AI core, and the data information is the data required for calculation by another AI core;

[0055] Step 2: The control information triggers a corresponding interrupt to be sent to a second interrupt-to-program address conversion circuit, and the second interrupt-to-program address conversion circuit converts the interrupt into a program address;

[0056] Step 3, storing the program address in the program address queue;

[0057] Step 4: The second program execution circuit takes out the address from the program address queue, and then finds the program execution in the second program memory according to the corresponding address. The instructions in the program are decoded by the second decoding module to generate corresponding control signals. Further, the control signals are respectively given to the corresponding second register channel execution unit, the second data channel execution unit and the second global register execution unit;

[0058] Step 5: receiving control information and data information from the second program execution circuit, and further packaging the data and control information output from each execution unit of the second program execution circuit and sending them to the NOC interface.

[0059] The above is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and substitutions can be made without departing from the technical principles of the present invention. These improvements and substitutions should also be regarded as the scope of protection of the present invention.

Claims

1. A circuit for multi-core communication, characterized in that: The circuit includes a receiving unit, a sending unit and a global register; The receiving unit is used to receive data from outside the core, parse and process the data, and then transmit it to the core; The sending unit is used to receive data from the core, parse and process the data in the core, and then transmit it to the outside of the core; The global register is used to record the current working mode and working status and is connected to the receiving unit and the sending unit respectively.

2. The circuit for multi-core communication according to claim 1, characterized in that: The receiving unit includes an unpacking cache circuit, a first interrupt-to-program address conversion circuit, a first program execution circuit, a first program memory and an output channel. The unpacking cache circuit is used to receive data from outside the core. The unpacking cache circuit is connected to the first interrupt-to-program address conversion circuit, the first program execution circuit and the output channel in sequence. The first program execution circuit is also connected to the first program memory and the global register respectively.

3. The circuit for multi-core communication according to claim 2, characterized in that: The unpacking cache circuit includes a control packet FIFO, a data packet FIFO and a control parsing module. The control packet FIFO is used to cache control packets in out-core data, the data packet FIFO is used to cache data packets in out-core data, the control parsing module is connected to the control packet FIFO, and the data packet FIFO outputs the data packets directly to the first program execution circuit.

4. The circuit for multi-core communication according to claim 2, characterized in that: The first program execution circuit includes a first addressing circuit, a first decoding circuit, a first register channel execution unit, a first data channel execution unit and a first global register execution unit. The first addressing circuit is respectively connected to the first interrupt program address conversion circuit and the first program memory, the first decoding circuit is connected to the first addressing circuit, and the first decoding circuit is also respectively connected to the first register channel execution unit, the first data channel execution unit and the first global register execution unit. The first register channel execution unit, the first data channel execution unit and the first global register execution unit are respectively connected to the output channel and the global register.

5. The circuit for multi-core communication according to claim 4, characterized in that: The output channel includes a first register channel and a first data channel. The first register channel is used to receive control information from a first register channel execution unit, and the first data channel is used to receive data from a first data channel execution unit.

6. The circuit for multi-core communication according to claim 1, characterized in that: The sending unit includes an input channel, a second interrupt-to-program address conversion circuit, a program address queue, a second program execution circuit, a second program memory and a package sending circuit. The input channel is connected to the second interrupt-to-program address conversion circuit, the program address queue, the second program execution circuit and the package sending circuit in sequence. The second program execution circuit is also connected to the second program memory and the global register respectively.

7. The circuit for multi-core communication according to claim 6, characterized in that: The input channel includes a second register channel and a second data channel, the second register channel is used to receive control information that needs to be calculated from another core in the core, and the second data channel is used to receive data information that needs to be used from another core in the core.

8. The circuit for multi-core communication according to claim 6, characterized in that: The second program execution circuit includes a second addressing circuit, a second decoding circuit, a second register channel execution unit, a second data channel execution unit and a second global register execution unit. The second addressing circuit is respectively connected to the program address queue and the second program memory, the second decoding circuit is connected to the second addressing circuit, and the second decoding circuit is also respectively connected to the second register channel execution unit, the second data channel execution unit and the second global register execution unit. The second register channel execution unit, the second data channel execution unit and the second global register execution unit are respectively connected to the packaging and sending circuit and the global register.

9. A communication method using a circuit for multi-core communication as claimed in claim 1, characterized in that: The method uses the receiving unit to receive data, and the specific steps include: Step 11, the receiving unit classifies and caches the received out-of-core data, and the data is divided into control packets and data packets; Step 12, unpacking the control packet, generating an interrupt signal, and generating a corresponding program address according to the interrupt signal; Step 13, the receiving unit executes the corresponding program according to the program address, and the instructions in the program are decoded to generate corresponding control signals; In step 14, the receiving unit processes the data packet and the control signal obtained in step 13 and sends them to the core.

10. The communication method according to claim 9, characterized in that: The method uses the sending unit to send data, and the specific steps include: Step 21, the sending unit receives control information and data information in the core, the control information is the control information required by another AI core, and the data information is the data required for calculation by another AI core; Step 22, the control information triggers a corresponding interrupt signal, and the interrupt signal is converted into the first address of the program; Step 23, the sending unit executes the corresponding program according to the first address of the program, and the instructions in the program are decoded to generate corresponding control signals; In step 24, the sending unit packages the data information and the control signal obtained in step 23 and sends them out of the core.