13.07.2015 Views

Volume 3: General-Purpose and System Instructions - Stanford ...

Volume 3: General-Purpose and System Instructions - Stanford ...

Volume 3: General-Purpose and System Instructions - Stanford ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

24594 Rev. 3.10 February 2005 AMD64 Technology1 Instruction FormatsThe format of an instruction encodes its operation, as well asthe locations of the instruction’s initial oper<strong>and</strong>s <strong>and</strong> the resultof the operation. This section describes the general format <strong>and</strong>parameters used by all instructions. For information on thespecific format(s) for each instruction, see:• Chapter 3, “<strong>General</strong>-<strong>Purpose</strong> Instruction Reference.”• Chapter 4, “<strong>System</strong> Instruction Reference.”• “128-Bit Media Instruction Reference” in <strong>Volume</strong> 4.• “64-Bit Media Instruction Reference” in <strong>Volume</strong> 5.• “x87 Floating-Point Instruction Reference” in <strong>Volume</strong> 5.1.1 Instruction Byte OrderAn instruction can be between one <strong>and</strong> 15 bytes in length.Figure 1-1 shows the byte order of the instruction format.LegacyPrefixREXPrefixOpcode(1 or 2 bytes) ModRM SIBDisplacement(1, 2, or 4 bytes)Immediate(1, 2, or 4 bytes)Instruction Length ≤ 15 BytesFigure 1-1.Instruction Byte-Order<strong>Instructions</strong> are stored in memory in little-endian order. Theleast-significant byte of an instruction is stored at its lowestmemory address, as shown in Figure 1-2 on page 2.Chapter 1: Instruction Formats 1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!