[llvm-dev] ffp-model=fast ignores #pragma STDC FP_CONTRACT OFF

Joerg Sonnenberger via llvm-dev llvm-dev at lists.llvm.org
Tue Oct 26 14:26:04 PDT 2021


On Tue, Oct 26, 2021 at 04:38:13PM +0000, Kaylor, Andrew via llvm-dev wrote:
> I've brought this up before and I feel very strongly that the pragma
> should be honored even when fp-contract=fast is used on the command line.

In an ideal world, the pragma should be either honored or result in an
explicit compile-time error if it can't be honored. E.g. if the
implementation requires the pragma to be specified outside a function,
it would be reasonable to error if it should change the state when used
inside a function.

Joerg


More information about the llvm-dev mailing list