3-646
INSTRUCTION SET REFERENCE
SHUFPS—Shuffle Single-FP
Description
The SHUFPS instruction is able to shuffle any of the four SP FP numbers from xmm1 to the
lower two destination fields; the upper two destination fields are generated from a shuffle of any
of the four SP FP numbers from xmm2/m128.
Example 3-1. SHUFPS Instruction
By using the same register for both sources, SHUFPS can return any combination of the four SP
FP numbers from this register. Bits 0 and 1 of the immediate field are used to select which of the
four input SP FP numbers will be put in the first SP FP number of the result; bits 3 and 2 of the
immediate field are used to select which of the four input SP FP will be put in the second SP FP
number of the result; etc.
Opcode
Instruction
Description
0F,C6,/r, ib
SHUFPS xmm1, xmm2/m128, imm8
Shuffle Single.
X4
X3
X2
X1
Y4
Y3
Y2
Y1
{Y4 ... Y1}{Y4 ... Y1}{X4 ... X1}{X4 ... X1}
xmm1
xmm2/m128
xmm1