[PATCH] D76419: [DAGCombiner] Add nsz constraint to aggressive fma folding

Qiu Chaofan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Mar 22 08:31:13 PDT 2020


qiucf marked an inline comment as done.
qiucf added inline comments.


================
Comment at: llvm/test/CodeGen/PowerPC/fma-assoc.ll:133-136
+  %F = fmul nsz double %A, %B         ; <double> [#uses=1]
+  %G = fmul nsz double %C, %D         ; <double> [#uses=1]
+  %H = fadd nsz double %F, %G         ; <double> [#uses=1]
+  %I = fsub nsz double %E, %H         ; <double> [#uses=1]
----------------
spatel wrote:
> That's not what I was hoping for, but I see now that this whole test file should be updated. We should treat "-enable-unsafe-fp-math" on the RUN line as deprecated and replace that with "fast" or "reassoc" in the IR. But that will require duplicating tests if I'm seeing it correctly.
> 
> I won't block this correctness fix on the test improvements, but please make that change as an NFC follow-up or least mark this file with a FIXME.
Thanks for explanation. I committed rGc1bc56bf4f and rG996dc13dc first and then this one. BTW, options/flags for FP operations may sometimes be confusing. It seems they should be clarified/reorganized.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D76419





More information about the llvm-commits mailing list