1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 20:43:44 +02:00
Commit Graph

78 Commits

Author SHA1 Message Date
Chris Lattner
0f61d55197 Fixes working towards PR341
llvm-svn: 14839
2004-07-15 01:50:47 +00:00
Chris Lattner
05f657f5c2 Do not mark instructions in unreachable sections of the function as live.
This fixes PR332 and ADCE/2004-05-04-UnreachableBlock.llx

llvm-svn: 13349
2004-05-04 17:00:46 +00:00
Chris Lattner
924b6c173c Simplify code a bit, and fix a bug that was breaking perlbmk
llvm-svn: 12814
2004-04-10 18:06:21 +00:00
Chris Lattner
f126f03878 Fix a bug in my checkin last night that was breaking programs using invoke.
llvm-svn: 12813
2004-04-10 16:53:29 +00:00
Chris Lattner
d4979e2904 Fix previous patch
llvm-svn: 12811
2004-04-10 07:27:48 +00:00
Chris Lattner
3b211f0432 Correctly update counters
llvm-svn: 12810
2004-04-10 07:02:02 +00:00
Chris Lattner
1676188024 Simplify code a bit, and use alias analysis to allow us to delete unused
call and invoke instructions that are known to not write to memory.

llvm-svn: 12807
2004-04-10 06:53:09 +00:00
Chris Lattner
3575c84933 Fix the count of the number of instructions removed
llvm-svn: 11049
2004-02-01 05:15:07 +00:00
Chris Lattner
e0021ba353 Fix ADCE/2003-12-19-MergeReturn.llx
llvm-svn: 10539
2003-12-19 09:08:34 +00:00
Chris Lattner
a88e567e00 Do not crash when deleing a region with a dead invoke instruction
llvm-svn: 10161
2003-11-22 02:13:08 +00:00
Chris Lattner
2b7309dd1c Minor cleanups and simplifications
llvm-svn: 10127
2003-11-21 16:52:05 +00:00
Chris Lattner
feeb3261f2 Start using the nicer terminator auto-insertion API
llvm-svn: 10111
2003-11-20 18:25:24 +00:00
Chris Lattner
04d122be8f Fix PR116
llvm-svn: 10032
2003-11-16 21:39:27 +00:00
Brian Gaeke
d25f86d683 Put all LLVM code into the llvm namespace, as per bug 109.
llvm-svn: 9903
2003-11-11 22:41:34 +00:00
John Criswell
b402729b30 Added LLVM project notice to the top of every C++ source file.
Header files will be on the way.

llvm-svn: 9298
2003-10-20 19:43:21 +00:00
Misha Brukman
868eac95dd Fix spelling.
llvm-svn: 9027
2003-10-10 17:57:28 +00:00
Chris Lattner
d4de2760aa Rename Function::getEntryNode -> getEntryBlock
llvm-svn: 8625
2003-09-20 14:39:18 +00:00
Chris Lattner
3d39abeeb7 Renamed DominatorTree::Node::getNode() -> getBlock()
llvm-svn: 8469
2003-09-11 16:26:13 +00:00
Chris Lattner
b859bf2fb5 Unwind instructions are intrinsically alive, just like returns
llvm-svn: 8462
2003-09-10 20:38:14 +00:00
Misha Brukman
cda7f97dbb The word dependent' has no a'.
llvm-svn: 8030
2003-08-21 22:14:26 +00:00
Misha Brukman
56f7db4178 Spell `necessary' correctly.
llvm-svn: 7944
2003-08-18 14:43:39 +00:00
Chris Lattner
686e94e760 DEBUG got moved to Support/Debug.h
llvm-svn: 7492
2003-08-01 22:15:03 +00:00
Chris Lattner
2cd94ee470 Fix bug: ADCE/2003-06-24-BadSuccessor.ll
llvm-svn: 6891
2003-06-24 23:02:45 +00:00
Chris Lattner
aac87d1e58 Do not mark ALL terminators live if any instruciton in the block is live. We only
want to mark it live if it is an unconditional branch.  This fixes bug:
ADCE/2002-05-28-Crash.ll and makes this pass _much_ more useful.

llvm-svn: 6887
2003-06-24 21:49:45 +00:00
Chris Lattner
64ec8f36aa Fix bug: ADCE/2003-06-11-InvalidCFG.ll
This was because we were deleting large chunks of functions without an exit block, because the post-dominance
information was not useful.  This broke crafty and twolf.

llvm-svn: 6698
2003-06-16 12:10:45 +00:00
Chris Lattner
e58f6153f4 Remove using declarations
llvm-svn: 6306
2003-05-22 22:00:07 +00:00
Chris Lattner
d2960ee802 Fix bug: ADCE/2003-04-25-PHIPostDominateProblem.ll
llvm-svn: 5952
2003-04-25 22:53:27 +00:00
Chris Lattner
db6b7ba364 Remove unnecesary &*'s
llvm-svn: 5872
2003-04-23 16:37:45 +00:00
Chris Lattner
497c0d443c Rename Instruction::hasSideEffects() -> mayWriteToMemory()
llvm-svn: 5620
2003-02-24 20:48:32 +00:00
Chris Lattner
7af7b1c82c Fix bug: ADCE/2003-01-22-PredecessorProblem.ll
llvm-svn: 5405
2003-01-23 02:12:18 +00:00
Chris Lattner
7cf9f6f4b1 Updates to work with recent Statistic's changes:
* Renamed StatisticReporter.h/cpp to Statistic.h/cpp
    * Broke constructor to take two const char * arguments instead of one, so
      that indendation can be taken care of automatically.
    * Sort the list by pass name when printing
    * Make sure to print all statistics as a group, instead of randomly when
      the statistics dtors are called.
    * Updated ProgrammersManual with new semantics.

llvm-svn: 4002
2002-10-01 22:38:41 +00:00
Chris Lattner
5f4b79edaf Fix the last of the silly bugs I just introduced. :(
llvm-svn: 3674
2002-09-10 23:46:10 +00:00
Chris Lattner
37c3a1d80c Clean up code due to auto-insert constructors
llvm-svn: 3665
2002-09-10 22:38:47 +00:00
Chris Lattner
c4bd846e84 - Split Dominators.h into Dominators.h & PostDominators.h
llvm-svn: 3432
2002-08-21 23:43:50 +00:00
Chris Lattner
80b897953e Avoid inserting an entry block unless we need it
llvm-svn: 3336
2002-08-14 21:35:02 +00:00
Chris Lattner
a21e315db4 - Cleaned up the interface to AnalysisUsage to take analysis class names
instead of ::ID's.
 - Pass::getAnalysis<> now no longer takes an optional argument

llvm-svn: 3265
2002-08-08 19:01:30 +00:00
Chris Lattner
b9052f081a * Fix bug: test/Regression/Transforms/ADCE/2002-07-17-AssertionFailure.ll
which was caused by us not running the "drop references of dead
  instructions" code when there were no basic blocks that were dead.

  We still don't want to do some of the stuff we do if there are dead
  basic blocks, but we DO want to drop references of dead instructions,
  so we factor the common code out to a new method.

llvm-svn: 3137
2002-07-30 00:22:34 +00:00
Chris Lattner
72b8a38a26 Add code to ensure that no PHI nodes are left laying around with their
arguments dropped.  This fixes bug:
   test/Regression/Transforms/ADCE/2002-07-17-PHIAssertion.ll

llvm-svn: 3134
2002-07-29 23:40:46 +00:00
Chris Lattner
5aef91b716 Fix bug: test/Regression/Transforms/ADCE/2002-07-29-Segfault.ll
llvm-svn: 3129
2002-07-29 22:31:39 +00:00
Chris Lattner
ec2780457d * Standardize how analysis results/passes as printed with the print() virtual
methods
* Eliminate AnalysisID:  Now it is just a typedef for const PassInfo*
* Simplify how AnalysisID's are initialized
* Eliminate Analysis/Writer.cpp/.h: incorporate printing functionality into
  the analyses themselves.

llvm-svn: 3116
2002-07-27 01:12:17 +00:00
Chris Lattner
7a9eb848cd * Add support for different "PassType's"
* Add new RegisterOpt/RegisterAnalysis templates for registering passes that
  are to show up in opt or analyze
* Register Analyses now
* Change optimizations to use RegisterOpt instead of RegisterPass
* Add support for different "PassType's"
* Add new RegisterOpt/RegisterAnalysis templates for registering passes that
  are to show up in opt or analyze
* Register Analyses now
* Change optimizations to use RegisterOpt instead of RegisterPass
* Remove getPassName implementations from various subclasses

llvm-svn: 3113
2002-07-26 21:12:46 +00:00
Chris Lattner
ec1a192b16 *** empty log message ***
llvm-svn: 3105
2002-07-26 18:40:14 +00:00
Chris Lattner
c482880f9e *** empty log message ***
llvm-svn: 3016
2002-07-23 18:06:35 +00:00
Anand Shukla
85065832f1 changes to make it compatible with 64bit gcc
llvm-svn: 2792
2002-06-25 21:07:58 +00:00
Chris Lattner
dfd421a7df MEGAPATCH checkin.
For details, See: docs/2002-06-25-MegaPatchInfo.txt

llvm-svn: 2779
2002-06-25 16:13:24 +00:00
Chris Lattner
779f966ce5 Avoid deleting individual instructions until AFTER dead blocks have dropped
their references.  This fixes bug:
    test/Regression/Transforms/ADCE/2002-05-28-Crash*.ll

llvm-svn: 2753
2002-05-28 21:38:16 +00:00
Chris Lattner
1f66858791 Fix and implement ADCE to finally work!
llvm-svn: 2720
2002-05-22 21:32:16 +00:00
Chris Lattner
1f2723a2c9 Use the new DEBUG(x) macro to allow debugging code to be enabled on the commandline
llvm-svn: 2713
2002-05-22 17:17:27 +00:00
Chris Lattner
1bf8912c74 Fix some bugs, straighten stuff out, more work needs to be done.
llvm-svn: 2600
2002-05-10 15:37:35 +00:00
Chris Lattner
bbd8a94a9b Fix bug: test/Regression/Transforms/ADCE/2002-01-31-UseStuckAround.ll
Cleanup code a lot

llvm-svn: 2547
2002-05-07 22:11:39 +00:00