[PATCH] D61447: [FPEnv] WIP on threading fneg through llvm

Kevin P. Neal via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 2 09:24:39 PDT 2019


kpn created this revision.
kpn added reviewers: spatel, arsenm, andrew.w.kaylor, cameron.mcinally, craig.topper.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

This is my work-in-progress code for threading fneg from the IRBuilder on through the optimization passes. It isn't in shape to commit, but perhaps should be seen for discussion on direction at least.

At least some of the optimization passes use the IRBuilder, so adding FNeg there means the optimization passes must be changed in concert. Otherwise code quality is affected.

Currently some of the tests are still failing because the Reassociate pass doesn't know how to deal with a unary instruction. I don't know what comes after that is fixed.


Repository:
  rL LLVM

https://reviews.llvm.org/D61447

Files:
  include/llvm/IR/IRBuilder.h
  include/llvm/IR/InstrTypes.h
  include/llvm/IR/Instructions.h
  include/llvm/IR/NoFolder.h
  include/llvm/IR/PatternMatch.h
  lib/IR/Instructions.cpp
  lib/Transforms/InstCombine/InstCombineAddSub.cpp
  lib/Transforms/InstCombine/InstCombineCalls.cpp
  lib/Transforms/InstCombine/InstCombineCasts.cpp
  lib/Transforms/InstCombine/InstCombineInternal.h
  lib/Transforms/InstCombine/InstCombineMulDivRem.cpp
  lib/Transforms/Scalar/Reassociate.cpp
  test/Transforms/InstCombine/cos-1.ll
  test/Transforms/InstCombine/cos-sin-intrinsic.ll
  test/Transforms/InstCombine/fast-math.ll
  test/Transforms/InstCombine/fmul.ll
  test/Transforms/InstCombine/fpcast.ll
  test/Transforms/InstCombine/fsub.ll
  test/Transforms/InstCombine/maximum.ll
  test/Transforms/InstCombine/maxnum.ll
  test/Transforms/InstCombine/minimum.ll
  test/Transforms/InstCombine/minnum.ll
  test/Transforms/InstCombine/pow-1.ll
  test/Transforms/InstCombine/select-crash.ll
  test/Transforms/Reassociate/fast-SubReassociate.ll
  test/Transforms/Reassociate/fast-basictest.ll
  test/Transforms/Reassociate/fp-expr.ll
  unittests/IR/IRBuilderTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D61447.197802.patch
Type: text/x-patch
Size: 43473 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190502/d7d3b8ea/attachment.bin>


More information about the llvm-commits mailing list