[PATCH] D87037: [DAGCombiner] Propagate FMF flags in FMA folding

Qiu Chaofan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Sep 7 19:52:05 PDT 2020


qiucf added inline comments.


================
Comment at: llvm/test/CodeGen/PowerPC/fma-combine.ll:293
+; CHECK-FAST-NEXT:    xxswapd 0, 0
+; CHECK-FAST-NEXT:    xvmaddadp 34, 34, 0
+; CHECK-FAST-NEXT:    blr
----------------
spatel wrote:
> I can't tell if anything is changing on this test with this patch. Should this not reduce to 'xor' like the scalar code?
For the `NOVSX` check: `v2f64` isn't legal, so result before this patch is `fsub+fsub`. Now it returns constants.

If VSX is enabled, combiner will not meet the condition, since `ConstantFPSDNode` not works for vectors. So result doesn't change.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D87037/new/

https://reviews.llvm.org/D87037



More information about the llvm-commits mailing list