1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 11:33:24 +02:00
Commit Graph

432 Commits

Author SHA1 Message Date
Chris Lattner
b565d3ac5b - Rename AnalysisUsage::preservesAll to getPreservesAll & preservesCFG to
setPreservesCFG to be less confusing.

llvm-svn: 4255
2002-10-21 20:00:28 +00:00
Chris Lattner
7be670ef4b - Eliminate SymbolTable::ParentSymTab, ST::localLookup, and
Function::ParentSymTab.  These aren't needed at all.

llvm-svn: 4186
2002-10-15 21:26:29 +00:00
Chris Lattner
5b41b28fb6 - Dramatically simplify the Constant::mutateReferences implementation,
allowing it to be called on all constant types (structures/arrays)

llvm-svn: 4160
2002-10-14 03:30:23 +00:00
Chris Lattner
1492e49a49 Minor cleanups, no changes to functionality
llvm-svn: 4157
2002-10-14 00:48:57 +00:00
Chris Lattner
82f54dca49 - Change Function's so that their argument list is populated when they are
constructed.  Before, external functions would have an empty argument list,
    now a Function ALWAYS has a populated argument list.

llvm-svn: 4149
2002-10-13 20:57:00 +00:00
Chris Lattner
fdf2ca9468 - Rename Instruction::First*Op to *OpsBegin, and Num*Ops to *OpsEnd to
reflect the fact that it's a range being defined.

llvm-svn: 4147
2002-10-13 19:39:16 +00:00
Chris Lattner
266bacb650 - Make Value::replaceAllUsesWith work with constants correctly. This fixes
bug FuncResolve/2002-08-19-ResolveGlobalVars.ll and gzip looks better.

llvm-svn: 4103
2002-10-09 23:12:59 +00:00
Chris Lattner
0acdba0025 - Add new Constant::replaceUsesOfWithOnConstant which has an end result
similar to User::replaceUsesOfWith but actually does the right thing for
    constants.

llvm-svn: 4102
2002-10-09 23:12:25 +00:00
Chris Lattner
a8dd29787b - Remove Value::use_remove
llvm-svn: 4090
2002-10-09 00:25:05 +00:00
Chris Lattner
88de60dd26 Fix NASTY N^2 behavior that was causing the gzip benchmark to take forever to
assemble.  Now we scan the use-list from the back when removing users instead
of from the front.

llvm-svn: 4086
2002-10-08 23:46:55 +00:00
Chris Lattner
4a72e094f9 Fix bug: Assembler/2002-10-08-LargeArrayPerformance.ll by using
std::vector::reserve when possible

llvm-svn: 4085
2002-10-08 23:33:52 +00:00
Chris Lattner
c35f54df86 Changes to support PHINode::removeIncoming changes
llvm-svn: 4080
2002-10-08 21:36:34 +00:00
Chris Lattner
f868df40b9 - Change PHINode::removeIncomingValue to delete the phi node if the last
incoming value is removed!

llvm-svn: 4078
2002-10-08 21:34:58 +00:00
Chris Lattner
b9f59f1533 Expose new "recalculate" method from dominatorset
llvm-svn: 4074
2002-10-08 19:12:08 +00:00
Chris Lattner
4e19009255 Global variables are now external if they don't have initializers, not
"uninitialized"

llvm-svn: 4052
2002-10-06 22:48:09 +00:00
Chris Lattner
d8244f43d4 Check that we don't have external varaibles with internal linkage
llvm-svn: 4051
2002-10-06 22:47:32 +00:00
Chris Lattner
53a414c3c4 PHI nodes are not allowed to exist with zero incoming values, check that
there aren't any like this.

llvm-svn: 4044
2002-10-06 21:00:31 +00:00
Chris Lattner
85ba0832e5 Fix a nasty problem with dominance calculation for unreachable blocks.
If we had a CFG that look like Entry -> B, Unreachable -> B, then we would
not correctly determine that Entry dominated B, because Entry did not
apparently dominate "unreachable".  This patch fixes this by making the entry
node dominate all blocks, including unreachable ones.

llvm-svn: 4037
2002-10-04 14:45:48 +00:00
Chris Lattner
94a5211b6a - Print the predecessors of a basic block instead of the number of uses of
the block in the AsmWriter

llvm-svn: 4019
2002-10-02 19:38:55 +00:00
Chris Lattner
9a8022871b Make sure to use the TimerGroup that we created!
llvm-svn: 3995
2002-10-01 20:12:06 +00:00
Chris Lattner
10fd9ad81e Make sure not to count the PassManager wrapers
llvm-svn: 3994
2002-10-01 20:08:11 +00:00
Chris Lattner
b7a507eb31 Factor timer code out of PassManager implementation, into a generic interface
exposed by Support/Timer.h.

llvm-svn: 3993
2002-10-01 19:54:07 +00:00
Chris Lattner
e3eaa16375 Fix a problem that was caused by stale analyses being in CurrentAnalyses
llvm-svn: 3981
2002-09-29 22:50:22 +00:00
Chris Lattner
2a7dd8373f Improve printing of dominator sets
llvm-svn: 3976
2002-09-29 21:42:42 +00:00
Chris Lattner
8752bb1cfc - Add methods to ImmediateDominators & DominatorTree to allow updates
- Make DominatorTree::Node not inherit from std::vector

llvm-svn: 3939
2002-09-26 16:14:41 +00:00
Chris Lattner
989b743c33 - Add new ctor to BasicBlock to allow insertion before any BB, not just at
the end of the function.

llvm-svn: 3934
2002-09-26 05:03:22 +00:00
Chris Lattner
37ae98efd1 * Fix ugly bug in previous checkin where I reused the name 'i' one too many times
* Print out immutable passes in the -debug-pass=Structure report.

llvm-svn: 3923
2002-09-25 22:26:52 +00:00
Chris Lattner
e7d8ee84e7 Add support for ImmutablePasses, which are not run, and cannot be
invalidated.

llvm-svn: 3921
2002-09-25 21:59:11 +00:00
Chris Lattner
c86c7ecdb5 Make sure that we abort if an error happens as early as neccesary. Before
it was possible for the passmanager to continue running passes after the
verifier even if the module was not well formed.

llvm-svn: 3820
2002-09-19 16:12:19 +00:00
Vikram S. Adve
ee3caccf5c Remove specification of argument default from cpp file.
llvm-svn: 3772
2002-09-17 01:17:57 +00:00
Chris Lattner
547be87c13 Change the MallocInst & AllocaInst ctors to take the allocated type, not the
pointer type returned.

llvm-svn: 3711
2002-09-13 22:28:50 +00:00
Chris Lattner
ad291457ef include/llvm/DataTypes.h includes this #define so we don't need it anymore
llvm-svn: 3708
2002-09-13 22:24:57 +00:00
Chris Lattner
dfd0d44c99 Another portability fix provided via Casey Carter:
ISSUE: getTimeRecord in lib/VMCore/Pass.cpp uses timeval and
gettimeofday() without including sys/time.h.

ACTION: Include sys/time.h.
llvm-svn: 3699
2002-09-13 14:47:12 +00:00
Chris Lattner
9b5fa33b42 Add a new BasicBlockPass::doInitialization/Finalization(Function &) pair of
methods that may be useful for BasicBlockPasses.

llvm-svn: 3688
2002-09-12 17:06:40 +00:00
Chris Lattner
596aa597a6 Give better assertion message for error conditions
llvm-svn: 3680
2002-09-11 01:21:04 +00:00
Chris Lattner
1a91b112b7 Allocation insts always have one operand
llvm-svn: 3677
2002-09-11 00:22:39 +00:00
Chris Lattner
c882973bf7 Add convenience ctor to BranchInst
llvm-svn: 3676
2002-09-10 23:54:58 +00:00
Chris Lattner
00fd7c012d Tighten up assertion checking for binary operators, not allowing invalid
instructions to _even be created_.

llvm-svn: 3661
2002-09-10 19:57:53 +00:00
Chris Lattner
a63519afc8 Add support for printing constpointerrefs more nicely
llvm-svn: 3654
2002-09-10 15:53:49 +00:00
Chris Lattner
59efee4bf0 Add capability to insert an instruction into a basic block immediately after
it is created, as part of the ctor call.

Eliminate the GenericBinaryInst class

llvm-svn: 3653
2002-09-10 15:45:53 +00:00
Chris Lattner
a88aeefa30 Fix typeo in assertion message
llvm-svn: 3641
2002-09-10 04:52:59 +00:00
Chris Lattner
aac1fc4581 Do not allow adds of pointer types, or many other operations on pointer types.
llvm-svn: 3638
2002-09-09 20:26:04 +00:00
Chris Lattner
ba447dd0a3 Enable "garbage detection" of LLVM objects. Check for leaks after running
every pass.

llvm-svn: 3621
2002-09-08 19:00:07 +00:00
Chris Lattner
3d630b954f Enable "garbage detection" of LLVM objects. Now users should be obnoxious
warnings.  If they accidentally leak LLVM Value's.

llvm-svn: 3620
2002-09-08 18:59:35 +00:00
Chris Lattner
c1e61532a0 Move code out of header files into .cpp files to make future changes easier
llvm-svn: 3605
2002-09-06 21:33:15 +00:00
Chris Lattner
01f30bf2a0 * Remove extraneous #includes
* Add extra argument to Function ctor to allow automatic insertion into module

llvm-svn: 3600
2002-09-06 20:46:32 +00:00
Chris Lattner
c78ae565ef Implement setcc for booleans. Fixes bug:
test/Regression/Transforms/ConstProp/2002-09-03-SetCC-Bools.ll

llvm-svn: 3576
2002-09-03 20:09:49 +00:00
Chris Lattner
3ce5b343c5 - Renamed Type::isIntegral() to Type::isInteger()
- Added new method Type::isIntegral() that is the same as isInteger, but
    also accepts bool.

llvm-svn: 3574
2002-09-03 01:08:28 +00:00
Chris Lattner
5775f64365 - Exposed SetCondInst::getInverseCondition & ::getSwappedCondition better
llvm-svn: 3562
2002-09-01 19:46:40 +00:00
Chris Lattner
67f9108e98 - Use Pass::AnalysisImpls instead of findAnalysisGroupMemeber
- -debug-pass=Details now prints implementation class names for analysis
    groups
  - Rework how AnalysisGroups are resolved to be simpler and better.

llvm-svn: 3535
2002-08-30 20:25:01 +00:00