3-231
INSTRUCTION SET REFERENCE
FRNDINTRound to Integer
Description
This instruction rounds the source value in the ST(0) register to the nearest integral value,
depending on the current rounding mode (setting of the RC field of the FPU control word), and
stores the result in ST(0).
If the source value is
?
, the value is not changed. If the source value is not an integral value, the
floating-point inexact result exception (#P) is generated.
Operation
ST(0)
<
RoundToIntegralValue(ST(0));
FPU Flags Affected
C1
Set to 0 if stack underflow occurred.
Indicates rounding direction if the inexact result exception (#P) is gener-
ated: 0 = not roundup; 1 = roundup.
C0, C2, C3
Undefined.
Floating-Point Exceptions
#IS
Stack underflow occurred.
#IA
Source operand is an sNaN value or unsupported format.
#D
Source operand is a denormal value.
#P
Source operand is not an integral value.
Protected Mode Exceptions
#NM
EM or TS in CR0 is set.
Real-Address Mode Exceptions
#NM
EM or TS in CR0 is set.
Virtual-8086 Mode Exceptions
#NM
EM or TS in CR0 is set.
Opcode
Instruction
Description
D9 FC
FRNDINT
Round ST(0) to an integer.