Open SeanNijjar opened 1 month ago
Sounds good. Can you clarify what these mean w.r.t packet_queue_receiver_t
template <RemoteQueueCoreType tx_q_core_type, RemoteQueueCoreType rx_q_core_type> struct packet_queue_receiver_t
Is tx_q_core the sender to packet_queue_receiver_t and rx_q_core a receiver (downstream) of packet_queue_receiver_t
Does it make sense to use upstream/downstream instead of tx/rx?
Thanks for the questions. I will produce some diagrams to make it clearer.
For the type names yes we can change it. For receiver it could be upstream_core_type and my_core_type where the receiver interface implements the destination side of a queue writer reader connection. For example, if a worker writes into a queue on Ethernet, the receiver interface would be implemented on the Ethernet core. If that Ethernet core further forwarded data, it would also implement a writer interface. (At that point it may make sense to have a fused forwarder implementation: input queue, output queue, forwarder queue)
I was thinking of something like this:
Although thinking about it more, it probably makes sense to have 3 types of packet_queue interfaces: sender, receiver, forwarder which start startpoints (e.g. centers or workers), endpoints (final center or workers), and hops along a route, respectively.
Restructure the
packet_queue
structures from fast dispatch for reuse in EDM. Along the way, cleanup the interfaces so the queue is more amenable to optimization and specialization by sender/receiver configurations (e.g. core type and transport medium - noc or ethernet).Queue Restructure
I want to restructure the packet queue for this task for a handful of reasons:
eth_send_packet
is buried too low level for the main loops to manage appropriately. For optimized implementations on ethernet, the queue reader/writer interfaces need to be thinner so they can more easily do things like check for txcmdq fullness and wait/queue up the eth commands for later when the cmdq has space 5) We need these APIs formalized anyways to provide a consistent and modular interface for user kernels (e.g. CCLs) 6) Remove stream register usage (another inflexibility whose benefit is dubious)High Level Design (Queue Interfaces)
Define remote endpoint type
Define the reader interface:
Define the writer interface - analogous to reader above except write side
Implement the
packet_queue
containerThis will be a basic container that only does pointer update management, returns emptiness/fullness, etc.