Data broadcasting method, device, chip and medium of network on chip

文档序号:571906 发布日期:2021-05-18 浏览:5次 中文

阅读说明:本技术 片上网络的数据广播方法、装置、芯片及介质 (Data broadcasting method, device, chip and medium of network on chip ) 是由 何伟 沈杨书 于 2020-12-29 设计创作,主要内容包括:本发明实施例公开了一种片上网络的数据广播方法、装置、芯片及介质。该方法包括:接收数据包,其中所述数据包由目标节点发送至本节点;在判断出所述数据包为无目的地址的广播数据包时,根据本节点与所述目标节点在片上网络中的位置关系确定待转发节点;向所述待转发节点转发所述数据包。上述技术方案实现了无目的地址的广泛广播,提高了NOC的通信效率。(The embodiment of the invention discloses a data broadcasting method, a device, a chip and a medium of a network on chip. The method comprises the following steps: receiving a data packet, wherein the data packet is sent to a local node by a target node; when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and the target node in the network on chip; and forwarding the data packet to the node to be forwarded. The technical scheme realizes the wide broadcasting without destination addresses and improves the communication efficiency of the NOC.)

1. A data broadcasting method of a network on chip, comprising:

receiving a data packet; the data packet is sent to the local node by the target node;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and the target node in the network on chip;

and forwarding the data packet to the node to be forwarded.

2. The method according to claim 1, wherein determining the node to be forwarded according to the location relationship between the local node and the target node comprises:

if the node and the target node are in the same first direction of the network on chip, determining the other nodes except the target node and communicated with the node as nodes to be forwarded;

if the node and the target node are in the same second direction of the network on chip and are communicated with another node except the target node in the second direction, determining the other node as a node to be forwarded;

wherein the first direction and the second direction are perpendicular to each other.

3. A data broadcasting method of a network on chip, comprising:

receiving a data packet;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and a source node of the data packet in the network on chip;

and forwarding the data packet to the node to be forwarded.

4. The method according to claim 3, wherein determining the node to be forwarded according to the location relationship between the node and the source node of the data packet in the network on chip comprises:

if the positions of the node and the source node in the first direction of the network on chip are the same, determining other nodes except the target node and communicated with the node as nodes to be forwarded; the data packet is sent to the local node by the target node;

if the positions of the node and the source node in the first direction of the network on chip are different and the node is communicated with another node except the target node in the second direction, determining the other node as a node to be forwarded;

wherein the first direction and the second direction are perpendicular to each other.

5. The method according to claim 2 or 4, wherein the network on chip is of a 2D mesh topology, and the first direction and the second direction are predetermined.

6. The method according to claim 1 or 3, wherein forwarding the data packet to the node to be forwarded comprises:

and if the node to be forwarded is judged to be in the data packet broadcasting range, forwarding the data packet to the node to be forwarded.

7. The method of claim 6, wherein determining whether the node to be forwarded is within a packet broadcast range comprises:

and judging whether the node to be forwarded is in the data packet broadcasting range or not according to the source node address bit identifier and the broadcasting step bit identifier of the data packet.

8. The method of claim 7, wherein determining whether the node to be forwarded is within a packet broadcast range according to a source node address bit identifier and a broadcast step size bit identifier of a packet comprises:

determining the address bit identification range broadcasted by the data packet according to the source node address bit identification and the broadcasting step bit identification of the data packet;

and judging whether the node to be forwarded is in a data packet broadcasting range or not according to whether the address bit identification of the node to be forwarded falls into the address bit identification range or not.

9. The method of claim 1 or 3, wherein determining whether the packet is a broadcast packet without a destination address comprises:

and judging whether the data packet is a broadcast data packet without a destination address or not according to the broadcast bit identifier of the data packet.

10. The method according to claim 1 or 3, further comprising, after forwarding the data packet to the node to be forwarded:

and judging whether to reply information to the source node according to the source node address bit identifier of the data packet or not according to the source node state bit identifier of the data packet and the task state of the node.

11. The method of claim 10, wherein the source node status bit identification comprises at least one of: calculating force state identification and storing state identification.

12. The method of claim 1 or 3, further comprising:

and if the target data packet which needs to be broadcasted without the destination address exists, sending the target data packet to all nodes communicated with the node.

13. A data broadcasting apparatus of a network on chip, comprising:

the data packet receiving module is used for receiving data packets; the data packet is sent to the local node by the target node;

the first node to be forwarded determining module is used for determining a node to be forwarded according to the position relationship between the node and the target node in the network on chip when the data packet is judged to be a broadcast data packet without a destination address;

and the data packet forwarding module is used for forwarding the data packet to the node to be forwarded.

14. A data broadcasting method of a network on chip, comprising:

the data packet receiving module is used for receiving data packets;

a second node to be forwarded determining module, configured to determine a node to be forwarded according to a position relationship between a local node and a source node of the data packet in the network on chip when it is determined that the data packet is a broadcast data packet without a destination address;

and the data packet forwarding module is used for forwarding the data packet to the node to be forwarded.

15. A chip comprising a memory, a many-core processor, and a computer program stored on the memory and executable on the many-core processor, wherein each core in the many-core processor implements the method of any of claims 1-2, 5-12, or implements the method of any of claims 3-12 when executing the program.

16. A computer-readable storage medium having stored thereon a computer program, characterized in that the program, when executed by each core of a many-core processor, implements the method of any of claims 1-2, 5-12, or implements the method of any of claims 3-12.

Technical Field

The embodiment of the invention relates to the technical field of many-core chips, in particular to a data broadcasting method, a device, a chip and a medium of a network on chip.

Background

In many-core (including multi-core) Chip design, NOC (Network On Chip) is a common scheme for realizing communication between cores, wherein NOC performance is a key for improving performance of the whole Chip.

Currently, the data multicast scheme employed by NOCs in many-core chips is: when a Master data sending unit (Master) needs to multicast a data packet to a plurality of Slave data receiving units (Slave), multicast identification information is added in a data packet header to indicate a destination Slave data receiving unit corresponding to multicast, that is, address bit identifications of the plurality of Slave data receiving units are added in the data packet header. Therefore, when a data packet is received from the data receiving unit, the data packet needs to be parsed to determine whether the data packet needs to be subjected to header reassembly and forwarded, which further affects the communication efficiency of the NOC.

Disclosure of Invention

Embodiments of the present invention provide a method, an apparatus, a device, and a medium for data broadcasting in a network on chip, so as to implement wide broadcasting without a destination address and improve communication efficiency of an NOC.

In a first aspect, an embodiment of the present invention provides a data broadcasting method for a network on chip, including:

receiving a data packet; the data packet is sent to the local node by the target node;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and the target node in the network on chip;

and forwarding the data packet to the node to be forwarded.

In a second aspect, an embodiment of the present invention provides a data broadcasting method for a network on chip, including:

receiving a data packet;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and a source node of the data packet in the network on chip;

and forwarding the data packet to the node to be forwarded.

In a third aspect, an embodiment of the present invention further provides a data broadcasting apparatus for a network on chip, including:

the data packet receiving module is used for receiving data packets; the data packet is sent to the local node by the target node;

the first node to be forwarded determining module is used for determining a node to be forwarded according to the position relationship between the node and the target node in the network on chip when the data packet is judged to be a broadcast data packet without a destination address;

and the data packet forwarding module is used for forwarding the data packet to the node to be forwarded.

In a fourth aspect, an embodiment of the present invention further provides a data broadcasting apparatus for a network on chip, including:

the data packet receiving module is used for receiving data packets;

a second node to be forwarded determining module, configured to determine a node to be forwarded according to a position relationship between a local node and a source node of the data packet in the network on chip when it is determined that the data packet is a broadcast data packet without a destination address;

and the data packet forwarding module is used for forwarding the data packet to the node to be forwarded.

In a fifth aspect, an embodiment of the present invention further provides a chip, including a memory, a many-core processor, and a computer program that is stored in the memory and is executable on the many-core processor, where each core in the many-core processor implements the data broadcasting method of the network on chip according to any embodiment of the present invention when executing the program.

In a sixth aspect, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by each core in a many-core processor, implements the data broadcasting method for a network-on-chip according to any embodiment of the present invention.

In the technical scheme of the embodiment of the invention, when each node receives a data packet sent or forwarded by a target node in a network on chip, if the data packet is judged to be a broadcast data packet without a destination address, a node to be forwarded is determined according to the position relation of the node and the target node in the network on chip, and the data packet is forwarded to the node to be forwarded, so that the wide broadcast without the destination address is realized. Moreover, because the data packet is widely broadcast without a destination address, the data packet does not include address identification information of a destination node, so that the size of the data packet is reduced, and meanwhile, each node does not need to analyze after receiving the data packet and directly forwards the data packet, so that the communication efficiency of the NOC is improved.

Drawings

Fig. 1 is a flowchart of a data broadcasting method of a network on chip according to a first embodiment of the present invention;

fig. 2 is an exemplary diagram of a transmission direction of a data packet in a data broadcasting method of a network on chip according to an embodiment of the present invention;

fig. 3 is an exemplary diagram of the effect of data packet transmission in a data broadcasting method of a network on chip in an embodiment of the present invention;

fig. 4 is a flowchart of a data broadcasting method of a network on chip according to a second embodiment of the present invention;

fig. 5 is an exemplary diagram of a data packet broadcasting range in a data broadcasting method of a network on chip according to an embodiment of the present invention;

fig. 6 is a flowchart of a data broadcasting method of a network on chip according to a third embodiment of the present invention;

fig. 7 is a flowchart of a data broadcasting method of a network on chip according to a fourth embodiment of the present invention;

fig. 8 is a schematic structural diagram of a data broadcasting apparatus of a network on chip according to a fifth embodiment of the present invention;

fig. 9 is a schematic structural diagram of a data broadcasting apparatus of a network on chip according to a sixth embodiment of the present invention;

fig. 10 is a schematic diagram of a hardware structure of a chip in the seventh embodiment of the present invention.

Detailed Description

The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.

Before discussing exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although a flowchart may describe the operations (or steps) as a sequential process, many of the operations can be performed in parallel, concurrently or simultaneously. In addition, the order of the operations may be re-arranged. The process may be terminated when its operations are completed, but may have additional steps not included in the figure. The processes may correspond to methods, functions, procedures, subroutines, and the like.

Example one

Fig. 1 is a flowchart of a method for broadcasting data in a network on chip according to an embodiment of the present invention, where the present embodiment is applicable to a case where a network on chip in a many-core chip performs a broad broadcast without a destination address, and the method can be executed by a data broadcasting apparatus of a network on chip according to an embodiment of the present invention, where the apparatus can be implemented in a software and/or hardware manner, and can be generally integrated in a many-core chip.

As shown in fig. 1, the method for broadcasting data in a network on chip provided by this embodiment includes:

s110, receiving a data packet; and the data packet is sent to the node by the target node.

And the target node refers to any core node in the network on chip.

The target node may be a source node of the packet, or may be a relay node of the packet.

That is, the local node receives the data packet transmitted or forwarded by the target node.

Optionally, if there is a target data packet that needs to be broadcasted without a destination address, the target data packet is sent to all nodes connected to the node.

When the destination address-free broadcasting of the target data packet is needed, the node is the source node of the target data packet. The source node of the target data packet sends the target data packet to all nodes communicated with the node.

In a network on chip formed by a plurality of cores, the plurality of cores are typically arranged in rows and columns. Since the number of core nodes in each row and each column in the network on chip may be different, and the position of the source node in the network on chip is different, the number of nodes connected with the source node may be one, two, three or four. Regardless of the number of nodes connected to the source node, the source node sends the destination data packet that it needs to broadcast without destination address to all nodes connected to it.

And S120, when the data packet is judged to be the broadcast data packet without the destination address, determining the node to be forwarded according to the position relation of the node and the target node in the network on chip.

A broadcast packet, which refers to a packet with a broadcast transmission type; the broadcast data packet without the destination address refers to a data packet whose transmission type is broadcast and whose header does not include the destination node address identifier.

After each core node receives a data packet, it first determines the transmission type of the data packet, and determines whether the data packet is a broadcast data packet without a destination address, for example, a preset identifier may be used to determine whether the received data packet is a broadcast data packet without a destination address.

In an alternative embodiment, the data packet header includes a broadcast bit, and the broadcast bit identifies whether the data packet is a broadcast data packet without a destination address. For example, when the broadcast bit flag is 1, it indicates that the packet is a broadcast packet without a destination address; when the broadcast bit flag is 0, it indicates that the packet is not a broadcast packet without a destination address.

Correspondingly, the judging whether the data packet is a broadcast data packet without a destination address may specifically be: and judging whether the data packet is a broadcast data packet without a destination address or not according to the broadcast bit identifier of the data packet.

As shown in table 1, the data packet may include broadcast bits and data. After each core node receives the data packets sent by other core nodes, the broadcast bit identifier of the data packet is firstly obtained, and whether the broadcast bit identifier indicates that the data packet is a broadcast data packet without a destination address or not is judged.

Table 1 packet structure

Broadcasting station Data of

If the received data packet is not a broadcast data packet without a destination address, the data packet may be processed according to actual conditions, and this embodiment does not specifically limit the case where the data packet is not a broadcast data packet without a destination address.

If the received data packet is a broadcast data packet without a destination address, a node to be forwarded corresponding to the node needs to be determined according to the position relationship between the node and the target node in the network on chip.

For a node receiving a data packet, the node and a target node sending the data packet are located at adjacent positions in the network on chip, and may be adjacent vertically or horizontally, and the node may select different modes according to different adjacent relations to determine each node to be forwarded corresponding to the node.

As an optional implementation manner, determining a node to be forwarded according to the location relationship between the node and the target node may specifically be:

if the node and the target node are in the same first direction of the network on chip, determining the other nodes except the target node and communicated with the node as nodes to be forwarded; and if the node and the target node are in the same second direction of the network on chip and are communicated with another node except the target node in the second direction, determining the other node as the node to be forwarded. Wherein the first direction and the second direction are perpendicular to each other.

Optionally, the network on chip is a 2D mesh topology, and the first direction and the second direction are preset.

Since the plurality of cores are arranged in rows and columns in the network on chip, the row direction and the column direction of the network on chip can be taken as the first direction and the second direction. When the first direction is a row direction, the second direction is a column direction; when the first direction is a column direction, the second direction is a row direction. For example, in the network on chip shown in fig. 2, it is assumed that the first direction is a row direction and the second direction is a column direction.

Referring to fig. 2, assuming that the node n5 is the source node of the data packet, the source node transmits the data packet to all nodes connected thereto, i.e., to the node n1, the node n4, the node n6, and the node n 9.

And for each node, after receiving the data packet, judging the position relation between the node and a target node for sending the data packet in the network on chip. The position relationship between the local node and the target node in the network on chip can be judged according to the rank identification of the local node and the target node. When the row identifiers of the node and the target node are the same, the node and the target node are in the first direction of the network on chip, and when the column identifiers of the node and the target node are the same, the node and the target node are in the second direction of the network on chip.

And when the node and the target node are in the same first direction of the network on chip, taking the other nodes except the target node and communicated with the node as nodes to be forwarded. Referring to fig. 2, when the node n6 receives a data packet sent by the node n5, the nodes connected to the node n6 are the node n2, the node n5, the node n7, and the node n10, and when the node n6 determines that the node (the node n6) and the target node (the node n5) are in the first direction of the network on chip, the nodes connected to the node other than the target node (the node n5) are used as nodes to be forwarded, that is, the node n2, the node n7, and the node n10 are used as nodes to be forwarded corresponding to the node. Referring to fig. 2, when the node n4 receives a data packet sent by the node n5, the nodes connected to the node n4 are the node n0, the node n5, and the node n8, and the node n4 determines that the node (the node n4) and the target node (the node n5) are in the first direction of the network on chip, the nodes connected to the node other than the target node (the node n5) are used as nodes to be forwarded, that is, the node n0 and the node n8 are used as nodes to be forwarded corresponding to the node.

When the node and the target node are in the second direction of the network on chip, if the node is communicated with another node except the target node in the second direction, the other node is taken as a node to be forwarded. Referring to fig. 2, when the node n10 receives the data packet sent by the node n6, the nodes connected to the node n10 are the node n6, the node n9, the node n11, and the node n14, and the node n10 determines that the node (node n10) and the target node (node n6) are in the second direction of the network on chip, and determines that the node (node n10) is connected to the node n14 in addition to the target node (node n6) in the second direction, then the node n14 is taken as the node to be forwarded. Referring to fig. 2, when the node n1 receives a data packet sent by the node n5, the nodes connected to the node n1 are the node n0, the node n2, and the node n5, and the node n1 determines that the node (node n1) and the target node (node n5) are in the second direction of the network on chip, and also determines that the node (node n1) is not connected to other nodes except the target node (node n5) in the second direction, so that the node (node n1) does not have a node to be forwarded.

For each core node, the number of core nodes in each row and each column in the network on chip may also be different in view of the different positions of the core nodes in the network on chip, so the number of nodes to be forwarded corresponding to the node is also different.

S130, forwarding the data packet to the node to be forwarded.

And after determining each node to be forwarded corresponding to the node, forwarding the received data packet to each node to be forwarded corresponding to the node.

In the above optional embodiment of determining the node to be forwarded according to the position relationship between the local node and the target node, starting from the source node, each node in the first direction sends the data packet to the remaining directions except for the data packet receiving direction (if the node is not an edge node, the data packet is sent to the remaining three directions except for the data packet receiving direction), and each node in the second direction forwards the data packet to the next node along the data packet receiving direction. That is, the data packet propagates in the first direction of the network on chip only in the row where the source node is located (when the first direction is the row direction) or only in the column where the source node is located (when the first direction is the column direction). As shown in fig. 3, the entire propagation path of the packet from the source node 10 is in a fishbone shape, and there is no duplication problem in the propagation path of the packet, which can avoid waste of network on chip resources.

In the above technical solution, the transmission of the data packet is globally asynchronous, and can be applied to SNN (Spiking Neuron Networks, impulse neural Networks) asynchronous bionic simulation.

Further, as an optional implementation manner, forwarding the data packet to the node to be forwarded may specifically be: and if the node to be forwarded is judged to be in the data packet broadcasting range, forwarding the data packet to the node to be forwarded.

In this embodiment, the packet cannot be propagated endlessly through the network on chip, and a packet broadcast range can be set. After determining each node to be forwarded corresponding to the node, judging whether each node to be forwarded is in the data packet broadcasting range. If the node to be forwarded is in the data packet broadcasting range, forwarding the data packet to the node to be forwarded; and if the node to be forwarded is not in the data packet broadcasting range, the data packet is not forwarded to the node to be forwarded.

Optionally, the data packet carries a data packet broadcast range, and after determining each node to be forwarded corresponding to the node, the data packet broadcast range of the data packet is queried, and whether each node to be forwarded is within the data packet broadcast range is determined, if so, the data packet is forwarded, otherwise, the data packet is not forwarded.

In the technical scheme of the embodiment of the invention, when each node receives a data packet sent by a target node in a network on chip, if the data packet is judged to be a broadcast data packet without a destination address, a node to be forwarded is determined according to the position relation of the node and the target node in the network on chip, and the data packet is forwarded to the node to be forwarded, so that the wide broadcast without the destination address is realized. Moreover, because the data packet is widely broadcast without a destination address, the data packet does not include address identification information of a destination node, so that the size of the data packet is reduced, and meanwhile, each node does not need to analyze after receiving the data packet and directly forwards the data packet, so that the communication efficiency of the NOC is improved.

Example two

Fig. 4 is a flowchart of a data broadcasting method of a network on chip according to a second embodiment of the present invention. The embodiment is embodied on the basis of the foregoing embodiment, wherein the determining whether the node to be forwarded is within the packet broadcast range may specifically be:

and judging whether the node to be forwarded is in the data packet broadcasting range or not according to the source node address bit identifier and the broadcasting step bit identifier of the data packet.

As shown in fig. 4, the method for broadcasting data in a network on chip according to this embodiment includes:

s210, receiving a data packet; and the data packet is sent to the node by the target node.

S220, when the data packet is determined to be a broadcast data packet without a destination address, determining a position relationship between the node and the target node in the network on chip, if the data packet is in the first direction of the network on chip, executing S230, and if the data packet is in the second direction of the network on chip, executing S240.

Wherein the first direction and the second direction are perpendicular to each other.

And S230, taking the other nodes communicated with the node except the target node as nodes to be forwarded, and executing S250.

And S240, if the node is communicated with another node except the target node in the second direction, taking the other node as a node to be forwarded, and executing S250.

And S250, judging whether the node to be forwarded is in the data packet broadcasting range or not according to the source node address bit identifier and the broadcasting step bit identifier of the data packet, if so, executing S260, and if not, executing S270.

In this embodiment, as shown in table 2, the data packet may include a broadcast bit, a source node address bit, a broadcast step bit, and data. After each core node receives the data packets sent by other core nodes, the broadcast bit identifier of the data packet is firstly obtained, and when the broadcast bit identifier indicates that the data packet is a broadcast data packet without a destination address, whether the node to be forwarded corresponding to the node is in the broadcast range of the data packet can be judged according to the source node address bit identifier and the broadcast step bit identifier.

Table 2 packet structure

Broadcasting station Source node address bit Broadcast step size bit Data of

The address bit identifier is used to indicate a location of the node in the network on chip, and may be, for example, a rank and column location identifier, and may be identified in the form of (dx, dy), where dx may represent a row identifier and dy may represent a column identifier. The broadcast step bit flag is used to indicate the number of steps (i.e. hops) that the packet can propagate from the source node, for example, if the broadcast step is flag 3, it indicates that the packet can propagate three hops from the source node.

And acquiring the address bit identifier of any node to be forwarded corresponding to the node, and judging whether the address bit identifier of the node to be forwarded is in the data packet broadcasting range according to the source node address bit identifier and the broadcasting step bit identifier. For example, the step number between the node to be forwarded and the source node is determined according to the address bit identifier of the node to be forwarded and the address bit identifier of the source node, if the step number is less than or equal to the broadcast step bit identifier, it is determined that the node to be forwarded is within the data packet broadcast range, and the data packet is forwarded to the node to be forwarded, if the step number is greater than the broadcast step bit identifier, it is determined that the node to be forwarded is not within the data packet broadcast range, and the data packet does not need to be forwarded to the node to be forwarded.

As an optional implementation manner, judging whether the node to be forwarded is within a data packet broadcast range according to a source node address bit identifier and a broadcast step bit identifier of a data packet, which may specifically be:

determining the address bit identification range broadcasted by the data packet according to the source node address bit identification and the broadcasting step bit identification of the data packet; and judging whether the node to be forwarded is in a data packet broadcasting range or not according to whether the address bit identification of the node to be forwarded falls into the address bit identification range or not.

And determining each node within the step number range corresponding to the broadcast step bit identifier by taking the source node as a starting point according to the source node address bit identifier and the broadcast step bit identifier of the data packet, and taking the address bit identifiers of the nodes as the address bit identifier range of the data packet broadcast.

As shown in fig. 5, assuming that the broadcast step bit flag is 2, it is determined that the source node 10 is used as a starting point, and each node in the two-step range is used as each node in the dashed-line frame, and the address bit flags of these nodes are the address bit flag range for packet broadcast, that is, the dashed-line frame range is the broadcast range for packet.

S260, forwarding the data packet to the node to be forwarded.

S270, the data packet is not forwarded to the node to be forwarded.

Further, as an optional implementation manner, as shown in table 3, the data packet may include a broadcast bit, a source node address bit, a source node status bit, and data, where the status bit identifier is used to indicate a current status of the source node, and may be, for example, an idle status or an occupied status.

Table 3 packet structure

Broadcasting station Source node address bit Source node status bit Data of

Correspondingly, after forwarding the data packet to the node to be forwarded, the method further includes:

and judging whether to reply information to the source node according to the source node address bit identifier of the data packet or not according to the source node state bit identifier of the data packet and the task state of the node.

The task state of the node may refer to an execution state of a current task of the node, a situation of a task to be executed, and the like. The task state of the node is used for indicating whether the node needs to perform task coordination with other nodes.

And judging whether to reply information to the source node or not according to the source node state bit identifier of the data packet and the task state of the node, wherein the replied information is used for requesting the source node to perform task coordination. For example, when the status bit identifier of the source node indicates that the source node is idle and the task status of the node indicates that task coordination needs to be performed, information is replied to the source node according to the address bit identifier of the source node of the data packet to request the source node to perform task coordination, that is, the source node is requested to assist in performing the task of the node. For another example, if the status bit identifier of the source node indicates that the source node is occupied, no matter whether the task status of the node indicates that task coordination needs to be performed, information does not need to be replied to the source node, that is, a request for performing task coordination needs not to be made to the source node.

Optionally, the source node status bit identifier may also be a computing power status identifier. The computing power state identifier is used for indicating the computing power state of the node, and may be identified in the form of percentage, for example. Furthermore, whether to reply information to the source node can be judged according to the computing power state identification of the source node of the data packet and the task state (such as computing task state) of the node. For example, when the calculation power state identifier of the source node is smaller than the preset percentage threshold value and the task state of the node indicates that task coordination needs to be performed, information is replied to the source node according to the address bit identifier of the source node of the data packet to request the source node to perform task coordination.

Optionally, the source node status bit identifier may also be a storage status identifier. The storage status identifier is used to indicate the storage status of the node, and may be identified in the form of a percentage, for example. Furthermore, whether to reply information to the source node can be judged according to the storage state identification of the source node of the data packet and the task state (such as the storage task state) of the node. For example, when the storage state identifier of the source node is smaller than the preset percentage threshold value and the task state of the node indicates that task coordination needs to be performed, information is replied to the source node according to the address bit identifier of the source node of the data packet to request the source node to perform task coordination.

In addition to the above examples, the status bit identifier of the source node may further include other status identifiers, which are used to indicate performance statuses of some aspects of the node, and this embodiment is not limited in this respect.

The technical scheme provided by the embodiment can be applied to decentralized task scheduling, and the data, the source node address bit and the source node state bit in the data packet jointly represent source node information, so that the node receiving the data packet determines whether task coordination can be carried out with the source node according to the task state of the node, and task scheduling among core nodes in the network on chip is achieved.

Further, in an alternative embodiment, as shown in table 4, the data packet may include a broadcast bit, a source node address bit, a source node status bit, a broadcast step bit, and data.

Table 4 packet structure

Broadcasting station Source node address bit Source node status bit Broadcast step size bit Data of

In the embodiment, the limitation of the broadcast range of the data packet is realized by setting the broadcast step bit, and the endless propagation of the data packet is avoided, so that the decentralized task scheduling between the core nodes within a certain range of the network on chip is realized.

For those parts of this embodiment that are not explained in detail, reference is made to the aforementioned embodiments, which are not repeated herein.

EXAMPLE III

Fig. 6 is a flowchart of a data broadcasting method for a network on chip according to a third embodiment of the present invention, where this embodiment is applicable to a case where the network on chip in a many-core chip performs a broad broadcast without a destination address, and the method can be executed by a data broadcasting apparatus for a network on chip according to a third embodiment of the present invention, where the apparatus can be implemented in a software and/or hardware manner, and can be generally integrated in a many-core chip.

As shown in fig. 6, the method for broadcasting data in a network on chip provided by this embodiment includes:

s310, receiving a data packet; and the data packet is sent to the node by the target node.

And the target node refers to any core node in the network on chip.

The target node may be a source node of the packet, or may be a relay node of the packet. That is, the local node receives the data packet transmitted or forwarded by the target node.

Optionally, if there is a target data packet that needs to be broadcasted without a destination address, the target data packet is sent to all nodes connected to the node.

When the destination address-free broadcasting of the target data packet is needed, the node is the source node of the target data packet. The source node of the target data packet sends the target data packet to all nodes communicated with the node.

In a network on chip formed by a plurality of cores, the plurality of cores are typically arranged in rows and columns. Since the number of core nodes in each row and each column in the network on chip may be different, and the position of the source node in the network on chip is different, the number of nodes connected with the source node may be one, two, three or four. Regardless of the number of nodes connected to the source node, the source node sends the destination data packet that it needs to broadcast without destination address to all nodes connected to it.

S320, when the data packet is judged to be the broadcast data packet without the destination address, determining a node to be forwarded according to the position relation of the node and the source node of the data packet in the network on chip.

A broadcast packet, which refers to a packet with a broadcast transmission type; the broadcast data packet without the destination address refers to a data packet whose transmission type is broadcast and whose header does not include the destination node address identifier.

After each core node receives a data packet, it first determines the transmission type of the data packet, and determines whether the data packet is a broadcast data packet without a destination address, for example, a preset identifier may be used to determine whether the received data packet is a broadcast data packet without a destination address.

In an alternative embodiment, the data packet header includes a broadcast bit, and the broadcast bit identifies whether the data packet is a broadcast data packet without a destination address. For example, when the broadcast bit flag is 1, it indicates that the packet is a broadcast packet without a destination address; when the broadcast bit flag is 0, it indicates that the packet is not a broadcast packet without a destination address.

Correspondingly, the judging whether the data packet is a broadcast data packet without a destination address may specifically be: and judging whether the data packet is a broadcast data packet without a destination address or not according to the broadcast bit identifier of the data packet.

As shown in table 5, the data packet may include broadcast bits, source node address bits, and data. After each core node receives the data packets sent by other core nodes, the broadcast bit identifier of the data packet is firstly obtained, and whether the broadcast bit identifier indicates that the data packet is a broadcast data packet without a destination address or not is judged.

Table 5 packet structure

Broadcasting station Source node address bit Data of

If the received data packet is not a broadcast data packet without a destination address, the data packet may be processed according to actual conditions, and this embodiment does not specifically limit the case where the data packet is not a broadcast data packet without a destination address.

If the received data packet is a broadcast data packet without a destination address, a node to be forwarded corresponding to the node needs to be determined according to the position relationship between the node and a source node of the data packet in the network on chip.

For a node receiving a data packet, the node and a source node of the data packet may be located in the same row or in different rows or in the same column or in different columns in the on-chip network, and the node may select different ways according to different location relationships to determine each node to be forwarded corresponding to the node.

As an optional implementation manner, determining a node to be forwarded according to a position relationship between the node and a source node of the packet in the network on chip may specifically be:

if the positions of the node and the source node in the first direction of the network on chip are the same, determining other nodes except the target node and communicated with the node as nodes to be forwarded; the data packet is sent to the local node by the target node; if the positions of the node and the source node in the first direction of the network on chip are different and the node is communicated with another node except the target node in the second direction, determining the other node as a node to be forwarded; wherein the first direction and the second direction are perpendicular to each other.

Optionally, the network on chip is a 2D mesh topology, and the first direction and the second direction are preset.

Since the plurality of cores are arranged in rows and columns in the network on chip, the row direction and the column direction of the network on chip can be taken as the first direction and the second direction. When the first direction is a row direction, the second direction is a column direction; when the first direction is a column direction, the second direction is a row direction. For example, in the network on chip shown in fig. 2, it is assumed that the first direction is a row direction and the second direction is a column direction.

And for each node, after receiving the data packet, judging the position relation of the node and the source node of the data packet in the network on chip. The position relationship between the node and the source node in the network on chip can be judged according to the rank identification of the node and the source node. Taking the first direction as the row direction as an example, when the row identifiers of the node and the target node are the same, the positions of the node and the source node in the first direction of the network on chip are the same, and when the row identifiers of the node and the target node are different, the positions of the node and the source node in the first direction of the network on chip are different.

And when the positions of the node and the source node in the first direction of the network on chip are the same, taking the other nodes except the target node and communicated with the node as nodes to be forwarded. Referring to fig. 2, when the node n6 receives a packet sent by the node n5 (target node), and at this time, the target node sending the packet is also a source node, and when the node n6 determines that the row identifier of the node (node n6) is the same as that of the source node (node n5), that is, the position in the first direction of the network on chip is the same, the nodes other than the target node (node n5) and connected with the node n are used as nodes to be forwarded, that is, the node n2, the node n7, and the node n10 are used as nodes to be forwarded corresponding to the node n. Referring to fig. 2, when the node n7 receives a data packet sent by the node n6 (target node), where a source node of the data packet is n5, and the node n7 determines that a row identifier of the node (node n7) is the same as that of the source node (node n5), that is, a position of the node in the first direction of the network on chip is the same, the nodes other than the target node (node n6) and connected with the node n are used as nodes to be forwarded, that is, the node n3 and the node n11 are used as nodes to be forwarded corresponding to the node n.

And if the position of the node is different from that of the source node in the first direction of the network on chip in the second direction, the node is used as a node to be forwarded if the node is communicated with another node except the target node. Referring to fig. 2, when the node n10 receives a data packet sent by the node n6 (target node), where the source node of the data packet is n5, and the node n10 determines that the row identifiers of the node (node n10) and the source node (node n5) are different, that is, the positions of the node n10 in the first direction of the network on chip are different, and also determines that the node (node n10) in the second direction is in communication with the node n14 in addition to the target node (node n6), then the node n14 is taken as a node to be forwarded. Referring to fig. 2, when the node n1 receives a packet sent by the node n5 (target node), the target node sending the packet is also a source node, and the node n1 determines that the row identifier of the node (node n1) is different from that of the source node (node n5), that is, the position of the node in the first direction of the network on chip is different, and also determines that the node (node n1) is not communicated with other nodes except the target node (node n5) in the second direction, so that the node (node n1) does not have a node to be forwarded.

For each core node, the number of core nodes in each row and each column in the network on chip may also be different in view of the different positions of the core nodes in the network on chip, so the number of nodes to be forwarded corresponding to the node is also different.

S330, forwarding the data packet to the node to be forwarded.

And after determining each node to be forwarded corresponding to the node, forwarding the received data packet to each node to be forwarded corresponding to the node.

In the above optional embodiment of determining the node to be forwarded according to the position relationship between the node and the source node, starting from the source node, each node in the first direction sends the data packet to the remaining directions except for the data packet receiving direction (if the node is not an edge node, the data packet is sent to the remaining three directions except for the data packet receiving direction), and each node in the second direction forwards the data packet to the next node along the data packet receiving direction. That is, the data packet propagates in the first direction of the network on chip only in the row where the source node is located (when the first direction is the row direction) or only in the column where the source node is located (when the first direction is the column direction). As shown in fig. 3, the entire propagation path of the packet from the source node 10 is in a fishbone shape, and there is no duplication problem in the propagation path of the packet, which can avoid waste of network on chip resources.

In the technical scheme, the transmission of the data packet is globally asynchronous, and the method can be applied to SNN asynchronous bionic simulation.

Further, as an optional implementation manner, forwarding the data packet to the node to be forwarded may specifically be: and if the node to be forwarded is judged to be in the data packet broadcasting range, forwarding the data packet to the node to be forwarded.

In this embodiment, the packet cannot be propagated endlessly through the network on chip, and a packet broadcast range can be set. After determining each node to be forwarded corresponding to the node, judging whether each node to be forwarded is in the data packet broadcasting range. If the node to be forwarded is in the data packet broadcasting range, forwarding the data packet to the node to be forwarded; and if the node to be forwarded is not in the data packet broadcasting range, the data packet is not forwarded to the node to be forwarded.

Optionally, the data packet carries a data packet broadcast range, and after determining each node to be forwarded corresponding to the node, the data packet broadcast range of the data packet is queried, and whether each node to be forwarded is within the data packet broadcast range is determined, if so, the data packet is forwarded, otherwise, the data packet is not forwarded.

In the technical scheme of the embodiment of the invention, when each node receives a data packet sent by a target node in a network on chip, if the data packet is judged to be a broadcast data packet without a destination address, a node to be forwarded is determined according to the position relation of the node and a source node of the data packet in the network on chip, and the data packet is forwarded to the node to be forwarded, so that the wide broadcast without the destination address is realized. Moreover, because the data packet is widely broadcast without a destination address, the data packet does not include address identification information of a destination node, so that the size of the data packet is reduced, and meanwhile, each node does not need to analyze after receiving the data packet and directly forwards the data packet, so that the communication efficiency of the NOC is improved.

Example four

Fig. 7 is a flowchart of a data broadcasting method of a network on chip according to a fourth embodiment of the present invention. The embodiment is embodied on the basis of the foregoing embodiment, wherein the determining whether the node to be forwarded is within the packet broadcast range may specifically be:

and judging whether the node to be forwarded is in the data packet broadcasting range or not according to the source node address bit identifier and the broadcasting step bit identifier of the data packet.

As shown in fig. 7, the method for broadcasting data in a network on chip according to this embodiment includes:

s410, receiving a data packet; and the data packet is sent to the node by the target node.

S420, when the data packet is determined to be a broadcast data packet without a destination address, determining a position relationship between the node and the source node in the network on chip, if the positions in the first direction of the network on chip are the same, executing S430, and if the positions in the first direction of the network on chip are different, executing S440.

And S430, taking the other nodes communicated with the node except the target node as nodes to be forwarded, and executing S450.

And S440, if the node is communicated with another node except the target node in the second direction, taking the other node as a node to be forwarded, and executing S450.

Wherein the first direction and the second direction are perpendicular to each other.

S450, judging whether the node to be forwarded is in the data packet broadcasting range or not according to the source node address bit identification and the broadcasting step bit identification of the data packet, if so, executing S460, and if not, executing S470.

In this embodiment, as shown in table 2, the data packet may include a broadcast bit, a source node address bit, a broadcast step bit, and data. After each core node receives the data packets sent by other core nodes, the broadcast bit identifier of the data packet is firstly obtained, and when the broadcast bit identifier indicates that the data packet is a broadcast data packet without a destination address, whether the node to be forwarded corresponding to the node is in the broadcast range of the data packet can be judged according to the source node address bit identifier and the broadcast step bit identifier.

The address bit identifier is used to indicate a location of the node in the network on chip, and may be, for example, a rank and column location identifier, and may be identified in the form of (dx, dy), where dx may represent a row identifier and dy may represent a column identifier. The broadcast step bit flag is used to indicate the number of steps (i.e. hops) that the packet can propagate from the source node, for example, if the broadcast step is flag 3, it indicates that the packet can propagate three hops from the source node.

And acquiring the address bit identifier of any node to be forwarded corresponding to the node, and judging whether the address bit identifier of the node to be forwarded is in the data packet broadcasting range according to the source node address bit identifier and the broadcasting step bit identifier. For example, the step number between the node to be forwarded and the source node is determined according to the address bit identifier of the node to be forwarded and the address bit identifier of the source node, if the step number is less than or equal to the broadcast step bit identifier, it is determined that the node to be forwarded is within the data packet broadcast range, and the data packet is forwarded to the node to be forwarded, if the step number is greater than the broadcast step bit identifier, it is determined that the node to be forwarded is not within the data packet broadcast range, and the data packet does not need to be forwarded to the node to be forwarded.

As an optional implementation manner, judging whether the node to be forwarded is within a data packet broadcast range according to a source node address bit identifier and a broadcast step bit identifier of a data packet, which may specifically be:

determining the address bit identification range broadcasted by the data packet according to the source node address bit identification and the broadcasting step bit identification of the data packet; and judging whether the node to be forwarded is in a data packet broadcasting range or not according to whether the address bit identification of the node to be forwarded falls into the address bit identification range or not.

And determining each node within the step number range corresponding to the broadcast step bit identifier by taking the source node as a starting point according to the source node address bit identifier and the broadcast step bit identifier of the data packet, and taking the address bit identifiers of the nodes as the address bit identifier range of the data packet broadcast.

As shown in fig. 5, assuming that the broadcast step bit flag is 2, it is determined that the source node 10 is used as a starting point, and each node in the two-step range is used as each node in the dashed-line frame, and the address bit flags of these nodes are the address bit flag range for packet broadcast, that is, the dashed-line frame range is the broadcast range for packet.

S460, forwarding the data packet to the node to be forwarded.

S470, the data packet is not forwarded to the node to be forwarded.

Further, as an optional implementation manner, as shown in table 3, the data packet may include a broadcast bit, a source node address bit, a source node status bit, and data, where the status bit identifier is used to indicate a current status of the source node, and may be, for example, an idle status or an occupied status.

Correspondingly, after forwarding the data packet to the node to be forwarded, the method further includes:

and judging whether to reply information to the source node according to the source node address bit identifier of the data packet or not according to the source node state bit identifier of the data packet and the task state of the node.

The task state of the node may refer to an execution state of a current task of the node, a situation of a task to be executed, and the like. The task state of the node is used for indicating whether the node needs to perform task coordination with other nodes.

And judging whether to reply information to the source node or not according to the source node state bit identifier of the data packet and the task state of the node, wherein the replied information is used for requesting the source node to perform task coordination. For example, when the status bit identifier of the source node indicates that the source node is idle and the task status of the node indicates that task coordination needs to be performed, information is replied to the source node according to the address bit identifier of the source node of the data packet to request the source node to perform task coordination, that is, the source node is requested to assist in performing the task of the node. For another example, if the status bit identifier of the source node indicates that the source node is occupied, no matter whether the task status of the node indicates that task coordination needs to be performed, information does not need to be replied to the source node, that is, a request for performing task coordination needs not to be made to the source node.

Optionally, the source node status bit identifier may also be a computing power status identifier. The computing power state identifier is used for indicating the computing power state of the node, and may be identified in the form of percentage, for example. Furthermore, whether to reply information to the source node can be judged according to the computing power state identification of the source node of the data packet and the task state (such as computing task state) of the node. For example, when the calculation power state identifier of the source node is smaller than the preset percentage threshold value and the task state of the node indicates that task coordination needs to be performed, information is replied to the source node according to the address bit identifier of the source node of the data packet to request the source node to perform task coordination.

Optionally, the source node status bit identifier may also be a storage status identifier. The storage status identifier is used to indicate the storage status of the node, and may be identified in the form of a percentage, for example. Furthermore, whether to reply information to the source node can be judged according to the storage state identification of the source node of the data packet and the task state (such as the storage task state) of the node. For example, when the storage state identifier of the source node is smaller than the preset percentage threshold value and the task state of the node indicates that task coordination needs to be performed, information is replied to the source node according to the address bit identifier of the source node of the data packet to request the source node to perform task coordination.

In addition to the above examples, the status bit identifier of the source node may further include other status identifiers, which are used to indicate performance statuses of some aspects of the node, and this embodiment is not limited in this respect.

The technical scheme provided by the embodiment can be applied to decentralized task scheduling, and the data, the source node address bit and the source node state bit in the data packet jointly represent source node information, so that the node receiving the data packet determines whether task coordination can be carried out with the source node according to the task state of the node, and task scheduling among core nodes in the network on chip is achieved.

Further, in an alternative embodiment, as shown in table 4, the data packet may include a broadcast bit, a source node address bit, a source node status bit, a broadcast step bit, and data.

In the embodiment, the limitation of the broadcast range of the data packet is realized by setting the broadcast step bit, and the endless propagation of the data packet is avoided, so that the decentralized task scheduling between the core nodes within a certain range of the network on chip is realized.

For those parts of this embodiment that are not explained in detail, reference is made to the aforementioned embodiments, which are not repeated herein.

EXAMPLE five

Fig. 8 is a schematic structural diagram of a network-on-chip data broadcasting apparatus according to a fifth embodiment of the present invention, which is applicable to a case where a network-on-chip in a many-core chip performs a broad broadcast without a destination address. As shown in fig. 8, the apparatus includes: a packet receiving module 510, a first node to be forwarded determining module 520 and a packet forwarding module 530. Wherein the content of the first and second substances,

a packet receiving module 510, configured to receive a packet; the data packet is sent to the local node by the target node;

a first node-to-be-forwarded determining module 520, configured to determine a node to be forwarded according to a position relationship between the node and the target node in the network on chip when it is determined that the data packet is a broadcast data packet without a destination address;

a packet forwarding module 530, configured to forward the packet to the node to be forwarded.

In the technical scheme of the embodiment of the invention, when each node receives a data packet sent by a target node in a network on chip, if the data packet is judged to be a broadcast data packet without a destination address, a node to be forwarded is determined according to the position relation of the node and the target node in the network on chip, and the data packet is forwarded to the node to be forwarded, so that the wide broadcast without the destination address is realized. Moreover, because the data packet is widely broadcast without a destination address, the data packet does not include address identification information of a destination node, so that the size of the data packet is reduced, and meanwhile, each node does not need to analyze after receiving the data packet and directly forwards the data packet, so that the communication efficiency of the NOC is improved.

Optionally, the first node to be forwarded determining module 520 is specifically configured to determine, if the node and the target node are in the same first direction of the network on chip, that the other nodes except the target node and communicated with the node are nodes to be forwarded; if the node and the target node are in the same second direction of the network on chip and are communicated with another node except the target node in the second direction, determining the other node as a node to be forwarded; wherein the first direction and the second direction are perpendicular to each other.

Optionally, the network on chip is a 2D mesh topology, and the first direction and the second direction are preset.

Optionally, the packet forwarding module 530 is specifically configured to forward the packet to the node to be forwarded if it is determined that the node to be forwarded is within the packet broadcasting range.

Further, the data packet forwarding module 530 is specifically configured to determine whether the node to be forwarded is within a data packet broadcasting range according to the source node address bit identifier and the broadcasting step bit identifier of the data packet.

Further, the data packet forwarding module 530 is specifically configured to determine an address bit identifier range broadcasted by the data packet according to the source node address bit identifier and the broadcast step bit identifier of the data packet; and judging whether the node to be forwarded is in a data packet broadcasting range or not according to whether the address bit identification of the node to be forwarded falls into the address bit identification range or not.

Optionally, the first node-to-be-forwarded determining module 520 is specifically configured to determine whether the data packet is a broadcast data packet without a destination address according to the broadcast bit identifier of the data packet.

Optionally, the apparatus further comprises: and the task coordination module is used for judging whether to reply information to the source node according to the source node address bit identifier of the data packet or not according to the source node state bit identifier of the data packet and the task state of the node after forwarding the data packet to the node to be forwarded.

Optionally, the source node status bit identifier at least includes one of: calculating force state identification and storing state identification.

Optionally, the apparatus further comprises: and the data packet sending module is used for sending the target data packet to all nodes communicated with the node if the target data packet needing no destination address broadcasting exists.

The data broadcasting device of the network on chip can execute the data broadcasting method of the network on chip provided by any embodiment of the invention, and has the corresponding functional modules and the beneficial effects of the executed data broadcasting method of the network on chip.

EXAMPLE six

Fig. 9 is a schematic structural diagram of a network-on-chip data broadcasting apparatus according to a sixth embodiment of the present invention, which is applicable to a case where a network-on-chip in a many-core chip performs a broad broadcast without a destination address. As shown in fig. 9, the apparatus includes:

a packet receiving module 610, configured to receive a packet;

a second node-to-be-forwarded determining module 620, configured to determine a node to be forwarded according to a position relationship between the node and a source node of the data packet in the network on chip when it is determined that the data packet is a broadcast data packet without a destination address;

a packet forwarding module 630, configured to forward the packet to the node to be forwarded.

In the technical scheme of the embodiment of the invention, when each node receives a data packet sent by a target node in a network on chip, if the data packet is judged to be a broadcast data packet without a destination address, a node to be forwarded is determined according to the position relation of the node and a source node of the data packet in the network on chip, and the data packet is forwarded to the node to be forwarded, so that the wide broadcast without the destination address is realized. Moreover, because the data packet is widely broadcast without a destination address, the data packet does not include address identification information of a destination node, so that the size of the data packet is reduced, and meanwhile, each node does not need to analyze after receiving the data packet and directly forwards the data packet, so that the communication efficiency of the NOC is improved.

Optionally, the second node-to-be-forwarded determining module 620 is specifically configured to determine, if the positions of the node and the source node in the first direction of the network on chip are the same, the other nodes, except the target node, which are communicated with the node, as nodes-to-be-forwarded; the data packet is sent to the local node by the target node; if the positions of the node and the source node in the first direction of the network on chip are different and the node is communicated with another node except the target node in the second direction, determining the other node as a node to be forwarded; wherein the first direction and the second direction are perpendicular to each other.

Optionally, the network on chip is a 2D mesh topology, and the first direction and the second direction are preset.

Optionally, the packet forwarding module 630 is specifically configured to forward the packet to the node to be forwarded if it is determined that the node to be forwarded is within the packet broadcasting range.

Further, the data packet forwarding module 630 is specifically configured to determine whether the node to be forwarded is within a data packet broadcasting range according to the source node address bit identifier and the broadcasting step bit identifier of the data packet.

Further, the data packet forwarding module 630 is specifically configured to determine an address bit identifier range broadcasted by the data packet according to the source node address bit identifier and the broadcast step bit identifier of the data packet; and judging whether the node to be forwarded is in a data packet broadcasting range or not according to whether the address bit identification of the node to be forwarded falls into the address bit identification range or not.

Optionally, the second node-to-be-forwarded determining module 620 is specifically configured to determine, according to the broadcast bit identifier of the data packet, whether the data packet is a broadcast data packet without a destination address.

Optionally, the apparatus further comprises: and the task coordination module is used for judging whether to reply information to the source node according to the source node address bit identifier of the data packet or not according to the source node state bit identifier of the data packet and the task state of the node after forwarding the data packet to the node to be forwarded.

Optionally, the source node status bit identifier at least includes one of: calculating force state identification and storing state identification.

Optionally, the apparatus further comprises: and the data packet sending module is used for sending the target data packet to all nodes communicated with the node if the target data packet needing no destination address broadcasting exists.

The data broadcasting device of the network on chip can execute the data broadcasting method of the network on chip provided by any embodiment of the invention, and has the corresponding functional modules and the beneficial effects of the executed data broadcasting method of the network on chip.

EXAMPLE seven

Fig. 10 is a schematic diagram of a hardware structure of a chip according to a seventh embodiment of the present invention. As shown in fig. 10, the chip includes:

one or more many-core processors 710, one many-core processor 710 being exemplified in FIG. 10;

and a memory 720.

The many-core processor 710 and the memory 720 in the chip can be connected through a bus or in other ways, and the bus connection is taken as an example in FIG. 10.

The memory 720, which is a non-transitory computer-readable storage medium, may be used to store a software program, a computer-executable program, and program instructions corresponding to a data broadcasting method of a network on chip in an embodiment of the present invention, including:

receiving a data packet sent by a target node;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and the target node in the network on chip;

and forwarding the data packet to the node to be forwarded.

Alternatively, the program instruction corresponding to the data broadcasting method of the network on chip as in the embodiment of the present invention includes:

receiving a data packet;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and a source node of the data packet in the network on chip;

and forwarding the data packet to the node to be forwarded.

Each core in the many-core processor 710 executes various functional applications and data processing of the chip by running software program instructions stored in the memory 720, that is, implements a network-on-chip data broadcasting method in any of the above-described method embodiments.

The memory 720 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to use of the chip, and the like. Further, the memory 720 may include high speed random access memory, and may also include non-transitory memory, such as at least one magnetic disk storage device, flash memory device, or other non-transitory solid state storage device.

Example eight

An eighth embodiment of the present invention further provides a storage medium containing computer-executable instructions, where the computer-executable instructions are executed by each core in a many-core processor to implement a method for broadcasting data in a network on chip, where the method includes:

receiving a data packet sent by a target node;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and the target node in the network on chip;

and forwarding the data packet to the node to be forwarded.

Or a data broadcasting method for implementing a network on chip, the method comprising:

receiving a data packet;

when the data packet is judged to be a broadcast data packet without a destination address, determining a node to be forwarded according to the position relation of the node and a source node of the data packet in the network on chip;

and forwarding the data packet to the node to be forwarded.

Optionally, the computer-executable instruction may be further used to implement a technical solution of a network-on-chip data broadcasting method provided by any embodiment of the present invention when executed by each core in the many-core processor.

From the above description of the embodiments, it is obvious for those skilled in the art that the present invention can be implemented by software and necessary general hardware, and certainly, can also be implemented by hardware, but the former is a better embodiment in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which can be stored in a computer-readable storage medium, such as a floppy disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a FLASH Memory (FLASH), a hard disk or an optical disk of a computer, and includes instructions for enabling a chip to execute the method according to the embodiments of the present invention.

It should be noted that, in the embodiment of the data broadcasting apparatus of the network on chip, each unit and each module included in the embodiment are only divided according to functional logic, but are not limited to the above division as long as the corresponding function can be realized; in addition, specific names of the functional units are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present invention.

It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

24页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种PON系统报文镜像方法及PON系统

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!