Commit Graph

9565 Commits

Author SHA1 Message Date
Chris Lattner
655239cc6b Finally, _actually delete the machine code_ for a function, after it has
been emitted.  Also, since the FPK pass is causing memory access violations,
disable it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10559 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 10:20:19 +00:00
Chris Lattner
028565b14b This should not be needed anymore
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10558 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 10:19:18 +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
9068574a29 Fix memory leak in the stackifier, due to the machinebasicblocks not holding
instructions on an ilist


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10556 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 10:12:17 +00:00
Chris Lattner
f2e49d4c1a Finegrainify namespacification
Minor cleanups to killer pass


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10555 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 09:58:55 +00:00
Chris Lattner
583b9d8455 Hoist some sparc specific code into the sparc target
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10554 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 09:17:40 +00:00
Chris Lattner
07f32d48f1 * Finegrainify namespacification
* Move sparc specific code out of generic code
* Eliminate the getOffset() method which made INVALID_FRAME_OFFSET
  necessary, which made pulling in MAX_INT as a sentinal necessary.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10553 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 09:17:07 +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
e29ac166fa PR135 is now finally fixed
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10550 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 03:42:11 +00:00
Chris Lattner
c07ed13875 Implement PR135, lazy emission of global variables
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10549 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 03:36:47 +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
24b0a18c43 Simple refactorings to prepare for lazy global emission
Also, add a stat for the number of globals emitted


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10547 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 02:45:37 +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
2828970819 A minor cleanup for better encapsulation
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10545 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 02:03:14 +00:00
Chris Lattner
4d326fa9be Cleanup the JIT as per PR176. This renames the VM class to JIT, and merges the
VM.cpp and JIT.cpp files into JIT.cpp.  This also splits some nasty code out
into TargetSelect.cpp so that people hopefully won't notice it.  :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10544 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 01:46:27 +00:00
Chris Lattner
61612df9cb Update for changes in the JIT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10543 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-20 01:45:17 +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
370e809107 Eliminate a spurious warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10540 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 19:48:43 +00:00
Chris Lattner
bd1a90ecc7 Fix ADCE/2003-12-19-MergeReturn.llx
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10539 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 09:08:34 +00:00
Chris Lattner
7fe178681b New testcase for missed optimization
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10538 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 09:08:15 +00:00
Chris Lattner
539ca70112 Expand on the AliasSetTracker a bit, so I can remember this next time I come back to it. :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10537 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 08:43:07 +00:00
Chris Lattner
a3df8a964a Remove the wierd "Operands" loop, by traversing basicblocks in reverse order
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10536 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 08:18:16 +00:00
Chris Lattner
86f3dda18b Add support for people calling main recursively
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10535 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 07:51:46 +00:00
Chris Lattner
e4365b2e8c Implement LICM/sink_multiple.ll, by sinking all possible instructions in the
loop before hoisting any.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10534 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 07:22:45 +00:00
Chris Lattner
bb8d661b27 New testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10533 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 06:54:37 +00:00
Chris Lattner
9e25906482 Turn QOI section into CQ section (QUI can be added later if needed)
Add PR187


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10532 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 06:31:56 +00:00
Chris Lattner
0f98e75adf Generalize a special case to fix PR187
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10531 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 06:27:08 +00:00
Chris Lattner
60921c9aa1 Factor code out into the Utils library
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10530 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 05:58:40 +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
Chris Lattner
bb0aca5917 If -enable-linscan is specified, add ENABLE_LINEARSCAN=1 to the make commandline
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10527 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 03:47:31 +00:00
Chris Lattner
8ffc66dac4 Update template
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10525 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-19 03:34:46 +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
Brian Gaeke
78cb3f218a Add install target for libraries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10519 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 20:57:48 +00:00
Chris Lattner
5e46b513f3 Prune some #includes
Add a statistic for # reloads


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10518 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 20:25:31 +00:00
John Criswell
47df12d80d Reverted back to previous revision - this was previously merged
according to the CVS log messages.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10517 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 17:19:19 +00:00
John Criswell
d000e1dc2f Merged in RELEASE_11.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10516 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 16:43:17 +00:00
Alkis Evlogimenos
a71e05acdd Modify linear scan register allocator to use the two-address
instruction pass. This also fixes all remaining bugs for this new
allocator to pass all tests under test/Programs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10515 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 13:15:02 +00:00
Alkis Evlogimenos
a3d0e5c2b2 Fix bug in reserved registers. DH actually aliases DX and EDX which
are not reserved registers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10514 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 13:12:18 +00:00
Alkis Evlogimenos
9af9dbde7d Modify local register allocator to use the two-address instruction pass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10513 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 13:08:52 +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
43f692f90f When a variable is killed and redifined in a basic block only one
killing instruction is tracked. This causes the LiveIntervals to
create bogus intervals. The workaound is to add a range to the
interval from the redefinition to the end of the basic block.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10510 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 08:53:43 +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
5b7142a877 add boog
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10508 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 08:16:25 +00:00
Chris Lattner
ba7df4c482 When we delete instructions from the loop, make sure to remove them from the
AliasSetTracker as well.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10507 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 08:12:32 +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
Chris Lattner
45ab10cb6e Check in patch that Reid submitted
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10505 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-18 06:40:22 +00:00
Misha Brukman
e12e5f3a81 Fix the links to match our 'llvm' namespace in doxygen-generated docs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10504 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-17 23:10:49 +00:00
Misha Brukman
97f9cf2de2 * Converted C-style comments to C++
* Doxygenified comments
* Reordered #includes


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10503 91177308-0d34-0410-b5e6-96231b3b80d8
2003-12-17 22:08:20 +00:00