- May 27, 2011
-
-
Chandler Carruth authored
This looks like it flagged an actual bug. Devang, please review. I added the parentheses that change behavior, but make the behavior more closely match commit log's intent. llvm-svn: 132165
-
Devang Patel authored
llvm-svn: 132164
-
Chad Rosier authored
crc32.[8|16|32] have been renamed to .crc32.32.[8|16|32] and crc64.[8|16|32] have been renamed to .crc32.64.[8|64]. llvm-svn: 132163
-
Devang Patel authored
llvm-svn: 132161
-
- May 26, 2011
-
-
Devang Patel authored
If llvm.dbg.value and the value instruction it refers to are far apart then iSel may not be able to find corresponding Node for llvm.dbg.value during DAG construction. Make iSel's life easier by removing this distance between llvm.dbg.value and its value instruction. llvm-svn: 132151
-
Andrew Trick authored
Use a proper worklist for use-def traversal without holding onto an iterator. Now that we process all IV uses, we need complete logic for resusing existing derived IV defs. See HoistStep. llvm-svn: 132103
-
Eli Friedman authored
llvm-svn: 132097
-
- May 25, 2011
-
-
Evan Cheng authored
llvm-svn: 132071
-
Andrew Trick authored
cleanup and overdue test cases. llvm-svn: 132038
-
Evan Cheng authored
llvm-svn: 132025
-
Evan Cheng authored
case of a switch instruction. Back off this optimization when this would eliminate all of the predecessors to the latch. Sorry, I am unable to reduce a reasonably sized test case. rdar://9486843 llvm-svn: 132022
-
- May 24, 2011
-
-
Eli Friedman authored
Make instcombine O(N) instead of O(N^2) in code where the same simplifiable constant is used many times. Part of rdar://9471075. llvm-svn: 131979
-
Cameron Zwarich authored
llvm-svn: 131956
-
Cameron Zwarich authored
promoting allocas to SSA variables. Fixes <rdar://problem/9479036>. llvm-svn: 131953
-
- May 23, 2011
-
-
Dan Gohman authored
This fixes PR9845. llvm-svn: 131919
-
Chris Lattner authored
xform recurse. llvm-svn: 131888
-
Chris Lattner authored
in a known-non-zero context. llvm-svn: 131887
-
Chris Lattner authored
for a constant directly. Thanks to Duncan for pointing this out. llvm-svn: 131885
-
Chris Lattner authored
aligned. Teach memcpyopt to not give up all hope when confonted with an underaligned memcpy feeding an overaligned byval. If the *source* of the memcpy can be determined to be adequeately aligned, or if it can be forced to be, we can eliminate the memcpy. This addresses PR9794. We now compile the example into: define i32 @f(%struct.p* nocapture byval align 8 %q) nounwind ssp { entry: %call = call i32 @g(%struct.p* byval align 8 %q) nounwind ret i32 %call } in both x86-64 and x86-32 mode. We still don't get a tailcall though, because tailcalls apparently can't handle byval. llvm-svn: 131884
-
- May 22, 2011
-
-
Chris Lattner authored
llvm-svn: 131862
-
Chris Lattner authored
result is non-zero. Implement an example optimization (PR9814), which allows us to transform: A / ((1 << B) >>u 2) into: A >>u (B-2) which we compile into: _divu3: ## @divu3 leal -2(%rsi), %ecx shrl %cl, %edi movl %edi, %eax ret instead of: _divu3: ## @divu3 movb %sil, %cl movl $1, %esi shll %cl, %esi shrl $2, %esi movl %edi, %eax xorl %edx, %edx divl %esi, %eax ret llvm-svn: 131860
-
Chris Lattner authored
failing to form a memset, then having to delete it" but my approximation isn't safe for self recurrent loops. Instead of doign a hack, just do it the right way. llvm-svn: 131858
-
Frits van Bommel authored
Add a parameter to ConstantFoldTerminator() that callers can use to ask it to also clean up the condition of any conditional terminator it folds to be unconditional, if that turns the condition into dead code. This just means it calls RecursivelyDeleteTriviallyDeadInstructions() in strategic spots. It defaults to the old behavior. I also changed -simplifycfg, -jump-threading and -codegenprepare to use this to produce slightly better code without any extra cleanup passes (AFAICT this was the only place in -simplifycfg where now-dead conditions of replaced terminators weren't being cleaned up). The only other user of this function is -sccp, but I didn't read that thoroughly enough to figure out whether it might be holding pointers to instructions that could be deleted by this. llvm-svn: 131855
-
Chris Lattner authored
"stored once" even if its address is compared. llvm-svn: 131849
-
Chris Lattner authored
causing it to get into infinite loops when it would widen a load (which can necessarily leave around dead loads). llvm-svn: 131847
-
Nick Lewycky authored
of the inlinee to the code representing the original function. llvm-svn: 131838
-
- May 21, 2011
-
-
Eli Friedman authored
consistently. llvm-svn: 131803
-
Benjamin Kramer authored
It's better to do this in codegen, mul.with.overflow(X, 2) is more canonical because it has only one use on "X". llvm-svn: 131798
-
Benjamin Kramer authored
llvm-svn: 131789
-
- May 20, 2011
-
-
Andrew Trick authored
No functionality enabled by default. Use -disable-iv-rewrite. Extended IVUsers to keep track of the phi that represents the users' IV. Added the WidenIV transform to replace a narrow IV with a wide IV by doing a one-for-one replacement of IV users instead of expanding the SCEV expressions. [sz]exts are removed and truncs are inserted. llvm-svn: 131744
-
Andrew Trick authored
llvm-svn: 131716
-
-
- May 19, 2011
-
-
Devang Patel authored
Reapply r131605. This time with a fix, which is to use NoFolder. llvm-svn: 131673
-
Evan Cheng authored
llvm-svn: 131659
-
Rafael Espindola authored
llvm-svn: 131620
-
Eli Friedman authored
I'm not sure this is quite ideal, but I can't really think of any better way to do it. llvm-svn: 131616
-
Devang Patel authored
llvm-svn: 131609
-
Devang Patel authored
llvm-svn: 131607
-
Devang Patel authored
llvm-svn: 131605
-
Eli Friedman authored
llvm-svn: 131604
-