User Guide
128-Bit Media and Scientific Programming 133
24592—Rev. 3.15—November 2009 AMD64 Technology
in interval arithmetic, in which upper and lower bounds bracket the true result of a computation.
Round toward zero takes the smaller in magnitude, that is, always truncates.
The processor produces a floating-point result defined by the IEEE standard to be infinitely precise.
This result may n ot be representable exactly in the destination format, because only a subset of the
continuum of real numbers finds exact representation in any particular floating-point format.
Rounding modifies such a result to conform to the destination format, thereby making the result
inexact and also generating a precision exception (PE), as described in “SIMD Floating-Point
Exception Causes” on page 178.
Suppose, for example, the following 24-bit result is to be represented in single-precision format, where
“
E
2
1010” represents the biased exponent:
1.0011 0101 0000 0001 0010 0111 E
2
1010
This result has no exact representation, because the least-significant 1 does not fit into the single-
precision format, which allows for only 23 bits of fraction. The rounding control field determines the
direction of rounding. Rounding introduces an error in a result that is less than one unit in the last place
(ulp), that is, the least-significant bit position of the floating-point representation.
4.5 Instruction Summary—Integer Instructions
This section summarizes functions of the integer instructions in the 128-bit media instruction subset.
These include integer instructions that use an XMM register for source or destination and data-
conversion instructions that convert from integers to floating-point formats. For a summary of the
floating-point instructions in the 128-bit media instruction subset, including data-conversion
instructions that convert from floating-point to integer formats, see “Instruction Summary—Floating-
Point Instructions” on page 156.
The instructions are organized here by functional group—such as data-transfer, vector arithmetic, and
so on. Software running at any privilege level can use any of these instructions, if the CPUID
instruction reports support for the instructions (see “Feature Detection” on page 176). More detail on
individual instructions is given in the alphabetically organized “128-Bit Media Instruction Reference”
in Volume 4.
4.5.1 Syntax
Each instruction has a mnemonic syntax used by assemblers to specify the operation and the operands
to be used for source and destination (result) data. The majority of 128-bit media integer instructions
have the following syntax:
MNEMONIC xmm1, xmm2/mem128
Figure 4-16 on page 134 shows an example of the mnemonic syntax for a packed add bytes (PADDB)
instruction.