summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* improve the setcc -> setcc_carry optimization to happen moreChris Lattner2010-12-193-12/+34
| | | | | | | | consistently by moving it out of lowering into dag combine. Add some missing patterns for matching away extended versions of setcc_c. llvm-svn: 122201
* Fix PR8811 by teaching MachineVerifier about optional defs.Cameron Zwarich2010-12-191-3/+3
| | | | llvm-svn: 122199
* StrongPHIElimination will never run before TwoAddressInstructionPass.Cameron Zwarich2010-12-191-1/+0
| | | | llvm-svn: 122197
* simplify some code to just reuse a setcc if we can instead of Chris Lattner2010-12-191-11/+16
| | | | | | going through the CSE maps to get it. llvm-svn: 122196
* Add missing standard headers. Patch by Joerg Sonnenberger!Nick Lewycky2010-12-1914-0/+14
| | | | llvm-svn: 122193
* Add missing std:: prefixes to some calls. C++ doesn't require that <cfoo>Nick Lewycky2010-12-194-6/+6
| | | | | | | headers provide symbols outside namespace std and the LLVM coding standards state that we should prefix all of them. llvm-svn: 122192
* teach MaskedValueIsZero how to analyze ADDE. This isChris Lattner2010-12-191-2/+13
| | | | | | | enough to teach it that ADDE(0,0) is known 0 except the low bit, for example. llvm-svn: 122191
* tidy upChris Lattner2010-12-191-18/+17
| | | | llvm-svn: 122190
* now that generic vector types aren't selected onto MMX operations,Chris Lattner2010-12-191-8/+4
| | | | | | we don't need -disable-mmx anymore. llvm-svn: 122189
* reduce copy/paste programming with the power of for loops.Chris Lattner2010-12-191-40/+25
| | | | llvm-svn: 122187
* X86 supports i8/i16 overflow ops (except i8 multiplies), we shouldChris Lattner2010-12-191-17/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | generate them. Now we compile: define zeroext i8 @X(i8 signext %a, i8 signext %b) nounwind ssp { entry: %0 = tail call %0 @llvm.sadd.with.overflow.i8(i8 %a, i8 %b) %cmp = extractvalue %0 %0, 1 br i1 %cmp, label %if.then, label %if.end into: _X: ## @X ## BB#0: ## %entry subl $12, %esp movb 16(%esp), %al addb 20(%esp), %al jo LBB0_2 Before we were generating: _X: ## @X ## BB#0: ## %entry pushl %ebp movl %esp, %ebp subl $8, %esp movb 12(%ebp), %al testb %al, %al setge %cl movb 8(%ebp), %dl testb %dl, %dl setge %ah cmpb %cl, %ah sete %cl addb %al, %dl testb %dl, %dl setge %al cmpb %al, %ah setne %al andb %cl, %al testb %al, %al jne LBB0_2 llvm-svn: 122186
* move a transformation to a more logical place, simplifying it.Chris Lattner2010-12-192-16/+7
| | | | llvm-svn: 122183
* recognize an unsigned add with overflow idiom into uadd.Chris Lattner2010-12-192-25/+51
| | | | | | | | | | | | | | | | | | | | | | | | | This resolves a README entry and technically resolves PR4916, but we still get poor code for the testcase in that PR because GVN isn't CSE'ing uadd with add, filed as PR8817. Previously we got: _test7: ## @test7 addq %rsi, %rdi cmpq %rdi, %rsi movl $42, %eax cmovaq %rsi, %rax ret Now we get: _test7: ## @test7 addq %rsi, %rdi movl $42, %eax cmovbq %rsi, %rax ret llvm-svn: 122182
* optimize uadd(x, cst) into a comparison when the normal Chris Lattner2010-12-191-0/+16
| | | | | | | result is dead. This is required for my next patch to not regress the testsuite. llvm-svn: 122181
* use IC.ReplaceInstUsesWith instead of a raw RAUW so that uses ofChris Lattner2010-12-191-3/+5
| | | | | | | | the old thing end up on the instcombine worklist. Not doing this can cause an extra top-level iteration of instcombine, burning compile time. llvm-svn: 122179
* generalize the sadd creation code to not require that theChris Lattner2010-12-191-39/+16
| | | | | | | | | | | | | | sadd formed is half the size of the original type. We can now compile this into a sadd.i8: unsigned char X(char a, char b) { int res = a+b; if ((unsigned )(res+128) > 255U) abort(); return res; } llvm-svn: 122178
* fix another miscompile in the llvm.sadd formation logic: it wasn't Chris Lattner2010-12-191-4/+39
| | | | | | | | | checking to see if the high bits of the original add result were dead. Inserting a smaller add and zexting back to that size is not good enough. This is likely to be the fix for 8816. llvm-svn: 122177
* Remove some checks for StrongPHIElim. These checks make it impossible to use anCameron Zwarich2010-12-193-12/+6
| | | | | | | | | | | alternative register allocator that does not require LiveIntervals by specifying it on the command-line for a target that has StrongPHIElimination enabled by default. These checks are pretty meaningless anyways, since StrongPHIElimination and PHIElimination are never used at the same time. llvm-svn: 122176
* fix a bug (possibly 8816) in the sadd forming xform: it isn'tChris Lattner2010-12-191-0/+10
| | | | | | | profitable (or safe) to promote code when the add-with-constant has other uses. llvm-svn: 122175
* rework the code added in r122072 to pull it out to its ownChris Lattner2010-12-191-61/+64
| | | | | | | helper function, clean up comments, and reduce indentation. No functionality change. llvm-svn: 122174
* Enhance LICM to promote alias sets whose pointers themselves are stored,Chris Lattner2010-12-191-1/+4
| | | | | | which doesn't affect the memory address being promoted. llvm-svn: 122172
* fix PR8602, a bug in an assertion: a volatile store *of* a pointerChris Lattner2010-12-191-1/+1
| | | | | | | does not make the alias set for that pointer volatile, just stores *to* the pointer. llvm-svn: 122171
* fix PR8642: if a critical edge has a PHI value that can trap,Chris Lattner2010-12-191-0/+41
| | | | | | | isel is *required* to split the edge. PHI values get evaluated on the edge, not in their predecessor block. llvm-svn: 122170
* revert r122164, I'm going to go with a different approach.Chris Lattner2010-12-191-11/+0
| | | | llvm-svn: 122168
* Fixed version of 122160 (the previous one would fold undefined symbols).Rafael Espindola2010-12-191-50/+52
| | | | llvm-svn: 122167
* Revert 122160 while I debug it.Rafael Espindola2010-12-191-44/+50
| | | | llvm-svn: 122165
* first step to fixing PR8642: don't fold away empty basic blocksChris Lattner2010-12-191-0/+11
| | | | | | | | which have trapping constant exprs in them due to PHI nodes. Eliminating them can cause the constant expr to be evalutated on new paths if the input edges are critical. llvm-svn: 122164
* Move all folding to AttemptToFoldSymbolOffsetDifference.Rafael Espindola2010-12-191-50/+44
| | | | llvm-svn: 122160
* Fix whitespace.Michael J. Spencer2010-12-181-8/+8
| | | | llvm-svn: 122158
* Support/PathV1: Deprecate get{Basename,Dirname,Suffix}.Michael J. Spencer2010-12-184-9/+8
| | | | llvm-svn: 122157
* simplify this a bit.Chris Lattner2010-12-181-2/+1
| | | | llvm-svn: 122156
* Restore the behavior of frame lowering before my refactoring.Anton Korobeynikov2010-12-184-12/+29
| | | | | | | | It turns out that ppc backend has really weird interdependencies over different hooks and all stuff is fragile wrt small changes. This should fix PR8749 llvm-svn: 122155
* Add support for lexing single quotes like 'c'.Roman Divacky2010-12-181-0/+37
| | | | | | This fixed 8615. llvm-svn: 122150
* Revert r122143 through r122140, which collectively broke the LLVMC tests onOwen Anderson2010-12-184-15/+17
| | | | | | the buildbots. llvm-svn: 122149
* Merge isAbsolute into IsSymbolRefDifferenceFullyResolved.Rafael Espindola2010-12-185-40/+30
| | | | llvm-svn: 122148
* Remove the MCObjectFormat class.Rafael Espindola2010-12-1810-82/+20
| | | | llvm-svn: 122147
* Add a FIXME and explain a hack.Rafael Espindola2010-12-181-1/+4
| | | | llvm-svn: 122144
* Fix whitespace.Michael J. Spencer2010-12-181-8/+8
| | | | llvm-svn: 122142
* Support/PathV1: Deprecate get{Basename,Dirname,Suffix}.Michael J. Spencer2010-12-184-9/+7
| | | | llvm-svn: 122141
* Fix the note.Rafael Espindola2010-12-181-1/+1
| | | | llvm-svn: 122139
* Revert 122011, 122012, 122013, 122023 adding back an important optimization.Rafael Espindola2010-12-182-20/+60
| | | | | | I added a note, but suggestions on how to add a test are really welcome. llvm-svn: 122138
* Apparently, operandices is not a word.Jakob Stoklund Olesen2010-12-181-1/+1
| | | | llvm-svn: 122135
* Move some data to the TargetWriter.Rafael Espindola2010-12-185-102/+78
| | | | llvm-svn: 122134
* Teach the inline spiller to attempt folding a load instruction into its singleJakob Stoklund Olesen2010-12-182-5/+27
| | | | | | | | | | | | | | | | | | use before rematerializing the load. This allows us to produce: addps LCPI0_1(%rip), %xmm2 Instead of: movaps LCPI0_1(%rip), %xmm3 addps %xmm3, %xmm2 Saving a register and an instruction. The standard spiller already knows how to do this. llvm-svn: 122133
* Tweak debug spew.Jakob Stoklund Olesen2010-12-181-2/+4
| | | | llvm-svn: 122132
* r120333 changed the opcode for the Thumb1 stuff from ARM::tMOVr toBill Wendling2010-12-181-1/+1
| | | | | | | | | | | ARM::tMOVgpr2gpr. But this check didn't change. As a result, we were getting misaligned references to the jump table from an ADR instruction. There is a test case, but unfortunately it's sensitive to random code changes. <rdar://problem/8782223> llvm-svn: 122131
* RemoveUnusedCPEntries can change things. Track it.Bill Wendling2010-12-181-1/+1
| | | | llvm-svn: 122129
* Check that the register is live-in to the loop header before inserting copies inJakob Stoklund Olesen2010-12-181-5/+7
| | | | | | | | | the loop predecessors. The register can be live-out from a predecessor without being live-in to the loop header if there is a critical edge from the predecessor. llvm-svn: 122123
* Fix GCC warning:Nick Lewycky2010-12-181-0/+1
| | | | | | lib/CodeGen/RegAllocGreedy.cpp:311: error: unused variable 'PhysReg' [-Wunused-variable] llvm-svn: 122122
* Relax push instructions.Rafael Espindola2010-12-181-0/+3
| | | | llvm-svn: 122121
OpenPOWER on IntegriCloud