A machine mode describes a size of data object and the representation used
for it. In the C code, machine modes are represented by an enumeration
enum machine_mode, defined in `machmode.def'. Each RTL
expression has room for a machine mode and so do certain kinds of tree
expressions (declarations and types, to be precise).
In debugging dumps and machine descriptions, the machine mode of an RTL
expression is written after the expression code with a colon to separate
them. The letters `mode' which appear at the end of each machine mode
name are omitted. For example,
(reg:SI 38) is a
expression with machine mode
SImode. If the mode is
VOIDmode, it is not written at all.
Here is a table of machine modes. The term "byte" below refers to an
BITS_PER_UNIT bits (see section Storage Layout).
cc0(see see section Condition Code Status).
BLKmodewill not appear in RTL.
VOIDmodebecause they can be taken to have whatever mode the context requires. In debugging dumps of RTL,
VOIDmodeis expressed by the absence of any mode.
SCmode, DCmode, XCmode, TCmode
CQImode, CHImode, CSImode, CDImode, CTImode, COImode
The machine description defines
Pmode as a C macro which expands
into the machine mode used for addresses. Normally this is the mode
whose size is
SImode on 32-bit machines.
The only modes which a machine description must support are
QImode, and the modes corresponding to
The compiler will attempt to use
DImode for 8-byte structures and
unions, but this can be prevented by overriding the definition of
MAX_FIXED_MODE_SIZE. Alternatively, you can have the compiler
TImode for 16-byte structures and unions. Likewise, you can
arrange for the C type
short int to avoid using
Very few explicit references to machine modes remain in the compiler and
these few references will soon be removed. Instead, the machine modes
are divided into mode classes. These are represented by the enumeration
enum mode_class defined in `machmode.h'. The possible
mode classes are:
CCmodeplus any modes listed in the
EXTRA_CC_MODESmacro. See section Defining Jump Instruction Patterns, also see section Condition Code Status.
Here are some C macros that relate to machine modes:
PUT_MODE (x, newmode)
GET_MODE_SIZEexcept in the case of complex modes. For them, the unit size is the size of the real or imaginary part.
The global variables
word_mode contain modes
whose classes are
MODE_INT and whose bitsizes are either
BITS_PER_WORD, respectively. On 32-bit
machines, these are
Go to the first, previous, next, last section, table of contents.