(fneg (fma X, Y, Z)) is not equivalent to (fma (fneg X), Y, (fneg Z))
unless no signed zeros fast math flag is on.
See https://reviews.llvm.org/D90901 for a similar issue on X86.
Paths
| Differential D109523
[ARM] Remove isel patterns that start with (fneg (fma)). Changes PlannedPublic Authored by craig.topper on Sep 9 2021, 9:30 AM.
Details Summary (fneg (fma X, Y, Z)) is not equivalent to (fma (fneg X), Y, (fneg Z)) See https://reviews.llvm.org/D90901 for a similar issue on X86.
Diff Detail
Event TimelineHerald added subscribers: pengfei, hiraditya, kristof.beyls. · View Herald TranscriptSep 9 2021, 9:30 AM Comment Actions Echoing the comment in D109525 - are there tests that include 'nsz' to confirm that we can still fold those patterns?
Revision Contents
Diff 371628 llvm/lib/Target/ARM/ARMInstrVFP.td
llvm/test/CodeGen/ARM/GlobalISel/arm-instruction-select-combos.mir
llvm/test/CodeGen/ARM/GlobalISel/select-pr35926.mir
llvm/test/CodeGen/ARM/fp16-fusedMAC.ll
llvm/test/CodeGen/ARM/fusedMAC.ll |
Generate the full checks as a preliminary step, so we just see the diffs?