[Bug target/104045] [AArch64] combine related to insn fmaxnm

2022-01-17 Thread joseph at codesourcery dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104045 --- Comment #5 from joseph at codesourcery dot com --- Folding the fmax operation should be valid in the absence of -fsignaling-nans (fmax (a, +Inf) should return +Inf without raising any exceptions, for any x not a signaling NaN). However, r

[Bug target/104045] [AArch64] combine related to insn fmaxnm

2022-01-15 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104045 --- Comment #4 from Andrew Pinski --- Note I don't even think llvm implements-ftrapping-math . Still not a gcc bug. There is a bug request on changing the default already opened for gcc.

[Bug target/104045] [AArch64] combine related to insn fmaxnm

2022-01-15 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104045 Andrew Pinski changed: What|Removed |Added Resolution|--- |INVALID Status|UNCONFIRMED

[Bug target/104045] [AArch64] combine related to insn fmaxnm

2022-01-15 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104045 --- Comment #2 from Andrew Pinski --- I read that wrong. We have Max. I suspect the issue is gcc has -ftrapping-math turned on by default while clang does not. Does -fno-trapping-math fix the issue?

[Bug target/104045] [AArch64] combine related to insn fmaxnm

2022-01-15 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104045 --- Comment #1 from Andrew Pinski --- I think gcc is correct and clang is wrong. Fmax treats Nan as missing data so fmax is really just a.