| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
| |
icmp slt i32 %X, 0 ; <i1>:0 [#uses=1]
sext i1 %0 to i32 ; <i32>:1 [#uses=1]
into:
%X.lobit = ashr i32 %X, 31 ; <i32> [#uses=1]
This implements InstCombine/icmp.ll:test[34]
llvm-svn: 35891
|
|
|
|
|
|
| |
Transforms/InstCombine/icmp.ll
llvm-svn: 35890
|
|
|
|
| |
llvm-svn: 35886
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
define i32 @test(i32 %X) {
entry:
%Y = and i32 %X, 4 ; <i32> [#uses=1]
icmp eq i32 %Y, 0 ; <i1>:0 [#uses=1]
sext i1 %0 to i32 ; <i32>:1 [#uses=1]
ret i32 %1
}
by moving code out of commonIntCastTransforms into visitZExt. Simplify the
APInt gymnastics in it etc.
llvm-svn: 35885
|
|
|
|
|
|
| |
InstCombine/set.ll:test25
llvm-svn: 35852
|
|
|
|
| |
llvm-svn: 35792
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Transforms/InstCombine/vec_insertelt.ll and fixes PR1286.
We now compile the code from that bug into:
_foo:
movl 4(%esp), %eax
movdqa (%eax), %xmm0
movl 8(%esp), %ecx
psllw (%ecx), %xmm0
movdqa %xmm0, (%eax)
ret
instead of:
_foo:
subl $4, %esp
movl %ebp, (%esp)
movl %esp, %ebp
movl 12(%ebp), %eax
movdqa (%eax), %xmm0
#IMPLICIT_DEF %eax
pinsrw $2, %eax, %xmm0
xorl %ecx, %ecx
pinsrw $3, %ecx, %xmm0
pinsrw $4, %eax, %xmm0
pinsrw $5, %ecx, %xmm0
pinsrw $6, %eax, %xmm0
pinsrw $7, %ecx, %xmm0
movl 8(%ebp), %eax
movdqa (%eax), %xmm1
psllw %xmm0, %xmm1
movdqa %xmm1, (%eax)
movl %ebp, %esp
popl %ebp
ret
woo :)
llvm-svn: 35788
|
|
|
|
| |
llvm-svn: 35765
|
|
|
|
| |
llvm-svn: 35763
|
|
|
|
|
|
|
|
| |
constants.
Add a new xform to simplify (A&B)|(~A&C). THis implements InstCombine/or2.ll:test1
llvm-svn: 35760
|
|
|
|
| |
llvm-svn: 35700
|
|
|
|
|
|
| |
elsewhere.
llvm-svn: 35668
|
|
|
|
| |
llvm-svn: 35665
|
|
|
|
| |
llvm-svn: 35655
|
|
|
|
|
|
|
|
| |
some constant exprs to apints).
Thanks to Anton for tracking down a small testcase that triggered this!
llvm-svn: 35633
|
|
|
|
|
|
| |
ldecod now passes.
llvm-svn: 35626
|
|
|
|
|
|
| |
others) on ARM.
llvm-svn: 35620
|
|
|
|
|
|
| |
visitICmpInstWithInstAndIntCst.
llvm-svn: 35614
|
|
|
|
| |
llvm-svn: 35612
|
|
|
|
|
|
| |
2. Use cheaper APInt methods.
llvm-svn: 35594
|
|
|
|
| |
llvm-svn: 35593
|
|
|
|
| |
llvm-svn: 35588
|
|
|
|
| |
llvm-svn: 35587
|
|
|
|
|
|
| |
test/Transforms/InstCombine/xor.ll:test28
llvm-svn: 35584
|
|
|
|
| |
llvm-svn: 35561
|
|
|
|
| |
llvm-svn: 35555
|
|
|
|
|
|
| |
Support overloaded intrinsics bswap, ctpop, cttz, ctlz.
llvm-svn: 35547
|
|
|
|
| |
llvm-svn: 35536
|
|
|
|
| |
llvm-svn: 35525
|
|
|
|
| |
llvm-svn: 35524
|
|
|
|
| |
llvm-svn: 35510
|
|
|
|
|
|
|
|
| |
amount is safe.
2. Use new method on ConstantInt instead of (? :) operator.
3. Use new method uge() on ConstantInt to simplify codes.
llvm-svn: 35505
|
|
|
|
| |
llvm-svn: 35503
|
|
|
|
|
|
|
| |
2. Let APInt variable do the binary operation stuff instead of using
ConstantExpr::getXXX.
llvm-svn: 35450
|
|
|
|
| |
llvm-svn: 35446
|
|
|
|
|
|
|
|
| |
1. Line out nested call of APInt::zext/trunc.
2. Make more use of APInt::getHighBitsSet/getLowBitsSet.
3. Use APInt[] operator instead of expression like "APIntVal & SignBit".
llvm-svn: 35444
|
|
|
|
|
|
|
|
| |
instead of using ConstantExpr::getXX.
2. Use constant reference to APInt if possible instead of expensive
APInt copy.
llvm-svn: 35443
|
|
|
|
| |
llvm-svn: 35431
|
|
|
|
|
|
|
|
| |
2. Use APInt[] instead of "X & SignBit".
3. Clean up some codes.
4. Make the expression like "ShiftAmt = ShiftAmtC->getZExtValue()" safe.
llvm-svn: 35424
|
|
|
|
|
|
|
| |
2. Make the APInt value do the zext/trunc stuff instead of using
ConstantExpr::getZExt().
llvm-svn: 35422
|
|
|
|
| |
llvm-svn: 35418
|
|
|
|
| |
llvm-svn: 35414
|
|
|
|
|
|
|
|
| |
1. Line out nested use of zext/trunc.
2. Make more use of getHighBitsSet/getLowBitsSet.
3. Use APInt[] != 0 instead of "(APInt & SignBit) != 0".
llvm-svn: 35408
|
|
|
|
|
|
|
| |
When converting an add/xor/and triplet into a trunc/sext, only do so if the
intermediate integer type is a bitwidth that the targets can handle.
llvm-svn: 35400
|
|
|
|
| |
llvm-svn: 35383
|
|
|
|
| |
llvm-svn: 35373
|
|
|
|
|
|
| |
Fix another incorrectly converted shift mask.
llvm-svn: 35371
|
|
|
|
| |
llvm-svn: 35361
|
|
|
|
|
|
|
|
| |
original and new instruction. A slight performance hit with ostringstream
but it is only for debug.
Also, clean up an uninitialized variable warning noticed in a release build.
llvm-svn: 35358
|
|
|
|
| |
llvm-svn: 35357
|