Skip to content
Commit 5854e9fa authored by David Majnemer's avatar David Majnemer
Browse files

InstSimplify: Optimize ICmpInst xform that uses computeKnownBits

A few things:
- computeKnownBits is relatively expensive, let's delay its use as long
  as we can.
- Don't create two APInt values just to run computeKnownBits on a
  ConstantInt, we already know the exact value!
- Avoid creating a temporary APInt value in order to calculate unary
  negation.

llvm-svn: 222092
parent 83c97c69
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment