IA-32 Assembly Language Reference Manual

Real Transfer Instructions

Load Real (fld)

fld{lst}
Operation

SRC -> STACK ELEMENT 0

Description

The source operand is pushed onto the stack by fld. The register used before the stack top-pointer is decremented, is the register number used if the source is a register.

Example

Load stack element 7 onto stack element 0.

fld %st (7)

Store Real (fst)

fst{ls}
Operation

STACK ELEMENT 0 -> DESTINATION

Description

The current value of stack element 0 is copied to the destination. The destination can be a single- or double-real memory operand or another register.

Example

Store the contents of stack element 7 onto stack element 0.

%fst (7)

Store Real and Pop (fstp)

fstp{lst}
Operation

STACK ELEMENT 0 -> DESTINATION THEN POP

Description

The current value of stack element 0 is copied to the destination. The destination can be a single-, double-, or extended-real memory operand, or another register. Then pop the stack register.

Example

Copy the contents of stack element 0 onto stack element 7 and pop stack element 0.

%fstp (7)

Exchange Registers (fxch)

fxch
Example

Exchange the contents of stack element 0 and stack element 7.

fxch %st(7)