wire / wire-format / apic
The APIC (Local APIC + I/O APIC) is the modern interrupt controller for x86 multi-core systems. Local APIC: per-CPU, handles local interrupts (timer, thermal, performance monitoring) and receives IPIs (inter-processor interrupts). I/O APIC: routes external interrupts to CPUs. Key registers: ICR (interrupt command register, for IPIs), LVT (local vector table, for timer/LINT/thermal/PMI), TPR (task priority register), EOI register.
aka: APIC (Advanced Programmable Interrupt Controller)
spec: Intel 64 and IA-32 Architectures Software Developer's Manual
The APIC (Local APIC + I/O APIC) is the modern interrupt controller for x86 multi-core systems. Local APIC: per-CPU, handles local interrupts (timer, thermal, performance monitoring) and receives IPIs (inter-processor interrupts). I/O APIC: routes external interrupts to CPUs. Key registers: ICR (interrupt command register, for IPIs), LVT (local vector table, for timer/LINT/thermal/PMI), TPR (task priority register), EOI register.
| field | size | meaning |
|---|---|---|
| Local APIC ID | 1 byte | Unique ID for each CPU's local APIC (0-255). |
| ICR (Interrupt Command Register) | 8 bytes (2 dwords) | Sends IPIs: vector (8 bits), delivery mode (3 bits: fixed, lowest priority, SMI, NMI, INIT, startup), destination mode (physical/logical), level (assert/deassert), trigger (edge/level), destination shorthand, destination ID. |
| LVT Timer | 4 bytes | Local vector table entry for the APIC timer: vector, delivery mode, mask, timer mode (one-shot/periodic/TSC-deadline). |
| LVT LINT0/LINT1 | 2 x 4 bytes | Local vector table for LINT0 and LINT1 (external interrupts from 8259 or I/O APIC). |
| TPR (Task Priority Register) | 4 bytes | Task priority (0-15). Interrupts with priority <= TPR are masked. |
| EOI Register | 4 bytes | Write to signal end of interrupt processing. |
| I/O APIC RTE | 8 bytes each | Redirection Table Entry: vector, delivery mode, destination mode, polarity, trigger, mask, destination. |
| I/O APIC ID | 4 bytes | I/O APIC identifier. |
example:
00 00 00 00 00 00 00 00
APIC (placeholder)
agent: curl -H 'accept: application/json' wire.phall.io/wire-format/apic
or /wire-format/apic.json