Zen Peripherals · Interrupt Architecture · brief · 2026-11-04

A RISC-V interrupt subsystem that turns wired sources into per-hart message-signalled interrupts

The Zen AIA (Advanced Interrupt Architecture) is a RISC-V AIA-1.0 interrupt subsystem a client drops into their SoC in place of a classic PLIC. An APLIC aggregates and rectifies wired interrupt sources; an IMSIC receives message-signalled interrupts (MSIs) as per-hart interrupt files and drives each hart's external-interrupt line. The two are pre-composed so a wired source becomes a hart interrupt with no external glue. Product / integrator view; every number is sourced from the as-built RTL or marked TBC with an owner.

1. AIA in one paragraph

The AIA replaces per-hart wired interrupt lines with message-signalled delivery. The APLIC rectifies each raw wired source per its configured mode — edge-rising, edge-falling, level-high, level-low, or inactive/detached — into a pending/enable bitmap. It then delivers either direct (asserts a wired irq_o to the highest-priority pending-enabled source) or by MSI (emits one outbound bus write carrying the source's interrupt identity to a per-hart MSI address). The IMSIC receives that MSI as a literal bus write of an identity to a per-hart seteipnum offset, maintains per-hart pending/enable state, priority-encodes the top eligible interrupt (topei), and asserts ext_irq_o to that hart. The subsystem wrapper routes APLIC's MSI output straight into IMSIC, so the full source → hart path needs no external plumbing.

RISC-V AIA 1.0APLIC router + IMSIC MSI file
32 sourcesAPLIC wired inputs (default)
64 identitiesper IMSIC hart file (default)
direct + MSItwo delivery modes
Zen AIA (aia_top) sourceswired irq_src APLICrectify · ip/iedirect · MSI FSM IMSICeip/eie filetopei encode hartext irq line host — config over region-decoded peripheral bus MSI write ext_irq_o direct irq_o
Figure 1. A wired source enters the APLIC, is rectified into pending/enable state, and is delivered either directly as irq_o or as an MSI write that the IMSIC receives, priority-encodes (topei), and presents to the hart as ext_irq_o.
One subsystem, no glue. APLIC's MSI master port is routed straight into IMSIC through a 2:1 arbiter (APLIC MSI takes priority over an external IMSIC access). A wired source travels source → rectifier → pending/enable → MSI write → IMSIC eip → topei → ext_irq_o, and the identity the hart reads equals the identity the source carried — verified end-to-end.
One MSI in flight at a time. The APLIC MSI path is a serialized FSM (IDLE → SEND → DONE) that holds until the bus accepts the write; sources are arbitrated in ascending-identity order. Sustained MSI rate and cycle-exact end-to-end latency are frequency-dependent and reported TBC — measured from the end-to-end testbench, never asserted as a spec number.

2. What it is, at a glance

ElementDetailDefaultStatus
APLIC wired sourcesidentities 1..N-1; id 0 reserved32exists
APLIC source modesinactive · detached · edge-rising / -falling · level-high / -low—exists
APLIC deliverydirect (wired irq_o, IPRIO priority + claim) and MSI (outbound write of EIID)—exists
SW-generated MSIgenmsi emits a SW MSI (no source pending touched)—exists
IMSIC identities per hart filepending/enable (eip/eie) bitmaps64exists
IMSIC delivery controlseidelivery enable + eithreshold eligibility, per hart—exists
IMSIC topeipriority-encode, lowest identity wins; claim-on-read advances—exists
Target hartsshared by APLIC + IMSIC; per-hart MMIO page isolation1exists
Bus32-bit struct-typed peripheral bus; region-decoded (APLIC vs IMSIC)—exists
Multi-domain / supervisor / guest filessingle machine-level domain in v1; phased extension—TBC
Sustained MSI rate / end-to-end latency / fmaxfunctional sign-off shipped; timing downstreamTBCTBC

Sources: Zen AIA product datasheet; as-built RTL.

3. How a client uses it

  1. Instantiate the pre-composed subsystem (APLIC + IMSIC + wrapper) and attach the config bus; region decode selects the APLIC config region or an IMSIC page.
  2. Configure sources — set each source's mode (sourcecfg) and target hart, program the pending/enable bitmaps, and choose the domain delivery mode (direct or MSI).
  3. Deliver — in direct mode the hart reads a per-hart window to claim the highest-priority source; in MSI mode APLIC writes the identity to the hart's IMSIC page, which the hart services by reading topei.
  4. Scale or steer — raise NUM_SOURCES / NUM_IDS / NUM_HARTS for large interrupt populations, and steer each source to a hart; eithreshold masks low-priority identities at the receiver.

4. Verification & provenance

Sources read

Sources: Zen AIA product datasheet; as-built RTL.