Commit Graph

2044 Commits

Author SHA1 Message Date
Chris Lattner
a7e2321a65 doxygenify
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10661 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-31 04:42:00 +00:00
Chris Lattner
9c4c66e70e Add new function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10648 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-30 07:35:47 +00:00
Chris Lattner
9899ae3ae8 Further revisions of the FDHandle idea. In this version we use ownership
semantics that are the same as those used by std::auto_ptr.  This allows
copying of FDHandle's, but copying transfers ownership.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10646 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-30 02:45:16 +00:00
Chris Lattner
6dea527b4a Add a new class useful for providing fully materialized modules to ExecutionEngine's
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10645 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-30 02:44:04 +00:00
Chris Lattner
9b448b703f Add trivial exception specs to produce better code since the methods cannot
be inlined.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10643 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-29 21:43:58 +00:00
Chris Lattner
2d6481cc2a Factor FDHandle out of the bytecode reader into the FileUtilities.h support
routines.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10642 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-29 21:35:05 +00:00
Chris Lattner
9fc8a3ec2e add new function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10638 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-29 05:06:38 +00:00
Chris Lattner
f70e0c216c Clean up a lot of the code I added yesterday by exposing the IntrinsicLowering
implementation from the TargetMachine directly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10636 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 21:23:38 +00:00
Alkis Evlogimenos
26bfc08b80 Add coalescing to register allocator. A hint is added to each interval
which denotes the register we would like to be assigned to (virtual or
physical). In register allocation, if this hint exists and we can map
it to a physical register (it is either a physical register or it is a
virtual register that already got assigned to a physical one) we use
that register if it is available instead of a random one in the free
pool.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10634 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 17:58:18 +00:00
Alkis Evlogimenos
5e30002af7 Add TargetInstrInfo::isMoveInstr() to support coalescing in register
allocation.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10633 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 17:35:08 +00:00
Chris Lattner
cd824d7678 We may now pass IntrinsicLowering implementations into these methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10630 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 09:48:17 +00:00
Chris Lattner
09c692bcef add argument
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10625 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 09:42:49 +00:00
Chris Lattner
624affb56f ABC's must have virtual dtors! Shame on me!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10624 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 08:55:50 +00:00
Chris Lattner
8a1931a942 Move header into top-level llvm dir
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10622 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 08:30:07 +00:00
Chris Lattner
3f52c1561d Add new interface that allows removal of some code from the code generators,
provides for future extensibility, might help the LLVA project avoid having to
hack their own LLI, and provides support required for the experimental Venus
project.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10620 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-28 08:19:13 +00:00
Chris Lattner
e5dbbf2bdd New method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10615 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-26 06:50:15 +00:00
Chris Lattner
ff65e36be0 Rename 'run' to 'runFunction' to emphasize that it is usable to run any
function in a module, not just main


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10608 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-26 06:12:25 +00:00
Chris Lattner
dbd9b3f75c Hrm is a really nasty ommission. The lack of this destructor was causing abstract
types to never be deleted, manifesting itself as many OpaqueType objects being
leaked.  Whoops.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10601 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-23 23:25:21 +00:00
Chris Lattner
4e4bbc792c Rename ClassifyExpression -> ClassifyExpr
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10591 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-23 08:03:40 +00:00
Chris Lattner
b0404c7a6c Doxygenize methods, add new getIntPtrType method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10578 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-22 05:00:45 +00:00
Chris Lattner
ad4705f055 fix grammao
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10576 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-22 04:08:12 +00:00
Alkis Evlogimenos
6b4edbaaf9 Change weight into a float so that we can take into account the
nesting level when computing it. Right now the allocator uses:

    w = sum_over_defs_uses( 10 ^ nesting level );


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10569 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-21 20:19:10 +00:00
Alkis Evlogimenos
169cfd0196 Add support for inactive intervals. This effectively reuses registers
for live ranges that fall into assigned registers' holes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10566 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-21 05:43:40 +00:00
Chris Lattner
3e200e6c3b Rearrange code, indent for the namespace, add the createMachineFunctionPrinterPass
to passes.h, and add the machien destruction pass to Passes.h


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10557 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 10:18:58 +00:00
Chris Lattner
73c1366ee2 Remove sparc specific passes from public headers
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10552 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 09:15:21 +00:00
Chris Lattner
61838824c2 Remove a horrible API
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10551 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 09:15:01 +00:00
Chris Lattner
1514b5b334 Cleanups to implement PR135
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10548 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 03:35:50 +00:00
Chris Lattner
3ddc05bdde Simple refactorings to prepare for lazy global emission
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10546 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 02:45:16 +00:00
Chris Lattner
1e60a9165d Rip JIT specific stuff out of TargetMachine, as per PR176
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10542 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 01:22:19 +00:00
Chris Lattner
abbc2dd779 Add new function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10529 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 05:56:28 +00:00
Alkis Evlogimenos
4c080863de Remove TwoAddressInstruction from the public headers and add an ID
instead, since this pass doesn't expose any state to its users.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10520 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 22:40:24 +00:00
Alkis Evlogimenos
71499ded4d Add TwoAddressInstructionPass to handle instructions that have two or
more operands and the two first operands are constrained to be the
same. The pass takes an instruction of the form:

        a = b op c

and transforms it into:

        a = b
        a = a op c

and also preserves live variables.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10512 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 13:06:04 +00:00
Alkis Evlogimenos
485ec3c21e Rename LiveIntervals::expired() to LiveIntervals::expiredAt().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10511 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 08:56:11 +00:00
Alkis Evlogimenos
dd2cc65f34 Handle multiple virtual register definitions gracefully.
Move some of the longer LiveIntervals::Interval method out of the
header and add debug information to them. Fix bug and simplify range
merging code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10509 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 08:48:48 +00:00
Chris Lattner
2cffeec014 Add a new AliassetTracker::remove method. Because we need to be able to remove
a pointer from an AliasSet, maintain the pointer values on a doubly linked
list instead of a singly linked list, to permit efficient removal from the
middle of the list.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10506 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 08:11:56 +00:00
Brian Gaeke
0f7d2e8b8d Fix typo in comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10487 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-16 21:55:45 +00:00
Chris Lattner
cfde00b3d7 This header is dead
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10470 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-15 06:39:18 +00:00
Alkis Evlogimenos
721b4e5715 I wonder how this didn't cause any tests to fail...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10462 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-14 13:30:19 +00:00
Alkis Evlogimenos
4d7af65903 Change interface of MachineOperand as follows:
a) remove opIsUse(), opIsDefOnly(), opIsDefAndUse()
    b) add isUse(), isDef()
    c) rename opHiBits32() to isHiBits32(),
              opLoBits32() to isLoBits32(),
              opHiBits64() to isHiBits64(),
              opLoBits64() to isLoBits64().

This results to much more readable code, for example compare
"op.opIsDef() || op.opIsDefAndUse()" to "op.isDef()" a pattern used
very often in the code.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10461 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-14 13:24:17 +00:00
Chris Lattner
bb8f4769a2 Add capability to represent volatile AliasSet's
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10456 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-14 04:51:34 +00:00
Alkis Evlogimenos
4c214d2bf0 Ignore non-allocatable physical registers in live interval analysis.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10449 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-13 11:11:02 +00:00
Chris Lattner
459ccab002 Add new getJITStubForFunction method, which may optionally be implemented by
targets for better performance.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10429 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-12 07:10:32 +00:00
Chris Lattner
895be4bae2 Doxygenify comments, remove extraneous #include
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10428 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-12 06:31:42 +00:00
Brian Gaeke
246372f35d Use uintptr_t for pointer values in the ExecutionEngine.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10425 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-12 05:06:09 +00:00
Brian Gaeke
92c59d60c9 Fix typo in comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10424 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-12 04:58:13 +00:00
Brian Gaeke
8e32f5e46d IncludeFile hack to pull in BasicValueNumbering whenever ValueNumbering.h
is included.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10397 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-11 05:05:56 +00:00
Brian Gaeke
fc188b95b8 IncludeFile hack to pull in BasicAliasAnalysis whenever AliasAnalysis.h
is included.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10396 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-11 05:05:02 +00:00
Chris Lattner
18cb4c3c74 add two new virtual functions:
The first returns a function pointer or a stub if it's not already generated
  The second exposes what was previously JIT specific state to general clients


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10319 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-08 08:22:01 +00:00
Chris Lattner
a08bca95a7 Since ssaification of the varargs builtings, the vaarg instruction no longer
can write to memory.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10310 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-08 05:29:33 +00:00
Brian Gaeke
4768dc5705 Regenerated using autoheader-2.57
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10309 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-08 00:57:01 +00:00
Chris Lattner
eae45cf44b The recalclulate method was a nasty hack that was once used by the -cee pass,
which never worked itself.  The cee pass still doesn't work, but it doesn't use
this method anymore anyway, so eliminate the method.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10302 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-07 00:55:32 +00:00
Chris Lattner
31b935357d Rewrite dominators implementation. Now domset is constructed from immdom,
instead of the other way around.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10300 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-07 00:36:16 +00:00
Chris Lattner
677d027ace Move this method out of the generic dominators calculation code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10298 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-07 00:35:19 +00:00
Alkis Evlogimenos
b27ef248f5 Move operator<<(std::ostream&, const LiveInterval&) out of the header file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10290 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-05 10:38:28 +00:00
Brian Gaeke
59e47e3ee1 Lock abstraction, introduced with a view toward making the JIT thread-safe.
Eventually.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10284 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-01 21:33:31 +00:00
Chris Lattner
7f5dbcc9ea Add new block number
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10281 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-01 07:08:06 +00:00
Chris Lattner
d540e2c995 Remove unused enum value
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10279 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-01 05:40:37 +00:00
Chris Lattner
786a518f47 Add some "useful" methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10277 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-01 05:30:29 +00:00
Chris Lattner
f17072b79c be GCC 3.4 clean
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10264 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-29 19:55:12 +00:00
Chris Lattner
d2aa7b8ee7 Hrm, how could this compile?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10263 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-29 19:55:02 +00:00
Chris Lattner
d423fb5cbf fix gcc 3.4 compatibility problem
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10248 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-28 01:46:06 +00:00
Chris Lattner
6c7901bd11 It is legal to index into sequential types with any integer
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10227 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-25 21:20:19 +00:00
Chris Lattner
c4c6b9e5bc Work with gepi's and constant exprs. Also, add versions of iterator ctors that take references
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10220 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-25 20:17:49 +00:00
Chris Lattner
94a28c6bc8 Rename class to be consistent with other iterator classes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10213 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-25 19:58:35 +00:00
Chris Lattner
19ed305339 Initial checkin of gep_type_begin/end which will be used to address PR82
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10212 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-25 19:37:28 +00:00
Misha Brukman
a140b3c367 Expose functionality to query if a file is an ELF shared object.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10194 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-24 05:28:39 +00:00
Brian Gaeke
9bb2188b0e A better way to get std::pair into the compiler's little, walnut-sized brain.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10174 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-23 03:50:31 +00:00
Brian Gaeke
6de98f242a This is a hack to make this file compile under g++-3.0.x;
otherwise it can't decide what std::pair is. It seemed relatively
harmless.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10173 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-23 00:55:27 +00:00
Chris Lattner
593ba8f560 Somehow I forgot poor little UnwindInst
*sniff*


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10108 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-20 18:11:56 +00:00
Chris Lattner
dd56927846 * Add new constructors to allow insertion of terminator instructions at the
end of basic blocks.
* Document some confusing constructor combinations
* Move a ReturnInst method out-of-line, so that the vtable and type info don't
  need to be emitted to every translation unit that uses the class.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10106 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-20 17:44:37 +00:00
Alkis Evlogimenos
ff0cbe175d Merging the linear scan register allocator in trunk. It currently passes most tests under test/Programs/SingleSource/Benchmarks/Shootout so development will continue on trunk. The allocator is not enabled by default. You will need to pass -regallo=linearscan to lli or llc to use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10103 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-20 03:32:25 +00:00
Brian Gaeke
ff336a4e7f Regenerated using autoheader-2.57
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10064 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-18 06:21:24 +00:00
Chris Lattner
5d5a714b24 Implement == and != correctly. Before they would incorrectly return !=
for some constant exprs when they could really be the same value


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10058 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-17 20:19:35 +00:00
Chris Lattner
48babfa60d The ConstantPointer class is now gone.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10057 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-17 19:47:21 +00:00
Chris Lattner
0dc396909e Constant folding shalt not be built on annotations
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10052 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-17 19:05:17 +00:00
Chris Lattner
825b02d5ee Fix copy-and-pasteo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10049 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-17 01:07:58 +00:00
Chris Lattner
8b70b78ba4 Fixes for PR114: Thanks to Reid Spencer!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10029 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-16 20:21:15 +00:00
Chris Lattner
60e9742e82 This is obviously illegal C++ code, but was apparently accepted by 3.3
bork


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9993 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-14 06:03:05 +00:00
Chris Lattner
21fc51daa5 Add methods for implementation
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9963 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-13 05:05:34 +00:00
Chris Lattner
a3f5f80f2b Remove needless dependence on boost
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9961 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-13 04:11:30 +00:00
Chris Lattner
de0579d946 Add namespace qualifier
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9959 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-13 02:30:22 +00:00
Chris Lattner
2d3e1ee93c Minor cleanups
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9958 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-13 02:01:41 +00:00
Chris Lattner
7d26815d8d Add an initial version of the CompleteBUDataStructures pass
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9955 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-13 01:42:38 +00:00
Chris Lattner
e94e0edc3e Fix faulty namespacification
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9943 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-12 22:45:14 +00:00
John Criswell
fed0b2995e Regress to not using the llvm namespace.
This keeps Pool Allocation stuff from compiling.
We can re-visit it later when we have time to do it right.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9932 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-12 21:32:06 +00:00
Chris Lattner
f58aefcb20 Add argument
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9921 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-12 17:58:09 +00:00
Brian Gaeke
d0fde30ce8 Put all LLVM code into the llvm namespace, as per bug 109.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9903 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-11 22:41:34 +00:00
Brian Gaeke
f33d00f0d8 Add prototypes for CheckMagic, IsArchive, and IsBytecode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9900 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-11 21:53:29 +00:00
Brian Gaeke
6a9127ec00 VS: ----------------------------------------------------------------------
Add prototype for FileOpenable().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9891 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-11 18:27:11 +00:00
Chris Lattner
3b120be94f Add new method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9879 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-11 05:08:36 +00:00
Chris Lattner
aeef8c70f0 Include forms of SplitCriticalEdge which work correctly with pred/succ iterators
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9856 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 04:42:13 +00:00
Chris Lattner
33e0a7575d No really, I'm not on crack
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9855 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 04:23:52 +00:00
Chris Lattner
b977ef2d54 Helper method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9854 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 04:16:50 +00:00
Chris Lattner
d9c5c5e12f Move isCriticalEdge & SplitCritical into this file. While we're at it, change
the interface to SplitCriticalEdge so that it splits an edge if it is critical,
otherwise just returns false and noops if not.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9852 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 04:10:27 +00:00
Chris Lattner
4a05ba0ab5 Move isCriticalEdge & SplitCritical edge out of this file, which is only
for passes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9851 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 04:09:44 +00:00
Brian Gaeke
9058349aa4 Regenerated.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9850 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 03:06:28 +00:00
Brian Gaeke
278a4ac603 Patch to fix PR102, contributed by Reid Spencer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9849 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-10 03:06:09 +00:00
Chris Lattner
d5b1245e8c Fix PR95. I'm checking this patch in for Reid Spencer, who figured it out
and wrote it up.  Thanks!!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9832 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-09 19:39:48 +00:00
Chris Lattner
94db57024f Provide a specialization of _Alloc_traits, which allows the G++ runtime to avoid
storing an instance of the allocator in each data structure it uses.  Yaay.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9795 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-07 23:20:56 +00:00
Brian Gaeke
4ba0f57904 Add a warning about not "new"ing or "delete"ing CallSites
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9782 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-07 19:25:22 +00:00
Misha Brukman
12a3f843ff Added ability to register FunctionPasses as optimizations, with
TargetMachine-accepting constructors (thanks to Chris).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9781 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-07 18:56:32 +00:00
Misha Brukman
d24fdda8e9 Declare FunctionPasses as such.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9767 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-07 17:19:39 +00:00
Chris Lattner
f0d6b493f2 Add some ctors for this allocator
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9766 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-07 15:20:06 +00:00
Chris Lattner
3323f2abbd Split the DAE pass into DAE and DAH passes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9742 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-05 21:43:42 +00:00
Brian Gaeke
01f93a4712 A few handy methods that seem to mesh well with what CallSite already provides.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9737 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-05 20:25:33 +00:00
Misha Brukman
80f0b57b5d Since this function returns an int, let's actually return something.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9734 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-05 19:48:05 +00:00
Alkis Evlogimenos
e292da29bf Add std::pair tier. This is a much simplified version of boost::tie
that works only for std::pair.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9723 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-05 05:58:26 +00:00
Chris Lattner
748b487ed2 This works with GCC 3.4 also
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9717 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-05 01:31:12 +00:00
Chris Lattner
d5e4918fa7 Fix spello
Add negate overload


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9709 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-04 23:37:40 +00:00
Alkis Evlogimenos
4dad76cea0 Update documentation since it was misleading: make it clear that a
negative instruction count is returned if instructions are removed
from a basic block.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9705 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-04 23:07:00 +00:00
Alkis Evlogimenos
e668dab5b3 Change all machine basic block modifier functions in MRegisterInfo to
return the number of instructions added to/removed from the basic block
passed as their first argument.

Note: This is only needed because we use a std::vector instead of an
ilist to keep MachineBasicBlock instructions. Inserting an instruction
to a MachineBasicBlock invalidates all iterators to the basic
block. The return value can be used to update an index to the machine
basic block instruction vector and circumvent the iterator elimination
problem but this is really not needed if we move to a better
representation.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9704 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-04 22:57:09 +00:00
Chris Lattner
c2630f7314 New file, for use by the pool allocator project
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9702 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-04 22:38:28 +00:00
Chris Lattner
ac50030f86 Allow CallSites to be used as the key of a map
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9660 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-02 23:04:33 +00:00
Chris Lattner
15869aa2c7 All DSGraphs keep a reference to the targetdata they are created with. This is
used to eliminate the hard coded, hacked in, sparc specific, global TargetData.
Changing the TargetData used to actually match the code fixes problems, and
eliminates a crash.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9659 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-02 22:27:28 +00:00
Chris Lattner
ba12c23ca7 Including the symbol table in the FindUsedTypes analysis was the WRONG way
to fix test/Regression/CBackend/2003-10-23-UnusedType.ll.  This completely
neutered the deadtypeelim pass.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9646 91177308-0d34-0410-b5e6-96231b3b80d8
2003-11-02 01:28:41 +00:00
Chris Lattner
1926f69c53 Escape "'s, which are frequent visitors to C++ types
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9642 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-31 22:16:41 +00:00
Chris Lattner
bc539434c5 Did I mention that I _HATE_ CPRs?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9639 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-31 18:38:06 +00:00
Chris Lattner
b10bed8a63 Constant pointer refs are causing these to fail unnecessarily, which is causing
a lot of code to be pessimized.  I hate CPRs.  :(


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9635 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-31 17:51:16 +00:00
Chris Lattner
072ddb1dac Expose new print methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9620 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-30 23:41:19 +00:00
Chris Lattner
0836bf7bcf New interface
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9618 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-30 23:39:52 +00:00
Brian Gaeke
0b64ca3cbd Apparently my Mac OS X fixes were not entirely compatible with SPARC...hmm.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9612 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-30 15:03:49 +00:00
Chris Lattner
14fffaf6c1 When someone includes CallGraph.h, make sure that they link in CallGraph.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9611 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-30 05:17:30 +00:00
Chris Lattner
9f6a519027 Tighten up what we consider to be first class types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9608 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-30 01:38:41 +00:00
Brian Gaeke
78e1dcc321 Add support for utostr(unsigned long)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9588 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-29 20:06:19 +00:00
Brian Gaeke
681453dc77 Pull in stdint.h here, if we have it. Some systems keep
the INT*_MAX macros there.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9577 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-29 04:25:48 +00:00
Chris Lattner
a3a1c2de9d Add new method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9570 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-28 23:10:44 +00:00
Brian Gaeke
8be7aa11c3 Remove __STDC_LIMIT_MACROS from here.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9550 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-28 19:11:29 +00:00
Brian Gaeke
20a277e162 ExecutionEngine::create no longer takes a TraceMode argument.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9488 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-24 19:58:38 +00:00
Chris Lattner
7c4098ee2b Add assertions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9443 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-23 19:33:49 +00:00
Chris Lattner
4a2c0e9259 Fix bug in eon hopefully
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9442 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-23 19:33:44 +00:00
Chris Lattner
815904d373 Include new prototype
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9422 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-23 16:51:49 +00:00
Chris Lattner
d97487d1e0 Actually share constants local to a function!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9417 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-23 16:29:12 +00:00
Brian Gaeke
0bd2189e5f Fix apparent typo in head-of-file comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9400 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-23 04:01:49 +00:00
Brian Gaeke
e1ff6cd6c4 I think this file is not included by anything.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9380 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-22 17:51:28 +00:00
Chris Lattner
c149c47d1f Add two new function stubs for viewing the CFG of a function inside of the
debugger


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9373 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-22 16:03:20 +00:00
Chris Lattner
5f7e61d226 Add a new map
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9311 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 20:55:13 +00:00
Chris Lattner
60f1445cf2 This #include is no longer necessary
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9306 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 20:29:44 +00:00
John Criswell
6fbcc26f14 Added LLVM copyright header (for lack of a better term).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9304 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 20:19:47 +00:00
John Criswell
1fc0d67e3e Oops. Typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9303 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 20:16:14 +00:00
John Criswell
2efc5b5780 Added LLVM header notice.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9302 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 20:11:43 +00:00
John Criswell
b2109ce978 Added LLVM notice.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9300 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 19:46:57 +00:00
Brian Gaeke
a42649e3dd Make replaceMachineCodeForFunction return void.
Make it assert by default.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9287 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-20 15:14:33 +00:00
Chris Lattner
3b237fcd38 Change the Opcode enum for PHI nodes from "Instruction::PHINode" to "Instruction::PHI" to be more consistent with the other instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9269 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-19 21:34:28 +00:00
Chris Lattner
4661dc6a6a Change the Opcode enum for PHI nodes from "Instruction::PHINode" to "Instruction::PHI" to be more consistent with the other instructions.
This allows removal of a special case from the instvisitor


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9268 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-19 21:34:11 +00:00
Chris Lattner
99e7ab72c8 New revised variable argument handling support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9219 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-18 05:53:13 +00:00
Misha Brukman
9573b91c32 Return the Module being materialized to avoid always calling getModule().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9198 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-17 18:26:51 +00:00
Brian Gaeke
5358bc39c1 Add stub version of replaceMachineCodeForFunction. It will live here until
we have a better place for it to go.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9197 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-17 18:26:45 +00:00
Alkis Evlogimenos
60596382aa Eliminate some extraneous code in SlotCalculator::insertVal().
Rename SlotCalculator::getValSlot() to SlotCalculator::getSlot(),
       SlotCalculator::insertValue() to SlotCalculator::getOrCreateSlot(),
       SlotCalculator::insertVal() to SlotCalculator::insertValue(), and
       SlotCalculator::doInsertVal() to SlotCalculator::doInsertValue().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9190 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-17 02:02:40 +00:00
Brian Gaeke
661ab811d8 This file has funny include guards and funny extra whitespace.
Make this file less funny.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9186 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-16 23:43:35 +00:00
Misha Brukman
7034adbce2 If we move the constructors to the .cpp file, we can drop the #include
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9180 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-16 21:16:21 +00:00
Chris Lattner
e63540307d Add weak linking type
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9168 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-16 18:27:04 +00:00
Chris Lattner
202884fd9b Completely rewrite support for the Value::use_* list. Now, all operations on
this list (except use_size()) are constant time.  Before the killUse method
(used whenever something stopped using a value) was linear time, and thus
very very slow for large programs.

This speeds GCCAS up _substantially_ on large programs: almost 2x for 176.gcc:

176.gcc:     77.07s -> 37.38s
177.mesa:     7.59s ->  5.57s
252.eon:     21.02s -> 19.52s (*)
253.perlbmk: 11.40s -> 13.05s
254.gap:      7.25s -> 7.42s

252.eon would speed up a whole lot more, but optimization time is being
dominated by the inlining pass, which needs to be fixed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9159 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-16 16:53:04 +00:00
Chris Lattner
ed60e1c939 Vector is my friend, do you like vector?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9147 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15 22:10:10 +00:00
Chris Lattner
978e2cbfb2 lalala
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9146 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15 22:09:57 +00:00
Chris Lattner
ea2c1dcb7c We'll need this soon as well
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9145 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15 22:09:46 +00:00
Chris Lattner
803f03e217 This file uses assert and doesn't include anything which already #includes <cassert>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9142 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15 21:55:37 +00:00
Chris Lattner
33922eb648 Remove usage of use_size()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9134 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15 16:43:24 +00:00
Chris Lattner
14d9ce7892 Add new hasOneUse() method. Remove explicit inline qualifiers
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9132 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-15 16:39:04 +00:00
Chris Lattner
eeed983821 Generalize abstract interpreter interface to allow linking in an arbitrary number of shared objects
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9129 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-14 21:52:52 +00:00
Misha Brukman
b6c54ed8f5 Enabling incremental bytecode loading in the JIT:
* ExecutionEngine can be constructed from a ModuleProvider
* Alphabetized order of forward-declared classes


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9123 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-14 21:35:52 +00:00
Misha Brukman
deb1740615 Enabling incremental bytecode loading in the JIT:
* Add ModuleProvider as a parameter to FunctionPassManager


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9122 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-14 21:34:56 +00:00
Chris Lattner
7915a1e764 Substantial cleanups:
* Add header comment
 * Remove extraneous #includes
 * Move the FileType enum into the GCC class
 * The GCC class is not virtual.
 * Move all of the "constructor" functions into the classes themselves
 * Stop using cl::list as arguments, use std::vector instead (which cl::list
   derives from)
 * Improve comments


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9121 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-14 21:34:11 +00:00
John Criswell
7eadec6327 Adding additional license information to these files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9102 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 20:34:27 +00:00
Chris Lattner
1e79609e30 Add missing default argument
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9092 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 16:44:30 +00:00
Chris Lattner
9061e992d5 add support for "external" depth first iterators, which store the 'visited' set
outside of the iterator itself.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9090 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 16:34:26 +00:00
John Criswell
a0137d3d82 Added a macro and code that checks for the %a format string in sprintf().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9089 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 16:22:01 +00:00
Chris Lattner
4846f4b87a Extricate the "reverse" support from the depth-first iterator. This is really
a crappy form of post-order traversal which really does not belong here.  While
we are at it, improve documentation and use a vector instead of a stack.

This improves the post dominator analysis pass by ~5%, and probably also helps
other passes as well.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9084 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 15:45:33 +00:00
Chris Lattner
ba7beb084c Add operator= for type iterators to make them assignable
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9083 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 15:34:17 +00:00
Chris Lattner
814f622526 Remove explicit inline qualifiers when the implicit ones work just as well
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9082 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 15:30:59 +00:00
Chris Lattner
d7db1fb944 Add new op_erase method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9068 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-13 03:29:26 +00:00
Chris Lattner
98bf436e2e Rename loop preheaders pass to loop simplify
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9061 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-12 21:52:28 +00:00
Chris Lattner
7f9bb6e92c Rename method to indicate what it does
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9054 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-12 18:51:53 +00:00
Brian Gaeke
854f9c4f84 No longer used anywhere.
Dead.

This is a dead header.

It's not pining! It's passed on! This header is no more! It has ceased
to be!  It's expired and gone to meet its maker! It's a stiff! Bereft
of life, it rests in peace! If you hadn't nailed it to the perch it'd
be pushing up the daisies! Its metabolic processes are now history! It's
off the twig! It's kicked the bucket! It's shuffled off its mortal coil,
run down the curtain, and joined the bleeding choir invisibile!! THIS IS
AN EX-HEADER!!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9035 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-10 18:58:07 +00:00
Misha Brukman
d5d96b9fcd Fix spelling.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9021 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-10 17:42:19 +00:00
Misha Brukman
50f7129324 Use 'F' for Function instead of 'M'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9019 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-10 17:38:31 +00:00
Brian Gaeke
f212e47271 Add my abstracted dynamic linker support files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9008 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-10 16:55:42 +00:00
Chris Lattner
97622b1751 Add a method to reserve space for operands
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8992 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-09 22:45:59 +00:00
Chris Lattner
342be126ef Kill warning when compiling in optimized mode
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8989 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-09 20:43:55 +00:00
Chris Lattner
1bc33a5227 Make getContainedType more efficient by not returning null if out of range!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8987 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-09 20:35:15 +00:00
Alkis Evlogimenos
185a7ab2ed Forward declare class Type since it is used in this class and Type.h is not included
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8958 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-08 04:45:45 +00:00
Brian Gaeke
cbeedf73d4 Regenerated with (at top-level llvm directory):
% autoheader -I autoconf autoconf/configure.ac


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8956 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-07 23:39:51 +00:00
Misha Brukman
29f73611e2 Moved to llvm/include/llvm/Support because it is LLVM-specific.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8897 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-06 18:34:38 +00:00
Chris Lattner
b0a994b4c0 Remove unneeded dtors
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8896 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-06 17:36:49 +00:00
Chris Lattner
aacd3c8d86 Doxygenize class comments. Add new NamedRegionTimer class
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8888 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-06 15:02:16 +00:00
Chris Lattner
43f820d1f7 Change the interface to PromoteMemToReg to also take a DominatorTree
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8883 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-05 21:20:13 +00:00
Chris Lattner
5e5252b4c9 Add new prototype for createLowerInvokePass(). Make simplifycfg be a
functionpass


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8870 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-05 19:15:13 +00:00
Chris Lattner
27db7e0472 Output a very high-precision number
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8856 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-05 00:41:07 +00:00
Chris Lattner
5133a5cf2e Add some new methods to forward to
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8852 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-05 00:13:28 +00:00
Chris Lattner
00413e3d63 Rename AbstractModuleProvider -> ModuleProvider, to match the header file name,
and because, while the class used by the interface is abstract, the actual
concept is not.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8850 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-04 20:14:59 +00:00
Chris Lattner
af6f93ce35 Minor cleanups
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8843 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-03 18:57:54 +00:00
Chris Lattner
7685ac8d35 This checkin basically amounts to a complete rewrite of the type-resolution
machinery.  This dramatically simplifies how things works, removes irritating
little corner cases, and overall improves speed and reliability.

Highlights of this change are:

1. The exponential algorithm built into the code is now gone.  For example
   the time to disassemble one bytecode file from the mesa benchmark went
   from taking 12.5s to taking 0.16s.
2. The linker bugs should be dramatically reduced.  The one remaining bug
   has to do with constant handling, which I actually introduced in
   "union-find" checkins.
3. The code is much easier to follow, as a result of fewer special cases.
   It's probably also smaller.  yaay.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8842 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-03 18:46:24 +00:00
Chris Lattner
1ad37b2b59 These methods are dead, remove them
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8839 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-03 18:39:40 +00:00
Chris Lattner
1c5164e9cf Make the PATypeHolder use a simple union-find implementation to handle
merging of types.  This makes it MUCH more efficient than before, also
making things simpler.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8833 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-02 23:35:57 +00:00
Chris Lattner
0dde36c4c7 There is no reason for Value to be an AbstractTypeUser. This just makes things
significantly more complete.  Instead, just make DerivedType's AbstractTypeUser's,
and make Value contain a PATypeHolder.  This will also be more efficient in the
future.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8827 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-02 19:44:23 +00:00
Chris Lattner
df0c1a2189 There is no reason for the PATypeHolder class to derive from the
PATypeHandle class


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8825 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-02 19:08:18 +00:00
Alkis Evlogimenos
7237ecef13 Moved enum and command-line option in separate file. Also added function that returns the user selected register allocator to the caller.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8819 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-02 16:57:49 +00:00
Alkis Evlogimenos
eed462b685 Change llc command line for register allocators
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8815 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-02 06:13:19 +00:00
Chris Lattner
01ed1c0846 Remove obsolete scoped pred and succ iterator typedefs
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8810 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-01 22:28:39 +00:00
Chris Lattner
22bca4dfb0 Use graph traits to perform generic interval construction
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8809 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-01 22:28:00 +00:00
Chris Lattner
96f7b1bf32 Add graph traits specializations for intervals
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8808 91177308-0d34-0410-b5e6-96231b3b80d8
2003-10-01 22:27:36 +00:00