Skip to content
DenseChip
Learn
PracticeCode labInterview

DenseChip

Navigate

Menu

LearnPracticeCode labInterview

Tools

All toolsSV editorCode repoResume
DenseChip

Practice, courses, and chip-design tools in one focused workspace.

LearnPracticeCode labInterviewToolsLearning paths

© 2026 DenseChip

AboutContactPrivacyTerms
Skip to lesson

Course contents

  • How to Use This Course
  • Reading Paths
  • Concept Map
  • How to Read the Diagrams
  • Part 0: What Is a Protocol?10
  • Part 1: Timing and Clocking11
  • Part 2: Encoding and Framing12
  • Part 3: Handshakes13
  • Part 4: Flow Control17
  • Part 5: Transactions19
  • Part 6: Concurrency and Performance17
  • Part 7: Ordering13
  • Part 8: Sharing and Arbitration12
    • Shared Media and Topologies
    • Arbitration Policies
    • Fairness and Starvation
    • Priority Inversion
    • Arbitration Granularity
    • Distributed Arbitration
    • Quality of Service
    • Virtual Channels
    • Routing
    • Multicast and Broadcast
    • Protocols Compared: Sharing and Arbitration
    • Drills: Sharing and Arbitration
  • Part 9: Deadlock and Liveness13
  • Part 10: Reliability and Recovery20
  • Part 11: Bring-Up and Link Management10
  • Part 12: Power8
  • Part 13: Shared State and Coherence9
  • Part 14: Security and Isolation7
  • Part 15: Specifying and Verifying11
  • Part 16: Protocols Dissected17
  • Part 17: Capstones5
  • Part 18: Interview Preparation6
Loading lesson

‹Part 8: Sharing and Arbitration
  1. Topics
  2. First Principles of Hardware Protocols
  3. Part 8: Sharing and Arbitration
  4. Virtual Channels

Part 8 · Sharing and Arbitration · Senior (S)

Virtual Channels

A virtual channel is a separate buffer and flow-control loop sharing one physical link. What virtual channels buy (isolation between traffic, freedom from head-of-line blocking, deadlock avoidance) and what they cost.

On this page

    Note

    Level: Senior (S) · Answers: Who gets the wire?

    Before this: Credit Classes and Pools, Head-of-Line Blocking

    A network-on-chip link carries both requests and responses. One day a burst of requests fills the input buffer at the next router, and the responses behind them, the very responses that would let those requests complete, cannot get in. The link is idle and the system is stuck. A second set of buffers for responses, on the same wires, removes the problem completely.

    How can one physical link behave like several independent ones, and why would you want it to?

    The obvious answer, and why it breaks

    The obvious link has one buffer at its receiving end and one flow-control loop: whatever arrives first goes first. Every kind of traffic shares that buffer, so any kind can block any other: bulk traffic delays urgent traffic (lesson 8.7), a blocked packet stops everything behind it (lesson 4.14), and requests can block the responses they depend on (Part 9). Adding more wires for each kind of traffic would fix it, at a high cost in area.

    The idea: separate buffers and credits, shared wires

    A virtual channel (VC) is a separate buffer at the receiver with its own credit loop, sharing the physical link's wires with other VCs. Each flit carries a VC number; the sender may send a flit on a VC only if that VC has credit; each cycle, an arbiter chooses which VC's flit uses the wires. A VC that is blocked holds only its own buffer; the others keep moving.

    Requests and responses share the wires but not the buffers: with VC 0 full, responses still flow on VC 1.

    What virtual channels buy

    Benefit

    How

    Isolation between traffic classes

    Urgent traffic has its own buffer and is never queued behind bulk (lesson 8.7)

    Less head-of-line blocking

    A packet blocked in one VC does not stop packets in another (lesson 4.14)

    Deadlock freedom

    Requests and responses in separate VCs cannot block each other (lesson 9.4); extra VCs break cyclic dependencies in rings and meshes (lesson 9.6)

    Higher link use

    When one VC is blocked, another can use the wires

    What they cost

    • Buffers: each VC needs enough buffer to cover its own credit round trip for the rate it must sustain (lesson 4.5); V VCs multiply buffer area.

    • Credit loops: one counter and one credit-return path per VC.

    • Arbitration: a VC arbiter on each link output, and VC allocation in each router (which VC a packet uses on the next link).

    • A VC field in every flit or packet.

    VCs are therefore assigned for a purpose (one per message class that must not block another, plus what deadlock avoidance needs), not handed out freely.

    How real protocols chose

    Protocol

    Virtual channels

    PCI Express

    Traffic classes map onto virtual channels, each with its own buffers and its own posted, non-posted and completion credits.

    On-chip networks

    VCs per message class (requests, responses, snoops) and extra VCs for deadlock-free routing on rings and with adaptive routing.

    AXI

    No VCs: independent channels per direction and kind (lesson 5.6) give some of the same isolation.

    What breaks

    The opening network (illustrative) carried requests and responses in one buffer per link. Under a request burst, buffers filled with requests whose targets could not accept more until they sent responses, and the responses had nowhere to go. Moving responses to their own VC removed the cycle of dependencies; nothing else changed.

    Why this matters

    Senior lens. Assign virtual channels deliberately: list the message classes that must never block each other and the extra channels the routing scheme needs for deadlock freedom, and give each its own buffers and credits sized for its rate. Check that every router and bridge keeps the VC assignment end to end; a single shared buffer anywhere reintroduces the coupling the VCs were added to remove.

    Interview

    Asked: "What is a virtual channel for?"

    Weak answer: To make the link faster.

    Strong answer: A VC is a separate buffer and credit loop sharing a physical link's wires, so traffic in one VC can't block another. That buys isolation between classes, so urgent traffic doesn't queue behind bulk; less head-of-line blocking; and deadlock freedom, by putting requests and responses in separate VCs and adding VCs to break routing cycles. The cost is buffer area per VC sized for its own credit loop, per-VC credits, VC arbitration and allocation, and a VC field in each flit.

    Follow-ups: (1) Why must requests and responses use different VCs? (2) How large must each VC's buffer be?

    Check yourself A link has 3 VCs, each needing 12 flits of buffer to cover its credit loop. How much receive buffering does the link need?

    36 flits: each VC has its own buffer and credits.

    Check yourself Why doesn't a full buffer in one VC stop the others?

    Each VC has its own credits; the sender stops sending on the full VC only, and the arbiter gives the wires to VCs that have credit.

    Key takeaways

    • A virtual channel is a separate buffer and credit loop sharing one physical link's wires.

    • VCs isolate traffic classes, reduce head-of-line blocking and break deadlock cycles.

    • Each VC costs buffers, credits and arbitration; assign them for a purpose and keep them end to end.

    Keep going

    Next: Lesson 8.9, Routing. Deterministic or adaptive routing, and why XY routing cannot deadlock.

    Related topics

    • Part 8 overview: Sharing and Arbitration

    Previous

    124 / 234

    Next: Routing

    Up next

    Up nextRouting

    Sign in to save progress

    Practice this lessonReport an error

    See also

    • Shared Media and Topologies
    • Arbitration Policies
    • Fairness and Starvation