[PATCH] D28448: InstCombine: Do unsafe math combine of fadd + fmuladd + fmul

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Jan 7 12:25:42 PST 2017


arsenm created this revision.
arsenm added a subscriber: llvm-commits.
Herald added a subscriber: wdng.

(fadd (fmuladd x, y, (fmul u, v), z) -> (fma x, y (fmuladd u, v, z)))

      

DAGCombiner already does this for fma/fmad. InstCombine should be able
to do it for unsafe fmuladds, fma depends on whether it is fast for the
 target.


https://reviews.llvm.org/D28448

Files:
  lib/Transforms/InstCombine/InstCombineAddSub.cpp
  test/Transforms/InstCombine/fmuladd-opt.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D28448.83533.patch
Type: text/x-patch
Size: 9803 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170107/3bc78911/attachment.bin>


More information about the llvm-commits mailing list