← Protocols Interviews

Interview Question · Design

IDs Through an AXI Interconnect

L3 SeniorL4 Staffaxiinterconnectidsarchitecture
  • Likely at Intel
  • Likely at Infineon

The Question

The interviewer asks

Four managers, each with 4-bit IDs, share three subordinates through your interconnect. How do IDs work across it, and where can it go wrong?

Reveal the Model Answer

The interconnect appends the manager port number, so subordinates see 6-bit IDs. The fabric routes BID and RID back by those bits, and strips them on the way. Across subordinates, it must keep same-ID order. If a manager sends ID 3 to subordinate A, then ID 3 to B, B's response must not overtake A's. Usually the fabric stalls the second request, or keeps a per-ID destination table. Every added bit widens subordinate tracking and exclusive monitors.

Two Reads, One ID, and a Fabric That Lets the Fast One PassThe manager asks m1 (slow) then m0 (fast) with the same ID. With ordering off, the fabric forwards both at once and hands back whatever answers first.
ARRARRARRManagertwo reads, id 5Fabricordering offm0, fast0x0000 to 0x7fffm1, slow0x8000 to 0xffff

Both requests carry id 5. The manager can only file the first data that comes back under its oldest request with that ID.

012345678910clkarvalidarreadyaraddr8100104xar_m1a1x8100xar_m0a0x104xr_m0d0xa1a2xr_m1d1xb0b1xrvalidrreadyridx5x5rdataxa1a2xb0b1rlast
  1. Cycle 1

    The second request, to the fast m0, is accepted one cycle after the first. A fabric that enforces ordering would hold it until the slow read had answered. This one forwards it at once.

  2. Cycle 6

    m0 answers first, and the fabric passes a1 to the manager under rid 5. The manager's oldest request with id 5 is the read of 0x8100, so a1 is filed as the first word of 0x8100.

  3. Cycle 9

    Now m1 answers. b0 and b1, the real content of 0x8100, are filed as the read of 0x104. Every handshake was legal; two transactions swapped their data.

Measured through a fabric that does not stall the second request. The fast subordinate answers first, so the two same-ID reads swap data.

Self-Check

Tick each key point you covered in your answer.

What Interviewers Listen For (Senior)

A good senior answer explains how the fabric adds port bits to the ID and routes responses back by them. It explains why a same-ID request to a second subordinate must stall.

Cross-Questions

Where the interviewer goes next. Open a node to practise that follow-up.

WhyWhat IfProve ItBreak ItCompareScale It

  1. IDs Through an AXI Interconnect
  2. WhyWhy the Interconnect Extends IDsL2 Mid-LevelL3 Senior

    Why does the interconnect add bits to the ID instead of passing it through?

    Reveal the Model Answer

    Two managers may both use ID 0. Without a port tag, their transactions would merge into one ordering stream at the subordinate. The responses also could not be routed back. Appending the port number makes every ID unique system-wide, without managers coordinating. It also gives the fabric its return address.

    Self-Check

    Tick each key point you covered in your answer.

  3. What IfSame ID to Two SubordinatesL3 Senior

    A manager issues ID 5 to a slow DDR, then ID 5 to a fast SRAM. Walk me through what your interconnect does.

    Reveal the Model Answer

    The SRAM would answer first, which would break same-ID order at the manager. The common design tracks the outstanding count and its destination, per manager and ID. A new request with the same ID to a different destination stalls until the earlier responses return. The alternative, a reorder buffer, costs area. Lesson P2.10 measured the stall: the second ID-5 request was held from edge 4 to edge 13.

    Self-Check

    Tick each key point you covered in your answer.

    What Interviewers Listen For (Senior)

    A good senior answer describes a tracker of the destination for each ID, and the stall it causes. It names a reorder buffer as the costlier alternative.

  4. CompareStalling Versus a Reorder BufferL3 SeniorL4 Staff

    Compare stalling same-ID requests with a reorder buffer in the interconnect.

    Reveal the Model Answer

    Stalling needs only a count and a destination per manager and ID. It costs speed when one manager reuses an ID across fast and slow targets. A reorder buffer lets both requests go and holds the early response until its turn. It must store every response that can arrive early, so it costs area and design risk.

    Self-Check

    Tick each key point you covered in your answer.

    Half-Truth

    "A reorder buffer is always better, because it never stalls."

    Its storage grows with outstanding requests and burst length. Giving independent streams their own IDs often gets the speed with no extra area.

  5. Scale ItThe Cost of ID Width in a Large FabricL4 Staff

    Your SoC has three levels of interconnect and 40 managers. The memory controller now sees 14-bit IDs. What problems does that create and what would you do?

    Reveal the Model Answer

    Every level adds port bits. The memory controller's per-ID state, reorder logic and exclusive monitors grow with the IDs it must tell apart. One option is to remap IDs into a smaller set of in-flight tags, which is legal if the original ordering is kept. Others are capping outstanding transactions per manager, or using the unique-ID indicator so unordered requests need no tracking. Each trades area for stalls.

    Self-Check

    Tick each key point you covered in your answer.

    What Interviewers Listen For (Staff)

    A good staff answer names ID remapping that keeps order, the unique-ID indicator and limits on outstanding requests. It treats it as an area versus performance decision, made with the memory-controller team.

  6. Break ItVerifying an AXI InterconnectL3 SeniorL4 Staff

    Walk me through how you would verify an AXI interconnect. What checks, what coverage, and which bugs are you most worried about escaping?

    Reveal the Model Answer

    Put a protocol checker on every manager and subordinate port. A fabric re-registers what it forwards, so it hides a subordinate's fault from the manager side. Add an end-to-end scoreboard keyed by manager and ID that checks routing, data, ID restore and same-ID order across subordinates. Test every region edge and hole for full-length DECERR. Stress with random back-pressure (READY held low), W before AW, maximum outstanding and racing exclusives, with watchdogs for deadlock.

    Bug that escapesWhat catches it
    Equal-length same-ID responses swappedscoreboard keyed by ID and address
    VALID waiting for READY (deadlock)watchdog or liveness property, plus a subordinate that waits for VALID
    Data in the wrong lanes with legal strobesbyte-level data check
    Subordinate stability bug behind a register slicechecker bound at the subordinate port
    Same-ID requests to two subordinates reorderedend-to-end per-ID order check with unequal latencies

    Self-Check

    Tick each key point you covered in your answer.

    What Interviewers Listen For (Senior)

    A good senior answer puts a checker on every port, plus an end-to-end scoreboard keyed by manager and ID, and decode tests.

  7. Prove ItSolve P2.17.1: The AXI MonitorSimulator-graded

    Show it, don't just say it: this Silicon Lab problem is graded by the simulator.

    Open Problem P2.17.1

What People Get Wrong

Common wrong answers and why they fail.

Misconception

"Each subordinate keeps same-ID order, so the system does too."

Two subordinates answer independently. Same-ID requests split across them can return out of order unless the interconnect prevents it.

Source AMBA AXI Protocol Specification IHI 0022L §A5.5 Write data and response ordering; §A5.6 Read data ordering

Wrong Altitude

"Just give subordinates a wide enough ID and pass everything through."

Width is not free: per-ID tracking, reorder buffers and exclusive monitors grow with it. The question is the trade-off, not the wiring.

Learn It, Then Prove It