[PATCH] D35044: [IR] Remove the opcode argument from CmpInst::Create

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 6 00:15:29 PDT 2017


craig.topper created this revision.
Herald added subscribers: mzolotukhin, sanjoy.

The predicate argument alone should be enough to determine the class that needs to be created.

For some cases where we were always creating an ICmpInst I used the ICmpInst constructor directly. I can do that as a separate patch if that's prefered.

Do I need to be concerned with out of tree users of this?

Not sure who the best reviewers of this are. The CmpInst::Create function has been untouched for many years.


https://reviews.llvm.org/D35044

Files:
  include/llvm/IR/InstrTypes.h
  lib/CodeGen/CodeGenPrepare.cpp
  lib/IR/Constants.cpp
  lib/IR/Instructions.cpp
  lib/Transforms/InstCombine/InstCombineCompares.cpp
  lib/Transforms/InstCombine/InstCombinePHI.cpp
  lib/Transforms/InstCombine/InstCombineSelect.cpp
  lib/Transforms/Vectorize/LoopVectorize.cpp
  tools/llvm-stress/llvm-stress.cpp
  unittests/Analysis/ScalarEvolutionTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35044.105378.patch
Type: text/x-patch
Size: 12163 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170706/2f8d6b20/attachment.bin>


More information about the llvm-commits mailing list