Expand description
Handshake primitives of the spatial IR in silicon: the bounded FIFO (Handshake::Fifo), the counting
semaphore (Handshake::Semaphore’s ready counter / valid flag), the arrive-all barrier
(Handshake::Barrier) and the one-writer multicast bus (a Group). Each emitter is paired with a trace
testbench whose expected values come from the Rust model of the same primitive, and the FIFO’s bound is
proven by k-induction with our own certified SAT — the sequential analogue of the combinational proofs
the datapaths carry.
emit_fifo_verilog("chan_fifo", 8, 32) is byte-identical to chan_rtl::emit_chan_fifo_verilog(): the
language Pipe IS the parameterized FIFO at its recorded parameters (locked).
Functions§
- emit_
barrier_ trace_ testbench - Staggered arrivals over several rounds:
releasedpulses exactly once per round, on the cycle after the last party arrives, and never otherwise. - emit_
barrier_ verilog - An arrive-all barrier over
nparties: arrivals are sticky; the cycle every party has arrived,releasedpulses for one cycle and the barrier re-arms. - emit_
fifo_ trace_ testbench - Scripted push/pop trace against a
VecDequemodel: every cycle the DUT’spushed,popped,countand (when popped)doutmust equal the model’s. PrintsPASS:or the first mismatch. - emit_
fifo_ verilog - A bounded FIFO of
depthentries ofwidthbits: FIFO order,fullrefuses a sender,emptyrefuses a receiver,doutis the oldest buffered value. Power-of-two depths wrap their pointers naturally; other depths compare explicitly. - emit_
mcast_ bus_ trace_ testbench - Sends, idles and back-to-back sends: every receiver’s
pushanddoutfollow the writer one cycle later. - emit_
mcast_ bus_ verilog - A one-writer multicast bus: on
send, the next cycle every one of thenreceivers seespushwith the samedout— the multicast landing of aGroup(each receiver pushes it into its own FIFO). - emit_
semaphore_ trace_ testbench - Scripted set/inc/threshold trace against the Rust model of the semaphore.
- emit_
semaphore_ verilog - A counting semaphore of
widthbits:setloadsset_val(the owner’s reset), elseincaddsinc_n(a remote increment);geiscount >= thresh— the set / increment / wait-threshold discipline every dataflow mesh’s semaphores implement. - fifo_
bound_ certified 0 ≤ cnt ≤ depthfor EVERY push/pop stream, by k-induction over the FIFO’s count register exactly as the RTL computes it (popped = pop ∧ cnt≠0,pushed = push ∧ cnt≠depth).