Developer Guide and Reference

Contents

fp-speculation, Qfp-speculation

Tells the compiler the mode in which to speculate on floating-point operations.

Syntax

Linux:
-fp-speculation
=
mode
macOS:
-fp-speculation
=
mode
Windows:
/Qfp-speculation
:
mode
Arguments
mode
Is the mode for floating-point operations. Possible values are:
fast
Tells the compiler to speculate on floating-point operations.
safe
Tells the compiler to disable speculation if there is a possibility that the speculation may cause a floating-point exception.
strict
Tells the compiler to disable speculation on floating-point operations.
off
This is the same as specifying strict.
Default
-fp-speculation=fast
or
/Qfp-speculation:fast
The compiler speculates on floating-point operations. This is also the behavior when optimizations are enabled. However, if you specify no optimizations (
-O0
on Linux*
;
/Od
on Windows*
), the default is
-fp-speculation=safe
(Linux*)
or
/Qfp-speculation:safe
(Windows*)
.
Description
This option tells the compiler the mode in which to speculate on floating-point operations.
Disabling speculation may prevent the vectorization of some loops containing conditionals. For an example, see the article titled:
Diagnostic 15326: loop was not vectorized: implied FP exception model prevents vectorization
, which is located in https://software.intel.com/en-us/articles/fdiag15326 .
Alternate Options
None

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804