Skip to content

AMBA AHB · Module 2

Pipelined Operation

How AHB overlaps the address and data phases of consecutive transfers to keep the shared bus busy every cycle — the staircase, what creates pipeline bubbles, and why pipelining is throughput, not concurrency.

You now know both phases of a single AHB transfer. This chapter shows what happens when transfers come back to back: their phases overlap, and that overlap is the pipeline that gives AHB its throughput. We met the idea informally in the mental-model chapter ("the next request is lined up while the current one is carried"); now we see it at signal level, watch a stream of transfers flow through the pipe, and identify exactly what stalls it. Crucially, we will pin down what pipelining is not — it is not concurrency — because conflating the two is the single most common AHB misconception, and the distinction is the line between AHB and AXI.

1. What Is It?

Pipelined operation is AHB running consecutive transfers so that each transfer's data phase overlaps the next transfer's address phase. Because the two phases use different parts of the bus (address/control vs data), they can happen in the same cycle for different transfers — so while transfer A's data is moving, transfer B's address is already being presented.

A staircase diagram of three transfers A, B, C, each with an address phase then a data phase, staggered so each data phase overlaps the next address phase, with the overlapping cycles highlighted.
Figure 1 — the pipeline as a staircase. Each transfer (A, B, C) has an address phase then a data phase, staggered by one cycle. In T1 the bus carries data A and address B at once; in T2, data B and address C. After the first transfer fills the pipe, one transfer completes every cycle.

The result is a steady cadence: after the very first transfer "fills the pipe," the bus completes one transfer per cycle, even though each individual transfer still takes two phases. This is dramatically more throughput than an unpipelined bus, which would finish each transfer completely — address and data — before starting the next, roughly halving the rate.

2. Why Does It Exist?

Pipelining exists to defeat the dead time that an unpipelined two-phase transfer would otherwise create.

Imagine AHB without pipelining. Each transfer would present its address (one cycle), then move its data (one cycle), then — only then — let the next transfer present its address. Every transfer would cost two cycles, and during each transfer's address phase the data bus would sit idle, and during its data phase the address bus would sit idle. Half the bus would be wasted at every moment. For a bus whose whole purpose is to move real bandwidth, that waste is unacceptable.

The fix is to notice that the idle halves can be filled: while transfer A is in its data phase (data bus busy, address bus free), transfer B can use the free address bus for its address phase. Overlap the phases and both halves of the bus are working every cycle. That is the entire reason the address phase was made separate in the first place — recall from chapter 2.3 that the separation was needed for decode time, but its bonus payoff is exactly this overlap. One design decision (split the transfer into two phases) bought two things: time to decode, and the ability to pipeline.

So pipelining exists because a two-phase transfer naturally leaves each half of the bus free half the time, and overlapping consecutive transfers fills that freedom with useful work. It is the mechanism that turns "two cycles per transfer" into "one transfer per cycle" — the difference between a sluggish bus and a high-performance one, at zero extra wires.

3. Mental Model

Model the pipeline as a two-stage assembly line.

Station 1 is "describe the order" (the address phase); station 2 is "fulfil the order" (the data phase). An item moves from station 1 to station 2 after one cycle. The trick of any assembly line is that while item A is at station 2 being fulfilled, item B is already at station 1 being described — both stations are working at once. After the line fills, a finished item rolls off station 2 every cycle, even though each item spent time at both stations.

That is exactly AHB: the address phase is station 1, the data phase is station 2, and consecutive transfers march through one cycle apart. Watch a real stream of three writes flowing through the pipe:

Three pipelined transfers — one completes per cycle

5 cycles
Across five cycles, HTRANS is NONSEQ for three transfers in T0, T1, T2 then IDLE; HADDR shows A, B, C in T0, T1, T2; HWDATA shows DA in T1, DB in T2, DC in T3; HREADY stays high, so each transfer's data phase overlaps the next transfer's address phase.addr Adata A / addr Bdata B / addr Cdata A moves while address B is issueddata A moves while add…data B moves while address C is issueddata B moves while add…HCLKHTRANSNONSEQNONSEQNONSEQIDLEIDLEHADDRABCCCHWDATA0DADBDCDCHREADYt0t1t2t3t4
Figure 2 — three pipelined writes. In each cycle the address phase of one transfer overlaps the data phase of the previous one: T0 issues address A; T1 moves data A while issuing address B; T2 moves data B while issuing address C; T3 moves data C. HREADY stays high throughout, so one transfer completes every cycle — the pipeline at full cadence.

The model's payoff is the cadence: address leads data by one cycle, and transfers march one cycle apart, so the bus is never idle between them. If you can see the staircase, you can read any pipelined AHB capture — and you can spot instantly when a bubble breaks the cadence.

4. Real Hardware Perspective

In hardware, the pipeline is a consequence of registering: the address-phase information is captured at a clock edge and used during the next cycle's data phase, while the next address is already being presented.

Concretely, the address and control a manager drives in one cycle are sampled by the subordinate and used to perform the data movement in the following cycle. That one-cycle offset between "address sampled" and "data moved" is the pipeline stage. Because it is built from ordinary edge-triggered registers, it is cheap — pipelining costs essentially nothing beyond the registers a synchronous design already has. This is why AHB gets its throughput "for free": the two-phase structure plus normal synchronous design is a pipeline.

The interaction with HREADY is the key hardware subtlety. HREADY does not just gate the data phase of the current transfer — because the pipeline advances only when the current beat completes, HREADY low stalls the entire pipeline. When a subordinate inserts a wait state, the current data phase cannot finish, so the next transfer's address phase cannot become the current data phase — the whole staircase freezes for that cycle. This is why the data-phase and pipeline chapters are joined at the hip: HREADY is simultaneously the data-phase completion gate and the pipeline-advance enable.

A second hardware reality is the address-hold-during-stall rule from chapter 2.3, now seen in pipeline context. When HREADY is low, not only must the current transfer hold its data, but the next transfer's address phase — already being presented — must also be held stable, because it has not yet been consumed. The whole pipeline holds its state for the wait cycle and resumes when HREADY returns. The pipeline does not lose its contents during a stall; it pauses.

5. System Architecture Perspective

At the system level, pipelining is what lets a shared bus still deliver respectable throughput — and understanding it sharpens exactly where AHB's ceiling sits.

The pipeline means a single AHB master streaming transfers to a fast subordinate achieves close to one transfer per cycle — genuinely high throughput for a cheap shared bus. This is why AHB is "good enough" for the embedded backbone: a processor fetching a run of instructions, or a DMA engine moving a block, gets near-peak bandwidth as long as the pipeline stays full. The system-level performance question therefore becomes "how full does the pipeline stay?" — which is the same as "how often do bubbles occur?"

Three cards describing the causes of pipeline bubbles — wait state, IDLE transfer, and BUSY transfer — each with its cause, and a note that smooth back-to-back transfers avoid bubbles.
Figure 3 — what creates a bubble. A wait state (subordinate holds HREADY low) freezes the pipeline; an IDLE transfer type means the manager has nothing to issue, leaving an empty address slot; a BUSY transfer type marks a pause inside a burst. Each is a cycle where no useful beat completes; a smooth pipeline avoids them.

The bubbles — wait states, IDLE, and BUSY — are the system-level enemies of throughput, and each points to a different culprit: wait states blame a slow subordinate, IDLE blames a manager with nothing to issue, BUSY blames a manager pausing mid-burst. So when an AHB subsystem underperforms, the pipeline view tells you where to look: are subordinates inserting waits (bridge them or speed them up), or are managers failing to keep the pipe fed (a manager-side issue)? The pipeline turns a vague "the bus is slow" into a specific diagnosis.

And here is the crucial system-level boundary: pipelining is throughput, not concurrency. A full pipeline still carries one access path at a time — it is one master's stream of transfers, overlapped. It does not let two masters move data simultaneously, and it does not hide memory latency by keeping many independent transactions outstanding. When a system needs those things — multiple masters making progress at once, latency hidden behind many outstanding requests — pipelining cannot provide them, and that is precisely the wall where AHB gives way to AXI. Pipelining is AHB extracting the most from one shared bus; concurrency is a different bus entirely.

6. Engineering Tradeoffs

Pipelining is almost pure upside, but understanding its limits and costs is where the engineering judgement lives.

  • Throughput vs latency of a single transfer. Pipelining roughly doubles throughput (one transfer per cycle instead of two cycles per transfer) but does not reduce the latency of any single transfer — each still takes its address phase plus its data phase. The win is in streams, not in isolated accesses. For a lone access, pipelining buys nothing; for a run of them, it buys everything.
  • Free throughput vs the hold discipline. The pipeline costs essentially no extra hardware (just the registers synchronous design already has), which is a superb trade. The price is the discipline it demands: address and data must be held correctly across stalls, and a manager that mishandles the hold during a wait state corrupts the pipeline. Cheap to build, but unforgiving of sloppy stall handling.
  • Keeping the pipe full vs real-world bubbles. Peak throughput requires back-to-back transfers with no bubbles, but real systems insert them — slow subordinates (wait states), managers that pause (IDLE/BUSY). The achievable throughput is the peak minus the bubbles, so design effort goes into minimizing both: fast subordinates on the hot path, managers that keep transfers queued.
  • Throughput within one master vs concurrency across masters. Pipelining maximizes a single master's stream but does nothing for concurrency. Spending effort to perfect AHB pipelining has a ceiling: it cannot give you simultaneous masters. Recognizing when you have hit that ceiling — and need AXI rather than a better-pipelined AHB — is the key architectural judgement.

The through-line: pipelining is the highest-leverage, lowest-cost performance feature of AHB, but it optimizes the wrong axis for concurrency. It is the right tool to keep one shared bus busy and the wrong tool to make many masters run at once. Knowing which problem you have decides whether you tune the pipeline or change buses.

7. Industry Example

Trace a DMA engine streaming a block through the pipeline, then watch a bubble appear.

A DMA engine (manager) on an AHB is copying a buffer from one on-chip SRAM to another, issuing a run of transfers.

  • Pipeline fills. The DMA issues address A in the first cycle. Next cycle, data A moves (SRAM is fast, HREADY high) while the DMA issues address B. The cycle after, data B moves while address C is issued. The staircase is full: after the first transfer, the DMA completes one transfer per cycle, streaming the block at near-peak bandwidth. This is AHB pipelining doing exactly its job — a cheap shared bus moving real bandwidth.
  • A wait state bubbles the pipe. Now suppose one of the SRAMs occasionally needs a wait state (say a refresh or an arbitration delay inside it). On that access, the subordinate holds HREADY low for a cycle: the current data phase repeats, the next address phase is held, and the whole pipeline pauses for one cycle — a bubble. Throughput for that beat drops; the DMA's effective rate is peak minus the bubbles.
  • An IDLE bubble from the manager. Suppose instead the DMA itself must pause — perhaps it is waiting on something internal — and issues an IDLE transfer. Now the bubble is the manager's fault, not a subordinate's: there is simply no address to feed the pipe that cycle, so a slot goes empty.
  • The diagnosis. If this DMA stream underperforms, the pipeline view localizes it immediately: count the bubbles and attribute them. Wait-state bubbles → a subordinate problem (speed it up or bridge it). IDLE/BUSY bubbles → a manager problem (keep it fed). And if single-stream throughput is already near one-per-cycle but the system still falls short because the processor also needs the bus, the conclusion is the concurrency wall — not a pipeline fix.

Every performance statement here is read off the pipeline cadence: full staircase = peak; bubbles = losses, attributable by their cause. That attribution is the practical engineering payoff of understanding pipelined operation.

8. Common Mistakes

9. Interview Insight

Pipelining is a favourite interview topic precisely because the throughput-versus-concurrency distinction separates those who understand AHB from those who memorized it.

A summary card describing the phase overlap, the causes of bubbles, the one-per-cycle payoff, and a senior note that pipelining is not concurrency.
Figure 4 — a strong answer in one card: AHB pipelines by overlapping each transfer's data phase with the next transfer's address phase, so after the pipe fills one transfer completes per cycle; bubbles come from wait states, IDLE, or BUSY. The senior point: pipelining keeps a single shared bus busy but does not create concurrency — still one access path at a time.

The answer that lands explains the overlap, the cadence, and the limit: "AHB pipelines by overlapping each transfer's data phase with the next transfer's address phase — they use different parts of the bus, so they coexist in a cycle. After the first transfer fills the pipe, one completes per cycle. Bubbles come from wait states, IDLE, or BUSY. But pipelining is throughput, not concurrency — the bus still carries one access path at a time, so it keeps a single shared bus busy and cannot make two masters run at once." That final distinction is the senior signal.

10. Practice Challenge

Reason from the staircase and the bubble causes.

  1. Draw the staircase. Sketch three pipelined transfers and label, for two cycles, which transfer is in its address phase and which is in its data phase. Check against Figure 1.
  2. Explain the overlap. In two sentences, explain why the address and data phases of different transfers can share a cycle.
  3. Attribute the bubbles. For each of a wait state, an IDLE, and a BUSY, state which component is responsible and why no useful beat completes that cycle.
  4. Throughput vs latency. Explain why pipelining helps a 100-transfer DMA stream but does nothing for a single isolated read.
  5. Spot the wall. A subsystem's single-master stream is near one-per-cycle but multi-master throughput is short. State whether this is a pipelining or concurrency problem and the correct class of fix.

11. Key Takeaways

  • Pipelining overlaps each transfer's data phase with the next transfer's address phase, because the two phases use different parts of the bus — so after the pipe fills, one transfer completes per cycle.
  • It exists to defeat the dead time of an unpipelined two-phase transfer, turning "two cycles per transfer" into "one transfer per cycle" at essentially no extra hardware.
  • HREADY advances the whole pipeline: high steps the staircase forward, low freezes every stage at once. The pipeline pauses during stalls, holding its state.
  • Bubbles come from wait states (subordinate's fault), IDLE, and BUSY (manager's fault); achievable throughput is peak minus bubbles, and the cause tells you where to fix it.
  • Pipelining improves stream throughput, not single-transfer latency — it helps runs of transfers, not isolated accesses.
  • Pipelining is throughput, not concurrency. A full pipeline still carries one access path at a time; making many masters run at once needs a concurrent interconnect — the AHB-to-AXI boundary.

12. What Comes Next

You now understand how AHB keeps its shared bus busy. The next chapter introduces the multi-beat transfers that make pipelined streams especially efficient:

  • 2.6 — Single Transfer vs Burst Transfer (coming soon) — single beats versus multi-beat bursts, the burst shapes, and when each is used.
  • 2.7 — AHB-Lite Overview (coming soon) — the single-master AHB-Lite subset and how it simplifies the full protocol.

To revisit the phases that pipeline together, see The Address / Control Phase and The Data Phase. For the model and the concurrency boundary this chapter sharpens, see The AHB Mental Model and Shared Bus vs Interconnect Thinking. For the broader protocol map, see the AMBA family overview.