aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Extend jump threading to support much more general threadingChris Lattner2009-11-062-27/+356
| | | | | | | | | | | | | | | | | | | | | | | predicates. This allows us to jump thread things like: _ZN12StringSwitchI5ColorE4CaseILj7EEERS1_RAT__KcRKS0_.exit119: %tmp1.i24166 = phi i8 [ 1, %bb5.i117 ], [ %tmp1.i24165, %_Z....exit ], [ %tmp1.i24165, %bb4.i114 ] %toBoolnot.i87 = icmp eq i8 %tmp1.i24166, 0 ; <i1> [#uses=1] %tmp4.i90 = icmp eq i32 %tmp2.i, 6 ; <i1> [#uses=1] %or.cond173 = and i1 %toBoolnot.i87, %tmp4.i90 ; <i1> [#uses=1] br i1 %or.cond173, label %bb4.i96, label %_ZN12... Where it is "obvious" that when coming from %bb5.i117 that the 'and' is always false. This triggers a surprisingly high number of times in the testsuite, and gets us closer to generating good code for doug's strswitch testcase. This also make a bunch of other code in jump threading redundant, I'll rip out in the next patch. This survived an enable-checking llvm-gcc bootstrap. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86264 91177308-0d34-0410-b5e6-96231b3b80d8
* Use WriteAsOperand to print GlobalAddress MachineOperands. ThisDan Gohman2009-11-061-1/+2
| | | | | | | prints them with the leading '@'. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86261 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not bother to emit debug info for nameless global variable.Devang Patel2009-11-063-2/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86259 91177308-0d34-0410-b5e6-96231b3b80d8
* Pass StringRef by value.Daniel Dunbar2009-11-0651-200/+196
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86251 91177308-0d34-0410-b5e6-96231b3b80d8
* clang++ points out that this is pointless.Chris Lattner2009-11-061-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86239 91177308-0d34-0410-b5e6-96231b3b80d8
* remove some more Context arguments.Chris Lattner2009-11-063-5/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86235 91177308-0d34-0410-b5e6-96231b3b80d8
* remove a bunch of extraneous LLVMContext argumentsChris Lattner2009-11-0620-289/+220
| | | | | | | from various APIs, addressing PR5325. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86231 91177308-0d34-0410-b5e6-96231b3b80d8
* NewNighlytTest: Fix timestamp format to actually make sense (it was missing ↵Daniel Dunbar2009-11-061-1/+2
| | | | | | the hour). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86229 91177308-0d34-0410-b5e6-96231b3b80d8
* NewNightlyTest: Add -noclean option, which doesn't run 'make clean' before ↵Daniel Dunbar2009-11-061-6/+8
| | | | | | | | building LLVM (for testing). Also, switch to always running 'make clean' in the test-suite directories. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86228 91177308-0d34-0410-b5e6-96231b3b80d8
* NewNightlyTest: Unbreak passing the build directory via a positional argument.Daniel Dunbar2009-11-061-7/+7
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86227 91177308-0d34-0410-b5e6-96231b3b80d8
* NewNightlyTest: Add -llvmgccdir as alternative to environment variable.Daniel Dunbar2009-11-061-8/+15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86226 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r86077 because it caused crashes in 179.art and 175.vpr on ARMVictor Hernandez2009-11-0619-244/+191
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86213 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not try to emit debug info entry for dead global variable.Devang Patel2009-11-062-1/+23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86212 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't print a redundant tab for inline asm, and do use the new printKill.Dan Gohman2009-11-061-2/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86206 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a bunch of missing "template" keywords to disambiguate dependent ↵Douglas Gregor2009-11-061-8/+11
| | | | | | template names. GCC eats this ill-formed code, Clang does not. I already filed PR5404 to improve recovery in this case git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86204 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR5315, original patch by Nicolas Capens!Eric Christopher2009-11-065-21/+21
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86203 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor out the printing of the leading tab into printInlineAsm.Dan Gohman2009-11-064-3/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86199 91177308-0d34-0410-b5e6-96231b3b80d8
* Make printImplicitDef and printKill non-virtual, since they don'tDan Gohman2009-11-061-2/+2
| | | | | | | need to be overridden. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86198 91177308-0d34-0410-b5e6-96231b3b80d8
* Use SUBREG_TO_REG instead of INSERT_SUBREG to model x86-64'sDan Gohman2009-11-051-5/+3
| | | | | | | implicit zero-extend. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86196 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach LSR to avoid calling SplitCriticalEdge on edges with indirectbr.Dan Gohman2009-11-051-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86193 91177308-0d34-0410-b5e6-96231b3b80d8
* Update these tests for the new label names.Dan Gohman2009-11-052-7/+7
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86192 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the label name generation for address-taken labels to avoid potentialDan Gohman2009-11-051-6/+10
| | | | | | | problems with name collisions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86189 91177308-0d34-0410-b5e6-96231b3b80d8
* Make a few more LLVM headers parsable as standalone headers.Douglas Gregor2009-11-0511-5/+19
| | | | | | | | | Fix some problems with the hidden copy constructors for ImmutableMap/ImmutableSet found by Clang++. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86186 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach lit's SyntaxCheckTest two new tricks:Douglas Gregor2009-11-051-1/+16
| | | | | | | | | - skip .svn directories - add a set of excluded filenames so we can easily skip tests git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86185 91177308-0d34-0410-b5e6-96231b3b80d8
* Added support for renumbering existing index list elements. Removed some ↵Lang Hames2009-11-051-25/+31
| | | | | | junk from the initial numbering code in runOnMachineFunction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86184 91177308-0d34-0410-b5e6-96231b3b80d8
* Avoid calling getUniqueExitBlocks from within LoopSimplify, as it dependsDan Gohman2009-11-051-1/+8
| | | | | | | | on loops having dedicated exits, which LoopSimplify can no longer always guarantee. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86181 91177308-0d34-0410-b5e6-96231b3b80d8
* LoopDeletion depends on loops having dedicated exits.Dan Gohman2009-11-051-0/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86180 91177308-0d34-0410-b5e6-96231b3b80d8
* The introduction of indirectbr meant the introduction ofDan Gohman2009-11-052-21/+165
| | | | | | | | | | unsplittable critical edges, which means the introduction of loops which cannot be transformed to LoopSimplify form. Fix LoopSimplify to avoid transforming such loops into invalid code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86176 91177308-0d34-0410-b5e6-96231b3b80d8
* Update various Loop optimization passes to cope with the possibility thatDan Gohman2009-11-057-9/+29
| | | | | | | LoopSimplify form may not be available. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86175 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug in aggressive antidep breaking; liveness was not updated correctly ↵David Goodwin2009-11-051-10/+7
| | | | | | for regions that do not have antidep candidates. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86172 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach LoopUnroll how to bail if LoopSimplify can't give it what it needs.Dan Gohman2009-11-051-1/+12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86164 91177308-0d34-0410-b5e6-96231b3b80d8
* Call getAnalysis<LoopInfo> the normal way, instead of asking passed-inDan Gohman2009-11-051-2/+2
| | | | | | | LoopPassManager for it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86163 91177308-0d34-0410-b5e6-96231b3b80d8
* InstrTypes.h includes Instruction.h, so it's not necessary to include both.Dan Gohman2009-11-052-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86162 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix IVUsers to avoid assuming that the loop has a unique backedge.Dan Gohman2009-11-051-0/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86161 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete an unused member variable.Dan Gohman2009-11-051-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86160 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor out the predicate code for loopsimplify form exit blocks intoDan Gohman2009-11-052-6/+12
| | | | | | | a separate helper function. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86159 91177308-0d34-0410-b5e6-96231b3b80d8
* CMake: Detect dotty.Oscar Fuentes2009-11-052-2/+11
| | | | | | | Patch by Arnaud Allard de Grandmaison! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86153 91177308-0d34-0410-b5e6-96231b3b80d8
* CMake: do not test for pthread and dl libraries on Windows (exceptOscar Fuentes2009-11-051-6/+12
| | | | | | | Cygwin). Fixes PR 5368. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86152 91177308-0d34-0410-b5e6-96231b3b80d8
* Avoid printing a redundant space in SDNode->dump().Dan Gohman2009-11-051-2/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86151 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove uninteresting and confusing debug output.Dan Gohman2009-11-0511-20/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86149 91177308-0d34-0410-b5e6-96231b3b80d8
* Move llvm::cl::opt's conversion function into the base classes thatDouglas Gregor2009-11-051-2/+4
| | | | | | | actually need that conversion function. Silences a Clang++ warning. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86148 91177308-0d34-0410-b5e6-96231b3b80d8
* Add an assertion to catch indirectbr in SplitBlockPredecessors. ThisDan Gohman2009-11-051-2/+6
| | | | | | | | | | | | | makes several optimization passes abort in cases where they're currently silently miscompiling code. Remove the indirectbr assertion from SplitEdge. Indirectbr is only a problem for critical edges, and SplitEdge defers to SplitCriticalEdge to handle those, and SplitCriticalEdge has its own assertion for indirectbr. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86147 91177308-0d34-0410-b5e6-96231b3b80d8
* add a note from PR5313Chris Lattner2009-11-051-0/+34
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86146 91177308-0d34-0410-b5e6-96231b3b80d8
* Declare classes with matched tags, pointed out by a clang++ warning.Chris Lattner2009-11-051-2/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86144 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach SimplifyLibCalls to fold memcmp calls with constant arguments.Benjamin Kramer2009-11-052-4/+15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86141 91177308-0d34-0410-b5e6-96231b3b80d8
* lit: Add --param NAME=VALUE option, for test suite specific use (to communicateDaniel Dunbar2009-11-053-2/+24
| | | | | | arbitrary command line arguments to the test suite). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86137 91177308-0d34-0410-b5e6-96231b3b80d8
* Do map insert+find in one step. TODO -= 2.Benjamin Kramer2009-11-051-15/+15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86133 91177308-0d34-0410-b5e6-96231b3b80d8
* Path::createDirectoryOnDisk should ignore existing directories on win32 too.Benjamin Kramer2009-11-051-2/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86132 91177308-0d34-0410-b5e6-96231b3b80d8
* Make two more LLVM headers standaloneDouglas Gregor2009-11-052-0/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86131 91177308-0d34-0410-b5e6-96231b3b80d8
* Make a few headers standalone. Plus, add a missing "template" keywordDouglas Gregor2009-11-055-1/+5
| | | | | | | that Clang diagnoses but GCC does not. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86130 91177308-0d34-0410-b5e6-96231b3b80d8