| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
| |
empty string for ConstantAggregateZero case which surprises selectiondag.
- Correctly handle memcpy from constant string which is zero-initialized.
llvm-svn: 52891
|
|
|
|
|
|
|
|
|
|
|
|
| |
Move GetConstantStringInfo to lib/Analysis. Remove
string output routine from Constant. Update all
callers. Change debug intrinsic api slightly to
accomodate move of routine, these now return values
instead of strings.
This unbreaks llvm-gcc bootstrap.
llvm-svn: 52884
|
|
|
|
|
|
|
|
|
| |
string output routine from Constant. Update all
callers. Change debug intrinsic api slightly to
accomodate move of routine, these now return values
instead of strings.
llvm-svn: 52748
|
|
|
|
| |
llvm-svn: 52702
|
|
|
|
|
|
|
|
| |
15).
See also PR1800, which is about the signed case.
llvm-svn: 52608
|
|
|
|
|
|
| |
load.
llvm-svn: 52525
|
|
|
|
| |
llvm-svn: 52502
|
|
|
|
|
|
| |
directly.
llvm-svn: 52498
|
|
|
|
| |
llvm-svn: 52466
|
|
|
|
| |
llvm-svn: 52442
|
|
|
|
|
|
| |
implements rdar://6013816 and the testcase in Transforms/InstCombine/sext-misc.ll.
llvm-svn: 52440
|
|
|
|
|
|
| |
Spotted by Nick Lewycky.
llvm-svn: 52411
|
|
|
|
|
|
| |
friends.
llvm-svn: 52318
|
|
|
|
| |
llvm-svn: 52316
|
|
|
|
|
|
|
|
|
|
| |
I'm at it, rename it to FindInsertedValue.
The only functional change is that newly created instructions are no longer
added to instcombine's worklist, but that is not really necessary anyway (and
I'll commit some improvements next that will completely remove the need).
llvm-svn: 52315
|
|
|
|
|
|
| |
when trying to sink stores.
llvm-svn: 52259
|
|
|
|
|
|
|
| |
structure checks are incorrect if the blocks aren't distinct.
Fixes PR2435.
llvm-svn: 52257
|
|
|
|
| |
llvm-svn: 52247
|
|
|
|
| |
llvm-svn: 52246
|
|
|
|
|
|
|
|
| |
useless insert-extract chains, similar to how it folds them for vectors.
Add a testcase for this.
llvm-svn: 52217
|
|
|
|
| |
llvm-svn: 52212
|
|
|
|
|
|
| |
don't make i1 phis when it won't be possible to eliminate them.
llvm-svn: 52097
|
|
|
|
|
|
| |
otherwise, opt might crash.
llvm-svn: 52041
|
|
|
|
|
|
|
|
| |
crash the opt. Just fix this.
Test case in llvm/test/Transforms/InstCombine/2008-06-05-ashr-crash.ll
llvm-svn: 52003
|
|
|
|
| |
llvm-svn: 51864
|
|
|
|
|
|
|
| |
out of instcombine into a new file in libanalysis. This also teaches
ComputeNumSignBits about the number of sign bits in a constantint.
llvm-svn: 51863
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the conditions for performing the transform when only the
function declaration is available: no longer allow turning
i32 into i64 for example. Only allow changing between
pointer types, and between pointer types and integers of
the same size. For return values ptr -> intptr was already
allowed; I added ptr -> ptr and intptr -> ptr while there.
As shown by a recent objc testcase, changing the way
parameters/return values are passed can be fatal when calling
code written in assembler that directly manipulates call
arguments and return values unless the transform has no
impact on the way they are passed at the codegen level.
While it is possible to imagine an ABI that treats integers
of pointer size differently to pointers, I don't think LLVM
supports any so the transform should now be safe while still
being useful.
llvm-svn: 51834
|
|
|
|
| |
llvm-svn: 51819
|
|
|
|
| |
llvm-svn: 51817
|
|
|
|
| |
llvm-svn: 51816
|
|
|
|
| |
llvm-svn: 51698
|
|
|
|
| |
llvm-svn: 51636
|
|
|
|
|
|
|
|
|
|
| |
Analysis/ConstantFolding to fold ConstantExpr's, then make instcombine use it
to try to use targetdata to fold constant expressions on void instructions.
Also extend the icmp(inttoptr, inttoptr) folding to handle the case where
int size != ptr size.
llvm-svn: 51559
|
|
|
|
|
|
| |
This fixes PR2359
llvm-svn: 51536
|
|
|
|
|
|
| |
use it instead of duplicating its functionality.
llvm-svn: 51499
|
|
|
|
| |
llvm-svn: 51482
|
|
|
|
| |
llvm-svn: 51476
|
|
|
|
| |
llvm-svn: 51475
|
|
|
|
| |
llvm-svn: 51474
|
|
|
|
| |
llvm-svn: 51472
|
|
|
|
| |
llvm-svn: 51471
|
|
|
|
|
|
|
| |
and/or to handle more cases (such as this add-sitofp.ll testcase), and
port it to selectiondag's ComputeNumSignBits.
llvm-svn: 51469
|
|
|
|
|
|
| |
exclude struct and array types.
llvm-svn: 51467
|
|
|
|
|
|
| |
now that instcombine also has ComputeNumSignBits.
llvm-svn: 51350
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(add (sext x), cst) --> (sext (add x, cst'))
(add (sext x), (sext y)) --> (sext (add int x, y))
(add double (sitofp x), fpcst) --> (sitofp (add int x, intcst))
(add double (sitofp x), (sitofp y)) --> (sitofp (add int x, y))
This generally reduces conversions. For example MiBench/telecomm-gsm
gets these simplifications:
HACK2: %tmp67.i142.i.i = sext i16 %tmp6.i141.i.i to i32 ; <i32> [#uses=1]
%tmp23.i139.i.i = sext i16 %tmp2.i138.i.i to i32 ; <i32> [#uses=1]
%tmp8.i143.i.i = add i32 %tmp67.i142.i.i, %tmp23.i139.i.i ; <i32> [#uses=3]
HACK2: %tmp67.i121.i.i = sext i16 %tmp6.i120.i.i to i32 ; <i32> [#uses=1]
%tmp23.i118.i.i = sext i16 %tmp2.i117.i.i to i32 ; <i32> [#uses=1]
%tmp8.i122.i.i = add i32 %tmp67.i121.i.i, %tmp23.i118.i.i ; <i32> [#uses=3]
HACK2: %tmp67.i.i190.i = sext i16 %tmp6.i.i189.i to i32 ; <i32> [#uses=1]
%tmp23.i.i187.i = sext i16 %tmp2.i.i186.i to i32 ; <i32> [#uses=1]
%tmp8.i.i191.i = add i32 %tmp67.i.i190.i, %tmp23.i.i187.i ; <i32> [#uses=3]
HACK2: %tmp67.i173.i.i.i = sext i16 %tmp6.i172.i.i.i to i32 ; <i32> [#uses=1]
%tmp23.i170.i.i.i = sext i16 %tmp2.i169.i.i.i to i32 ; <i32> [#uses=1]
%tmp8.i174.i.i.i = add i32 %tmp67.i173.i.i.i, %tmp23.i170.i.i.i ; <i32> [#uses=3]
HACK2: %tmp67.i152.i.i.i = sext i16 %tmp6.i151.i.i.i to i32 ; <i32> [#uses=1]
%tmp23.i149.i.i.i = sext i16 %tmp2.i148.i.i.i to i32 ; <i32> [#uses=1]
%tmp8.i153.i.i.i = add i32 %tmp67.i152.i.i.i, %tmp23.i149.i.i.i ; <i32> [#uses=3]
HACK2: %tmp67.i.i.i.i = sext i16 %tmp6.i.i.i.i to i32 ; <i32> [#uses=1]
%tmp23.i.i5.i.i = sext i16 %tmp2.i.i.i.i to i32 ; <i32> [#uses=1]
%tmp8.i.i7.i.i = add i32 %tmp67.i.i.i.i, %tmp23.i.i5.i.i ; <i32> [#uses=3]
This also fixes a bug in ComputeNumSignBits handling select and
makes it more aggressive with and/or.
llvm-svn: 51302
|
|
|
|
| |
llvm-svn: 51296
|
|
|
|
| |
llvm-svn: 51290
|
|
|
|
|
|
| |
code in SelectionDAG.
llvm-svn: 51279
|
|
|
|
| |
llvm-svn: 51275
|
|
|
|
|
|
| |
produce a negative zero.
llvm-svn: 51272
|