Intel 253666-024US Computer Hardware User Manual


 
Vol. 2A 2-9
INSTRUCTION FORMAT
2.2 IA-32E MODE
IA-32e mode has two sub-modes. These are:
Compatibility Mode. Enables a 64-bit operating system to run most legacy
protected mode software unmodified.
64-Bit Mode. Enables a 64-bit operating system to run applications written to
access 64-bit address space.
2.2.1 REX Prefixes
REX prefixes are instruction-prefix bytes used in 64-bit mode. They do the following:
Specify GPRs and SSE registers.
Specify 64-bit operand size.
Specify extended control registers.
Not all instructions require a REX prefix in 64-bit mode. A prefix is necessary only if
an instruction references one of the extended registers or uses a 64-bit operand. If a
REX prefix is used when it has no meaning, it is ignored.
Only one REX prefix is allowed per instruction. If used, the prefix must immediately
precede the opcode byte or the two-byte opcode escape prefix (if present). Other
placements are ignored. The instruction-size limit of 15 bytes still applies to instruc-
tions with a REX prefix. See Figure 2-3.
Figure 2-3. Prefix Ordering in 64-bit Mode
REX
Immediate data
of 1, 2, or 4
bytes or none
Address
displacement of
1, 2, or 4 bytes
1 byte
(if required)
1 byte
(if required)
1-, 2-, or
3-byte
opcode
(optional)
Grp 1, Grp
2, Grp 3,
Grp 4
(optional)
Legacy
Prefix
Opcode
ModR/M
SIB Displacement
Immediate
Prefixes