Skip to content

AMBA AHB · Module 10

Round-Robin Arbitration

Round-robin AHB arbitration — the arbiter cycles through the masters in rotation, granting each requesting master a turn before any repeats — guaranteeing fairness and preventing starvation, at the cost of no prioritization.

Chapter 10.5 covered fixed-priority — simple and low-latency for high-priority masters, but unfair (it can starve low-priority masters). This chapter covers the fair alternative: round-robin. The arbiter cycles through the masters in a rotation, granting each requesting master a turn before any master gets a second — tracked by a rotation pointer. This guarantees fairness: every requesting master is served in turn, so no master is starved. The trade-off versus fixed-priority: round-robin doesn't prioritize — a latency-critical master gets no special treatment (it waits its turn like everyone else) — and it needs state (the rotation pointer) versus fixed-priority's stateless encoder. So round-robin is preferred when the masters are roughly equal and fairness matters (no starvation), while fixed-priority suits a clear hierarchy. Round-robin trades fixed-priority's low high-priority latency for fairness.

1. What Is It?

Round-robin arbitration cycles through the masters in a fixed rotation, granting each requesting master a turn before any master repeats. A rotation pointer tracks whose turn is next.

Four masters (A, B, C, D) in a rotation cycle, with the arbiter granting each in turn, and a note that the rotation pointer tracks whose turn is next, ensuring fairness.
Figure 1 — round-robin grants each master a turn in rotation. The arbiter cycles A → B → C → D → A → … After granting one master, the turn moves to the next requesting master in the cycle, so each master is served before any master gets a second turn. A rotation pointer tracks whose turn is next. This guarantees fairness — every requesting master is served in turn — so no master is starved.

So the rule is: rotate through the masters, granting each requesting one a turn, then moving on. After master A is served, the turn moves to B (if requesting), then C, then D, then back to A — a cyclic order. The rotation pointer remembers where the cycle is, so the arbiter knows whose turn is next. Crucially, a master that was just served goes to the back of the rotation — so it won't be served again until all other requesting masters have had a turn. This is what guarantees fairness: every requesting master gets a turn before any master repeats. No master can monopolize the bus (unlike fixed-priority's high-priority master), and no master is starved (every requester is eventually served).

2. Why Does It Exist?

Round-robin exists because fixed-priority's unfairness (starvation of low-priority masters) is unacceptable in many systems — where masters are roughly equal and all need guaranteed access — and round-robin provides fairness by serving every master in turn.

Fixed-priority (chapter 10.5) starves low-priority masters when a high-priority master is busy. But many systems have masters that are roughly equal in importance — several DMA engines, several processors of equal priority — where no master should be starved; each needs a fair share of the bus. Fixed-priority can't provide this (it would starve the lower-ranked ones). Round-robin can: by cycling through the masters and serving each in turn, it guarantees every master gets the bus regularly — no starvation. So round-robin exists to provide fairness for systems where masters are equal and all need guaranteed access. It's the policy for "everyone gets a fair turn."

The reason round-robin guarantees no starvation is the rotation: because a just-served master goes to the back of the rotation, it can't be served again until all other requesting masters have had a turn. So every requesting master is served within one rotation cycle — its wait is bounded (by the number of other requesting masters). No master can be passed over indefinitely (as in fixed-priority). So round-robin's rotation structurally prevents starvation: the bounded wait is the anti-starvation guarantee. This is why round-robin is the fair policy — the rotation ensures everyone's turn comes around, with a bounded wait.

The reason round-robin doesn't prioritize (its trade-off) is that the rotation treats all masters equally — each gets one turn per cycle, regardless of urgency. So a latency-critical master gets no special treatment — it waits its turn like everyone else, with a wait bounded by the number of other masters (not minimized). So round-robin trades fixed-priority's low high-priority latency for fairness: everyone's wait is bounded and equal, but no one gets prioritized. This is the cost of fairness — equal treatment means the urgent master isn't favored. So round-robin exists for fairness, accepting that it can't give a critical master the minimal latency fixed-priority would. (Hybrid policies — weighted round-robin, priority-with-fairness — try to get both, but pure round-robin is purely fair.) So the choice between round-robin and fixed-priority is fairness vs prioritization — round-robin when masters are equal and fairness matters, fixed-priority when a clear hierarchy needs low high-priority latency.

3. Mental Model

Model round-robin as taking turns in a circle passing a ball — everyone gets the ball once before anyone gets it twice, so no one is left out, but the most eager player doesn't get it any more often than the others.

A group plays a game where a ball (the bus) is passed around a circle (the rotation). The rule: pass the ball to the next person in the circle who wants it, and once you've had the ball, you go to the back — you don't get it again until everyone else who wants it has had a turn. So everyone gets a turn before anyone repeats (fairness — no one is left out, no starvation). The position in the circle (the rotation pointer) tracks whose turn is next. But notice: the most eager player (a latency-critical master) doesn't get the ball any more than the others — they wait their turn in the circle like everyone else (no prioritization). So the game is fair (everyone included, bounded wait) but equal (no favoritism) — great when all players are equally important, but not if one genuinely needs the ball more often.

This captures round-robin: passing the ball around the circle = the rotation; everyone gets a turn before repeats = fairness/no starvation; going to the back after your turn = the just-served master moving to the back of the rotation; the position tracking whose turn is next = the rotation pointer; the eager player not favored = no prioritization. Fair and equal, but no favoritism.

Watch round-robin rotating through the masters:

Round-robin rotating through masters A, B, C

4 cycles
req_A, req_B, req_C are all high (all request continuously). The grant rotates A, B, C, A — each master served in turn, cyclically. No master is starved; each gets an equal turn. The rotation pointer advances after each grant.rotation: A → B → C → A (each gets a turn)rotation: A → B → C → …back to A — fair, no starvation, equal turnsback to A — fair, no s…HCLKreq_Areq_Breq_CgrantABCAt0t1t2t3
Figure 2 — round-robin rotating through the masters. Masters A, B, C all request continuously. The arbiter grants them in rotation: A, then B, then C, then back to A — each gets a turn in cyclic order. No master is starved (each is served every cycle), and no master gets the bus more than the others (equal treatment). The rotation pointer advances after each grant, ensuring the cyclic fairness.

The model's lesson: pass the ball around the circle — everyone gets a turn before anyone repeats. In the waveform, the grant rotates A → B → C → A, serving each master equally; none is starved, none favored. Round-robin gives everyone a fair, bounded turn — the fairness fixed-priority lacks.

4. Real Hardware Perspective

In hardware, round-robin arbitration is a priority-encoder-with-rotation: the arbiter has a rotation pointer (state) that sets the starting point of the priority comparison, and after each grant, the pointer advances past the served master — making it stateful (unlike fixed-priority's stateless encoder).

The rotation pointer is the key state: it points to the master whose turn is "first" in the current rotation. The arbiter grants the highest-"priority" requester relative to the pointer — i.e., starting from the pointer and going around the cycle, the first requesting master. After granting, the pointer advances past the served master (to the next in the cycle), so that master is now last in the next rotation. So round-robin is implemented as a priority encoder whose "priority order" rotates with the pointer — a fixed-priority encoder, but with a moving starting point. This requires the pointer state (a register), making round-robin stateful, versus fixed-priority's stateless encoder. So the hardware is a rotating priority encoder plus the pointer register.

The fairness guarantee in hardware comes from the pointer always advancing past the served master: since the served master moves to the back of the rotation, it can't be served again until the pointer has cycled all the way around (serving all other requesters). So the pointer's advance is what structurally guarantees the bounded wait (no starvation). In hardware, this is the pointer-update logic: after each grant, advance past the granted master. This small piece of state and logic is what makes round-robin fair. So round-robin's hardware is modest — a rotating encoder and a pointer — but more than fixed-priority's pure combinational encoder.

The state cost is the trade versus fixed-priority: round-robin needs the rotation pointer (a register) and the rotating-encoder logic, versus fixed-priority's stateless combinational encoder. So round-robin is slightly more hardware (the pointer state and update logic) — but still modest (a small register and some logic). The state also makes round-robin's behavior depend on history (the pointer's current position), so it's less trivially deterministic than fixed-priority (though still deterministic given the state). So in hardware, round-robin costs a bit more (state) for fairness — a reasonable trade when fairness is needed. So fixed-priority is the cheapest (stateless); round-robin adds a pointer for fairness.

A hardware note on variants: pure round-robin gives every master an equal turn. Variants adjust this: weighted round-robin gives some masters more turns per cycle (a middle ground between equal fairness and prioritization); priority-with-round-robin uses fixed-priority among priority classes but round-robin within a class (so equal-priority masters are fair to each other). So real arbiters often use hybrid policies — round-robin's fairness combined with some prioritization. These hybrids try to get both low latency for important masters and fairness/no-starvation for the rest. So in hardware, the arbiter's policy may be pure round-robin, pure fixed-priority, or a hybrid — chosen for the system's fairness/latency needs. Pure round-robin is the fair extreme; hybrids blend it with prioritization.

5. System Architecture Perspective

At the system level, round-robin is the policy for fairness among equal masters — guaranteeing every master a bounded-latency turn, no starvation — and it (or a hybrid) is chosen when all masters need guaranteed access, in contrast to fixed-priority's clear-hierarchy fit.

The equal-masters fit is round-robin's sweet spot: systems where the masters are roughly equal in importance and all need guaranteed bus access — several DMA engines, multiple equal-priority processors, multiple equal-bandwidth streams. Round-robin serves all of them fairly, with no master starved. So round-robin suits systems without a clear priority hierarchy — where favoring one master over another would be wrong, and every master deserves a fair share. This is common in symmetric multi-master systems (e.g., multiple identical compute engines). So round-robin is the natural choice when masters are peers.

The no-starvation guarantee is round-robin's key system property: because every requesting master is served within one rotation, each master's bus-access latency is bounded (by the number of other requesting masters) — no master waits indefinitely. So round-robin provides a bounded-latency guarantee for all masters, which is essential when every master needs predictable access (e.g., real-time systems where each master has a deadline). So round-robin's fairness gives a system-wide bounded-latency property — every master's worst-case wait is known and bounded. This predictability (for all masters, not just the top) is valuable for systems where starvation is unacceptable. So round-robin is chosen when all masters need guaranteed, bounded-latency access.

A side-by-side comparison: round-robin (fair, no starvation, no prioritization, stateful) versus fixed-priority (low high-priority latency, simple, starvation risk, unfair).
Figure 3 — round-robin versus fixed-priority. Round-robin is fair (every master gets a turn, no starvation) but doesn't prioritize (all treated equally) and needs state (the rotation pointer) — best when masters are roughly equal. Fixed-priority gives low latency for high-priority masters and is the simplest (stateless) but risks starving low-priority masters and is unfair — best with a clear priority hierarchy.

The hybrid policies are the common real-world middle ground: pure round-robin (fair but no prioritization) and pure fixed-priority (prioritized but unfair) are extremes; real systems often need both — low latency for a critical master and fairness/no-starvation for the rest. So arbiters often use hybrids: priority classes with round-robin within a class (critical masters prioritized, equal masters fair among themselves), or weighted round-robin (some masters get more turns). So at the system level, the arbitration policy is often a hybrid tuned to the masters' needs — combining round-robin's fairness with fixed-priority's prioritization. The architect chooses the policy (pure round-robin, pure fixed-priority, or a hybrid) based on the masters' relative importance and latency requirements. So round-robin's system role is the fairness building block — used pure for equal masters, or as the fairness component of a hybrid for mixed systems. The policy choice (fairness vs prioritization vs hybrid) is a key arbitration design decision, with round-robin providing the fairness.

6. Engineering Tradeoffs

Round-robin embodies the fairness-via-rotation design.

  • Round-robin (fair) vs fixed-priority (prioritized). Round-robin guarantees fairness (no starvation, bounded wait for all) but doesn't prioritize (a critical master waits its turn); fixed-priority prioritizes (low latency for the top) but starves the bottom. Round-robin for equal masters, fixed-priority for clear hierarchy.
  • Stateful (round-robin) vs stateless (fixed-priority). Round-robin needs the rotation pointer (state, slightly more hardware); fixed-priority is stateless (a combinational encoder, minimal). The fairness costs a bit of state — a modest trade.
  • Equal turns (pure round-robin) vs weighted. Pure round-robin gives equal turns; weighted round-robin gives some masters more (a middle ground toward prioritization). The choice depends on whether masters need exactly-equal shares or proportional shares.
  • Pure policies vs hybrids. Pure round-robin (fair) and pure fixed-priority (prioritized) are extremes; hybrids (priority-with-round-robin, weighted) blend them for systems needing both prioritization and fairness. Real systems often use hybrids.

The throughline: round-robin arbitration cycles through the masters in rotation, granting each requesting master a turn before any repeats — guaranteeing fairness (no starvation, bounded wait for all) at the cost of no prioritization (equal treatment) and a bit of state (the rotation pointer). It suits systems with roughly-equal masters where all need guaranteed access. It's the fairness counterpart to fixed-priority's prioritization; real systems often use hybrids to get both. The policy choice — round-robin, fixed-priority, or hybrid — is driven by whether the system needs fairness, prioritization, or both.

7. Industry Example

Trace round-robin arbitration in a system with equal masters.

A system has four identical DMA engines that each move data streams, all equally important.

  • Equal masters, fairness needed. The four DMA engines are peers — none is more important than the others, and all need a fair share of the bus to keep their streams flowing. Fixed-priority would be wrong here: it would starve the lower-ranked DMAs (favoring DMA 0 over DMA 3, which is arbitrary and unfair). So the system uses round-robin.
  • Round-robin serves them fairly. The arbiter cycles through the four DMAs: DMA 0, DMA 1, DMA 2, DMA 3, back to DMA 0. Each gets a turn in rotation, so each gets a roughly-equal share of the bus, and none is starved. The rotation pointer tracks whose turn is next. All four streams flow steadily, fairly sharing the bus.
  • Bounded latency for all. Each DMA's bus-access latency is bounded — it waits at most for the other three to have their turns. So every DMA has a predictable, bounded wait — no DMA is left behind. This bounded fairness is what the equal-streams system needs.
  • No prioritization (which is fine here). Round-robin doesn't favor any DMA — but that's correct here, since they're equal. None needs lower latency than the others. So round-robin's lack of prioritization is appropriate for these peer masters.
  • A hybrid for a mixed system. Now suppose the system also has a latency-critical CPU. Pure round-robin would make the CPU wait its turn among the DMAs (too slow for the CPU). So the system would use a hybrid: fixed-priority giving the CPU the highest priority (low CPU latency), with round-robin among the four DMAs for the remaining bus time (fair among the peers). So the hybrid gives the CPU prioritization and the DMAs fairness — the best of both. This is the common real-world pattern: prioritize the critical master, round-robin the equal ones.

The example shows round-robin serving four equal DMA engines fairly (each a bounded-latency turn, none starved — the right policy for peers), and the hybrid extension for a mixed system (fixed-priority for the critical CPU, round-robin among the equal DMAs). Round-robin provides the fairness for equal masters; a hybrid blends it with prioritization for mixed systems. The policy matches the masters' relative importance.

8. Common Mistakes

9. Interview Insight

Round-robin is a common interview topic — the rotation/fairness mechanism, the no-prioritization trade-off, and the hybrid option are the signals.

A summary card on round-robin: rotation/fairness, no starvation, no prioritization, state cost, and the equal-masters fit.
Figure 4 — a strong answer in one card: round-robin cycles through the masters in rotation, granting each requesting master a turn before any repeats (a rotation pointer); it's fair with no starvation (every master served in turn), but it doesn't prioritize (all equal) and needs state; it's preferred when masters are roughly equal and fairness matters. The senior point: round-robin trades fixed-priority's low high-priority latency for fairness — no starvation, but no prioritization.

The answer that lands gives the mechanism and the trade-off vs fixed-priority: "Round-robin arbitration cycles through the masters in a rotation, granting each requesting master a turn before any master gets a second. A rotation pointer tracks whose turn is next, and a just-served master goes to the back of the rotation — so every requesting master is served within one cycle. The key property is fairness: no master is starved, and every master's wait is bounded by the number of other requesting masters. The trade-off versus fixed-priority is that round-robin doesn't prioritize — all masters are treated equally, so a latency-critical master gets no special treatment, it just waits its turn. And it needs state — the rotation pointer — versus fixed-priority's stateless encoder. So round-robin is preferred when the masters are roughly equal and fairness matters, like several equal DMA engines; fixed-priority suits a clear hierarchy. In practice, systems often use a hybrid — fixed-priority for a critical master, round-robin among the equal ones — to get both low critical-latency and fairness for the rest." The rotation/fairness mechanism, the no-prioritization trade-off, and the hybrid option are the senior signals.

10. Practice Challenge

Reason from round-robin arbitration.

  1. State the mechanism. Explain how round-robin grants the bus, including the rotation pointer.
  2. Read the waveform. From Figure 2, explain how the three masters share the bus fairly.
  3. No starvation. Explain why round-robin guarantees no master is starved.
  4. The trade-off. Explain what round-robin gives up versus fixed-priority.
  5. Hybrid. Describe a system needing a round-robin/fixed-priority hybrid and how it works.

11. Key Takeaways

  • Round-robin arbitration cycles through the masters in rotation, granting each requesting master a turn before any repeats — tracked by a rotation pointer (a just-served master goes to the back).
  • It guarantees fairness — no starvation — every requesting master is served within one rotation, with a wait bounded by the number of other requesters.
  • It doesn't prioritize — all masters are treated equally, so a latency-critical master gets no special treatment (it waits its turn).
  • It needs state (the rotation pointer) — a rotating priority encoder — versus fixed-priority's stateless combinational encoder (a modest extra cost).
  • It suits systems with roughly-equal masters where all need guaranteed, bounded-latency access (no clear hierarchy).
  • Real systems often use hybrids — fixed-priority for a critical master, round-robin among the equal ones (or weighted round-robin) — to get both low critical-latency and fairness. The policy choice is driven by prioritization vs fairness needs.

12. What Comes Next

You now understand both arbitration policies (fixed-priority and round-robin). The next chapter examines the problem they manage:

  • 10.7 — Starvation (coming next) — master starvation and how arbitration policy avoids it.
  • 10.8 / 10.9 (coming soon) — arbitration timing and bus ownership handover.

To revisit the prioritized alternative, see Fixed-Priority Arbitration; for the arbitration mechanism, HBUSREQ & HGRANT and Why Arbitration Exists. For the broader protocol map, see the AMBA family overview.