Rust defines f32 and f64 as IEEE 754-2008 compliant, where NEON instructions on ARMv7-A only comply with 754-1985 (last paragraph on the page). Of particular interest is the lack of support for subnormal numbers. Quoting (denormals is the 1985, renamed to subnormals in 2008):
Additionally, NEON instructions always treats denormals as zero.
I was not able to find information on how clang/LLVM treats this, nor do I have access to IEEE 754, but at least GCC considers this non-compliant:
If the selected floating-point hardware includes the NEON extension (e.g. -mfpu=neon), note that floating-point operations are not generated by GCC’s auto-vectorization pass unless -funsafe-math-optimizations is also specified. This is because NEON hardware does not fully implement the IEEE 754 standard for floating-point arithmetic (in particular denormal values are treated as zero), so the use of NEON instructions may lead to a loss of precision.
My question here, is, how does
rustc handle this? Is NEON math used without additional flags?