3.3. NoC Switches
Each core is generally associated with a switch, which is composed of multiple sets
of input and output queues attached to a crossbar interconnect. Each output queue is
mapped to input queues of neighboring switches to support the flow of flits. In wormhole
networks, header packets create mappings of output queues to input queues as they
traverse the network. The mappings are revoked as a switch services the tail flit of
the corresponding packet. To enable the detection of open input ports, output ports
maintain a set of N transfer credits. When a flit of data is placed into an output queue,
a credit is consumed. When that credit is transferred to the subsequent input port,
either between the core and switch or between two separate switches, the credit is
refunded. Credits are checked when an internal mapping is established between an
input queue and an output queue—that is, when a connection is established through
wormhole routing. If the output queue is unable to receive any data due to a lack of
credits, no additional output data may be transferred until credits are refunded.
Figure 2(b) depicts an example where core 1 sends a message to core 4. Using XY
dimension-ordered routing, this message passes from core 1’s output queue to switch
1’s East output queue. Each post decrements a credit when the flit of data enters the
queue. Switch 1’s East output queue will then transfer to switch 2’s input queue, and
switch 2 will set the cross bar to transfer the packet to switch 2’s South output queue,
if enough credits exist in the South output queue. Subsequently, switch 4’s North input
queue will receive the flits from switch 2’s South output queue and refund credits.
Switch 4 will then create a mapping of the North input queue onto the core’s input
queue. Incoming flits into core 4’s input queue will be automatically buffered in a
larger SRAM FIFO buffer. Once this buffer fills up, no more data can be transferred
and corresponding attempts result in blocking at the API.