Handshakes and Credit-Based Flow Control
The protocols that move data between blocks — valid/ready, four-phase and two-phase req/ack, and credit-based flow control — and how to write assumptions, assertions and conservation invariants for them. Ends with a lab that hunts a lost credit.
What you will learn
- Split protocol rules into assumptions (what the neighbour promises) and assertions (what your block promises).
- Write the standard valid/ready rules and recognise legal and illegal waveforms.
- Check four-phase and two-phase req/ack handshakes.
- Explain credit-based flow control and why it suits long, pipelined links.
- Prove credit conservation, no overflow and no deadlock with auxiliary code.
Lessons
- 14.1Handshakes: who promises whatProducers, consumers, and the assume/assert split.
- 14.2Valid/ready: the rules and the waveformsHold, stability, transfer, independence and no X.
- 14.3Four-phase and two-phase req/ackReturn-to-zero handshakes and toggle (transition) signalling.
- 14.4Credit-based flow control explainedCounting free slots instead of asking "are you ready?" every cycle.
- 14.5Formal properties for a credit linkOverdraft, overflow, conservation, deadlock and liveness.
- 14.6Lab: hunting a lost creditA credit link with a one-line priority bug that simulation rarely notices.
- ✎Chapter quiz (5 questions)