Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: PowerPC System Software /
Chapter 4 - Exception Manager / Exception Manager Reference
Data Structures


Machine Information Records

The Exception Manager uses a machine information record to encode the state of the special-purpose registers at the time an exception occurs. A machine information record is defined by the MachineInformation data type.

struct MachineInformation {
   UnsignedWide         CTR;  /*Count Register*/
   UnsignedWide         LR;   /*Link Register*/
   UnsignedWide         PC;   /*Program Counter Register*/
   unsigned long        CR;   /*Condition Register*/
   unsigned long        XER;  /*Fixed-Point Exception Register*/
   unsigned long        MSR;  /*Machine State Register*/
};
typedef struct MachineInformation MachineInformation;
Note
The fields CTR, LR, and PC are declared as the 64-bit type UnsignedWide to allow compatibility with 64-bit processors.
On 32-bit processors, the register values are returned in the
low-order 32 bits. The high-order 32 bits are undefined.
Field Description
CTR
The contents of the Count Register (CTR).
LR
The contents of the Link Register (LR).
PC
The contents of the Program Counter Register (PC).
CR
The contents of the Condition Register (CR).
XER
The contents of the Fixed-Point Exception Register (XER).
MSR
The contents of the Machine State Register (MSR).

IMPORTANT
The fields of a machine information record are aligned in memory in accordance with 680x0 alignment conventions.

Previous Book Contents Book Index Next

© Apple Computer, Inc.
3 JUL 1996