-ffast-math tells the compiler to perform more aggressive floating-point optimizations.
-ffast-math results in behavior that
is not fully compliant with the ISO C or C++ standard. However, numerically robust
floating-point programs are expected to behave correctly.
aggressive floating-point optimizations. It also ensures that the floating-point
code that the compiler generates is compliant with the IEEE Standard for
Floating-Point Arithmetic (IEEE 754).
NoteARM® Compiler 6 uses neither
-fno-fast-mathby default. For the default behavior, ensure you specify neither
These options control which floating-point library the compiler uses. For more information, see the library variants in ARM C and C++ Libraries and Floating-Point Support User Guide.
Table 1-1 Floating-point library variants
||Floating-point library variant||Description|
||IEEE-compliant library with fixed rounding mode and support for certain IEEE exceptions, and flushing to zero.|
||Similar to the default behavior, but also performs aggressive floating-point optimizations and therefore it is not IEEE-compliant.|
||IEEE-compliant library with configurable rounding mode and support for all IEEE exceptions, and flushing to zero.|