background image

10-24 Vol. 3A

ADVANCED PROGRAMMABLE INTERRUPT CONTROLLER (APIC)

1. Flat Model — This model is selected by programming DFR bits 28 through 31 to 1111. Here, a unique logical 

APIC ID can be established for up to 8 local APICs by setting a different bit in the logical APIC ID field of the LDR 
for each local APIC. A group of local APICs can then be selected by setting one or more bits in the MDA. 
Each local APIC performs a bit-wise AND of the MDA and its logical APIC ID. If a true condition is detected, the 
local APIC accepts the IPI message. A broadcast to all APICs is achieved by setting the MDA to 1s.

2. Cluster Model — This model is selected by programming DFR bits 28 through 31 to 0000. This model supports 

two basic destination schemes: flat cluster and hierarchical cluster.
The flat cluster destination model is only supported for P6 family and Pentium processors. Using this model, all 
APICs are assumed to be connected through the APIC bus. Bits 60 through 63 of the MDA contains the encoded 
address of the destination cluster and bits 56 through 59 identify up to four local APICs within the cluster (each 
bit is assigned to one local APIC in the cluster, as in the flat connection model). To identify one or more local 
APICs, bits 60 through 63 of the MDA are compared with bits 28 through 31 of the LDR to determine if a local 
APIC is part of the cluster. Bits 56 through 59 of the MDA are compared with Bits 24 through 27 of the LDR to 
identify a local APICs within the cluster. 
Sets of processors within a cluster can be specified by writing the target cluster address in bits 60 through 63 
of the MDA and setting selected bits in bits 56 through 59 of the MDA, corresponding to the chosen members 
of the cluster. In this mode, 15 clusters (with cluster addresses of 0 through 14) each having 4 local APICs can 
be specified in the message. For the P6 and Pentium processor’s local APICs, however, the APIC arbitration ID 
supports only 15 APIC agents. Therefore, the total number of processors and their local APICs supported in 
this mode is limited to 15. Broadcast to all local APICs is achieved by setting all destination bits to one. This 
guarantees a match on all clusters and selects all APICs in each cluster. A broadcast IPI or I/O subsystem 
broadcast interrupt with lowest priority delivery mode is not supported in cluster mode and must not be 
configured by software.
The hierarchical cluster destination model can be used with Pentium 4, Intel Xeon, P6 family, or Pentium 
processors. With this model, a hierarchical network can be created by connecting different flat clusters via 
independent system or APIC buses. This scheme requires a cluster manager within each cluster, which is 
responsible for handling message passing between system or APIC buses. One cluster contains up to 4 agents. 
Thus 15 cluster managers, each with 4 agents, can form a network of up to 60 APIC agents. Note that hierar-
chical APIC networks requires a special cluster manager device, which is not part of the local or the I/O APIC 
units.

NOTES

All processors that have their APIC software enabled (using the spurious vector enable/disable bit) 
must have their DFRs (Destination Format Registers) programmed identically.
The default mode for DFR is flat mode. If you are using cluster mode, DFRs must be programmed 
before the APIC is software enabled. Since some chipsets do not accurately track a system view of 
the logical mode, program DFRs as soon as possible after starting the processor.

10.6.2.3   Broadcast/Self Delivery Mode

The destination shorthand field of the ICR allows the delivery mode to be by-passed in favor of broadcasting the IPI 
to all the processors on the system bus and/or back to itself (see Section 10.6.1, “Interrupt Command Register 
(ICR)”). 
Three destination shorthands are supported: self, all excluding self, and all including self. The destination 
mode is ignored when a destination shorthand is used.

10.6.2.4   Lowest Priority Delivery Mode

With lowest priority delivery mode, the ICR is programmed to send an IPI to several processors on the system bus, 
using the logical or shorthand destination mechanism for selecting the processor. The selected processors then 
arbitrate with one another over the system bus or the APIC bus, with the lowest-priority processor accepting the 
IPI. 
For systems based on the Intel Xeon processor, the chipset bus controller accepts messages from the I/O APIC 
agents in the system and directs interrupts to the processors on the system bus. When using the lowest priority 
delivery mode, the chipset chooses a target processor to receive the interrupt out of the set of possible targets. The 
Pentium 4 processor provides a special bus cycle on the system bus that informs the chipset of the current task