Expand description
The on-chip fabric of the one-card cluster: what RoCE would carry between replicas, as an RHDL experiment (D2).
§What it is, and what it is not
Each replica sends RDMA writes as a meta beat (opcode, QPN, addresses,
length) and data beats, exactly as it would to the RoCE stack. The fabric
turns each write into AXI writes into the destination replica’s HBM
region. It reproduces the parts of RoCE the source audit established
(Atlas, docs/rhdl_ubft-roce.md) and nothing more:
- The host-programmed connection table. Replica
i’s local QPN(N−1)·i + r(r < N − 1) reaches peerj = rifr < i, elser + 1. Any other QPN has no entry on replicai: it is not delivered and counts asunmapped. A QPN that has an entry is delivered to that entry’s peer even when the sender meant another. Upstream’s kernel indexes QPNs asid·N + j; withupstream_qpnsset (the replay of upstream’s sends) the fabric counts every write whose actual peer differs from that meaning asmisrouted. - No loopback. No QPN reaches the sender itself.
- Packet boundaries. A write takes data beats up to the first
tlast. Beats pastlenbytes beforetlastare not written and count asoversize; atlastbeforelenbytes ends the write short (short_packet);len = 0writes nothing (zero_length); a write past the destination region, or whose HBM address would wrap 64 bits, counts asout_of_boundsand is not written. A runtimenoutside2..=16or anid ≥ nmakes every descriptorbad_config(nothing is delivered). The final beat’s strobe covers only the bytes left oflen. - Physical lanes. AXI write lanes belong to the 64-byte-aligned
address, so the payload stream is re-aligned onto lines: a write at
raddrstartsraddr mod 64bytes into its first line, each line takes the previous beat’s tail and the current beat’s head (realign), and one extra line carries the last beat’s tail when the shift pushes it past. Shifts are in 4-byte steps (rhdl_ubft addresses words), so araddrthat is not a multiple of 4 is refused (misaligned), and a region base must be 64-byte aligned (elsebad_config).
§Receive authorization
A mapped write is then checked as a whole, before any AXI write, by
Atlas’s authorize_write: the trusted ingress (this link’s id), the
destination, the requested interval and W trusted WriteWindows.
A rejected descriptor is drained without writing and counted once, by
the guard’s reason: membership (bad_config), empty (zero_length),
outside the region or wrapping (out_of_bounds), or no window
(unauthorized). The windows are configuration and change only while
the fabric is drained.
What the audit left unknown is a labelled assumption of this model, not
a claim about RoCE: the source is the fabric port the write came in on
(never a payload field); one write at a time per source, and the next
starts only when every byte of the previous one is acknowledged by HBM
(B responses), which keeps each source’s writes in order and makes a
later flag write land after its payload. That B response is this
model’s commit point, not a statement about when real RDMA data is
visible. A fixed latency (cycles before a write starts) stands in for
the network.
Structs§
- Fabric
Link - One source link (see the module docs).
- Link
Counters - Error and progress counters of one source link.
- LinkIn
- One source link’s inputs.
- LinkOut
- One source link’s outputs.
Functions§
- fabric_
link_ kernel - The link’s logic.
- realign
- One 64-byte line of a re-aligned write: the payload stream shifted up by
sw4-byte words, from the previous beat’s tail and the current beat’s head (sw = 0: the current beat as it is). - realign_
keep - The byte enables of a re-aligned line, shifted like
realign. - strobe
- The strobe of a beat with
leftbytes still to write.