[PATCH][tree-complex.c] PR tree-optimization/70291: Inline floating-point complex multiplication more aggressively

Wilco Dijkstra Wilco.Dijkstra@arm.com
Wed May 2 16:45:00 GMT 2018


Richard Biener wrote:

> why use BUILT_IN_ISUNORDERED but not a GIMPLE_COND with
> UNORDERED_EXPR?  Note again that might trap/throw with -fsignalling-nans
> so better avoid this transform for flag_signalling_nans as well...

Both currently trap on signalling NaNs due to the implementation of the C99
builtins being buggy (PR66462).

However since the inputs are results of FP operations, they are guaranteed
to be quiet NaNs in this case, so no extra test for signalling NaNs is required.

> Which also means that we can dispatch to this simple variant not only for
> flag_complex_method != 2 but for !HONOR_NANS && !HONOR_INFINITIES?
> Maybe that should be done as followup.

With -ffinite-math-only the isunordered will be optimized anyway. So it's just
to avoid generating unnecessary dead code.

Wilco


More information about the Gcc-patches mailing list