### ieeefp

Controls whether floating point comparisons and some other optimizations are performed as per the IEEE standard. The default is off.

##### Syntax

#pragma ieeefp on | off

Parameters

on

> Floating-point comparisons are done using these conditions:

> - checks for NANs are not performed in comparisons, floating-point conditional moves, or integer conditional moves with floating-point tests in the condition
> - divides of all constants are changed to multiples of 1.0/constant
> - when performing float->integer conversions, the control word is reset to the assumed default of “round to nearest” instead of the original value, saving a few read/writes as the operation is performed

off

> Floating-point comparisons are done using IEEE standards.

##### Targets

Intel x86

##### Remarks

Use #pragma ieeefp on to reduce floating-point accuracy and increase calculation speed. The same effect can be achieved in the command-line using -opt ieeefp or -fast_math off commands.

Use #pragma ieeefp off to maximize floating-point accuracy and decrease calculation speed. The same effect can be achieved in the command-line using -opt noieeefp or -fast_math on commands.

This pragma corresponds to the Relax IEEE floating point setting in the processor-specific CodeGen panel. To check this setting, use __option (ieeefp), described in Checking Settings. By default, this setting is on.