Commit Graph

559 Commits

Author SHA1 Message Date
Chris Lattner
b74e83c898 Initial checkin of "local" register allocator. Bugs are still present.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5078 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-16 16:15:28 +00:00
Chris Lattner
1d62cea90b Rename createSimpleX86RegisterAllocator to createSimpleRegisterAllocator.
Remvoe some dead code


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5070 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-16 14:37:00 +00:00
Chris Lattner
b167c04e62 Some simpliciations to the spill/reload interface
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5067 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 23:01:26 +00:00
Chris Lattner
8ed9eb5ca3 Simplify PHI node elimination significantly by doing it as a prepass to
register allocation


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5066 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 22:39:53 +00:00
Chris Lattner
9f366d7ab6 Variety of small or trivial simplifications to the code, completely eliminated
the dependence on PhysRegClassMap


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5064 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 22:19:19 +00:00
Chris Lattner
f605055994 Remove unused savePhysRegToStack method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5061 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 21:33:51 +00:00
Chris Lattner
01b08c59b4 Localize a map, remove another
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5060 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 21:24:30 +00:00
Chris Lattner
8233e2fe01 Give simple reg allocator a nice Pass Name
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5058 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 21:13:12 +00:00
Chris Lattner
15f96db4d9 Add a big assert making sure 2 address instructions are formed right
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5057 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 21:02:20 +00:00
Chris Lattner
3f91ad7ba7 Fix a problem that occurs when PHI nodes have multiple entries for the same predecessor
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5055 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 20:48:03 +00:00
Chris Lattner
da7e453aac Grab bag of minor cleanups. Export some statistics about the number of
spills and reloads emitted


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5054 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 20:36:09 +00:00
Chris Lattner
2109f502d6 Implement printing of MBB arguments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5053 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 20:35:25 +00:00
Chris Lattner
198ab640bb Simplify interfaces used by regalloc to insert code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5052 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 20:06:35 +00:00
Chris Lattner
c2db1a95df * Simplify code a bit by breaking the PHI node handling stuff out into a seperate
function from normal regalloc code
* Make the regalloc for a block a function instead of part of runOnMachineBB, which
  makes it easier to see what's going on in runOnMBB.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5051 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 19:51:14 +00:00
Chris Lattner
9593fb1503 * Remove some unneccesary instance variables
* Make allocateStackSpaceFor only allocate the right amount of space


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5048 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 19:07:34 +00:00
Chris Lattner
dd444f9242 pull inverse reg class mapping into a class that is sharable and out of the
target register description classes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5045 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 18:38:59 +00:00
Chris Lattner
abe8dd592d Prune #includes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5044 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 18:19:24 +00:00
Chris Lattner
ad44bd99ff Remove extraneous #includes, perform FIXME
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5043 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 18:15:24 +00:00
Chris Lattner
71c83728b4 Fix borkness with not using MachineBasicBlocks in PHI nodes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5035 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-15 08:02:51 +00:00
Misha Brukman
0868667f78 Fixed a bug where moves due to phis were being neglected.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5019 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-13 12:33:31 +00:00
Misha Brukman
74676da6f1 Need to insert all moves due to PHI nodes before *ALL* jumps in a predecessor
basic block, as there could be multiple.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5016 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-13 11:55:59 +00:00
Misha Brukman
972b03fa53 This should be more correct: invalidates physical registers that are used in
an instruction to avoid using them to allocate to other virtual registers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5013 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-13 11:33:22 +00:00
Misha Brukman
59b3eedf31 Fixed bug with running out of registers. Also, reinstated namespace which
disappeared during the last checkin.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5007 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-13 10:42:31 +00:00
Misha Brukman
203b769b20 This should handle register allocating PHI nodes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5002 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-13 09:54:36 +00:00
Misha Brukman
cea2245f04 Start allocating stack space at [ebp-4] to not overwrite the return address.
Also make all loads & stores 4-byte aligned for performance. ;)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4982 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-13 04:34:02 +00:00
Misha Brukman
d1bedcced2 Take advantage of our knowledge of 2-address X86 instructions and
register-allocated them appropriately.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4976 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-12 23:20:31 +00:00
Misha Brukman
dd46e2a81d Added code generation for function prologues and epilogues.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4930 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-04 23:58:08 +00:00
Misha Brukman
06f8aecc88 Fun arithmetic with iterators aimed at fixing a bug: inserting instructions
after the *current* instruction while keeping the iterator in the same
'logical' place.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4923 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-04 19:24:45 +00:00
Chris Lattner
b72d221d61 Print out direct global references
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4906 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-04 06:44:41 +00:00
Misha Brukman
dc2ec004f1 This should fix the bug seen with some registers not being allocated
correctly: skipping instructions by incorrectly incrementing the pointer.

Also adds support for building a reg-to-regclass map, and splits the function
for saving register to stack into two, one suitable for virtual registers
(which also assigns it a physical register) and one for simply storing back
physical registers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4898 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-03 23:15:19 +00:00
Chris Lattner
f815aebd20 Checkin debug implementation of MCE
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4893 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-03 20:56:42 +00:00
Misha Brukman
f514d51b20 * Abstracted out stack space allocation into its own function
* Added saving of register values to the stack


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4858 91177308-0d34-0410-b5e6-96231b3b80d8
2002-12-02 21:11:58 +00:00
Misha Brukman
0721867c8d A simple (spilling) register allocator.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4828 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-22 22:44:32 +00:00
Misha Brukman
b7825bc725 Initialize the SSARegMap.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4782 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-20 18:55:27 +00:00
Chris Lattner
af55be15df Print is const!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4737 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-17 23:22:13 +00:00
Chris Lattner
570f55de8d Remove only uses of markDef/markDefAndUse methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4719 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-17 22:14:08 +00:00
Chris Lattner
0006bd7520 Fix warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4649 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-09 00:49:43 +00:00
Chris Lattner
5da2e6ac70 Move function to cpp file from header
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4510 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 22:07:51 +00:00
Chris Lattner
ec3e2f41cd New iostream definitions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4482 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-01 16:46:05 +00:00
Vikram S. Adve
26fbcec43b Restore support for indirect function calls (which briefly wasn't working
after I removed annotations on MachineInstr for the CallDescriptor).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4469 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-31 15:34:48 +00:00
Chris Lattner
188732c971 Remove fixme
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4447 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 02:02:37 +00:00
Chris Lattner
6a592271fb Add special code to make printing SSA form machine instructions nicer
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4446 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 01:55:38 +00:00
Chris Lattner
2a79a0927c Use MRegisterInfo, if available, to print symbolic register names
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4438 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 00:58:19 +00:00
Chris Lattner
1049164aa6 Implement structured machine code printing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4435 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 00:48:05 +00:00
Chris Lattner
88726188fe Make argsize calculation stuff optional, so that Targets without FrameInfo
objects yet don't die


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4427 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 23:40:03 +00:00
Chris Lattner
ddd7fcb887 Implement autoinserting ctor
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4426 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 23:19:00 +00:00
Chris Lattner
e316efc0e7 Rename annotation id
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4425 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 23:18:43 +00:00
Chris Lattner
ba64363562 Merge with sparc backend
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4403 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 20:10:58 +00:00
Chris Lattner
495fe2e087 X86 merge is complete, eliminate unused code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4400 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 20:07:16 +00:00
Vikram S. Adve
a2bae305fb Remove separate vector of implicit refs from MachineInstr, and
instead record them as extra operands in the operands[] vector.
Also, move CallArgsDescriptor into this class instead of making it an
annotation on the machine instruction.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4399 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 19:41:18 +00:00
Vikram S. Adve
e68a3435ee Move CallArgsDescriptor into this class instead of making it an
annotation on the machine instruction.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4398 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 19:38:46 +00:00
Chris Lattner
f1757c414c Move TargetInstrDescriptors extern to the one .cpp file that refers to it:
MachineInstr.cpp


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4392 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:40:30 +00:00
Chris Lattner
d9512caca8 Use higher level methods, don't use TargetInstrDescriptors directly!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4389 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:35:39 +00:00
Chris Lattner
8f7802727f Use higher level method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4386 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:25:41 +00:00
Chris Lattner
ea9d249595 Remove #include, misleading comment, and a typedef used only once
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4383 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:08:05 +00:00
Chris Lattner
88da77c739 Inline typedef, eliminate unused method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4382 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:03:19 +00:00
Chris Lattner
67eaf73c89 Remove long dead #if 0
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4381 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:00:19 +00:00
Chris Lattner
cb6b4bd1c6 Add #includes that were eliminated from headers
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4380 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 16:51:05 +00:00
Chris Lattner
770feb4bfc De-inline methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4379 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 16:50:33 +00:00
Chris Lattner
a80848704a Remove #include
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4378 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 16:50:20 +00:00
Chris Lattner
97d688515e Remove unneeded #include
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4377 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 16:50:06 +00:00
Chris Lattner
9538cecf27 Remove forward decl
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4376 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 16:49:44 +00:00
Chris Lattner
28760f4e77 Make assertIGNode be private to the InterferenceGraph.cpp file
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4375 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 16:42:34 +00:00
Chris Lattner
c5b8b1a040 MachineInstrInfo no longer #includes this header, so we must
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4366 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 23:54:47 +00:00
Chris Lattner
9a8e4121aa Remove all traces of the "Opcode Mask" field in the MachineInstr class
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4359 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 21:17:20 +00:00
Chris Lattner
b98a53f201 Remove more default arguments that are never used
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4358 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 21:02:40 +00:00
Chris Lattner
7279122e66 Remove default operands that are never used
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4357 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 20:59:49 +00:00
Chris Lattner
413746e983 * Make MachineOperand ctors private, so MachineOperand can only be created
by MachineInstr.
* Add a bunch of new methods to allow incremental addition of operands to the
  machine instr instance.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4356 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 20:48:39 +00:00
Misha Brukman
b7551ef115 Replaced uses of deprecated `MachineFunction::get(BasicBlock *BB)'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4351 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 20:00:31 +00:00
Chris Lattner
2f305989b3 Remove two arguments that are never specified
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4348 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 19:46:59 +00:00
Chris Lattner
ccdf23ebbb Rename some regalloc fields
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4346 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 19:43:23 +00:00
Chris Lattner
f726e776b8 Eliminate usage of MachineBasicBlock::get
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4344 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 19:22:04 +00:00
Chris Lattner
fcffe865f9 Remove usage of MachineBasicBlock::get
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4342 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 19:01:16 +00:00
Chris Lattner
fb3a0aed9b Remove usage of MachineBasicBlock::get
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4341 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 18:50:08 +00:00
Chris Lattner
b84a2ba877 Eliminate unneccesary use of MachineBasicBlock::get
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4339 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 06:01:57 +00:00
Chris Lattner
335d5c399b s/method/function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4338 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 05:58:46 +00:00
Chris Lattner
d0aa0cdbc6 Change MachineBasicBlock's to not be Annotations, instead they are kept as
part of a linked list tracked by MachineFunction.  MachineBasicBlock::get
is now linear time instead of constant time, and thus is deprecated!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4337 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 05:30:46 +00:00
Chris Lattner
c5ddc8b74b Make Scheduling Class variables be 'unsigned' instead of 'int'
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4333 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 04:53:02 +00:00
Chris Lattner
133f079c8c Rename the redundant MachineOperand::getOperandType() to MachineOperand::getType()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4331 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 04:45:29 +00:00
Chris Lattner
572f5c8c0c Fairly major overhaul of MachineInstr & Operand classes
- Inline methods that are mostly a single line anyway
  - Eliminate several methods that were never called
  - Group methods a bit more consistently


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4329 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 04:24:49 +00:00
Chris Lattner
0be79c6c1b Add #includes now that MachineInstr.h doesn't include llvm/Target/MachineInstrInfo.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4327 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 02:28:39 +00:00
Chris Lattner
4a63b72df9 Don't #include <Support/*>, #include "Support/*"
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4325 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 02:11:53 +00:00
Chris Lattner
e61a584f98 *** empty log message ***
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4323 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 02:01:37 +00:00
Chris Lattner
e7d27fa00b MachineFunction now includes MachineBasicBlock so there is no need to
reinclude it


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4322 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 02:01:35 +00:00
Chris Lattner
55291ead55 Rename MachineCodeForBasicBlock to MachineBasicBlock
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4318 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 01:41:47 +00:00
Chris Lattner
32be9f6cd4 *** empty log message ***
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4317 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 01:41:27 +00:00
Chris Lattner
51a8d85281 Inline some methods from .cpp files into .h files, minor cleanups
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4313 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 01:21:55 +00:00
Chris Lattner
6b9445389a Minor cleanups
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4312 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 01:16:38 +00:00
Chris Lattner
227c3d355b Move machine code generation/destruction passes out of Sparc.cpp because
they are generic


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4310 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 01:12:41 +00:00
Chris Lattner
1febf88ef4 Prune #includes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4307 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 01:02:51 +00:00
Chris Lattner
0c68e8ce6e Updates to match misha's changes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4302 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 00:37:53 +00:00
Misha Brukman
fce1143bcf Changed MachineCodeForMethod' to MachineFunction'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4301 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-28 00:28:31 +00:00
Chris Lattner
78cee7e7ab Initial checkin of codegen infrastructure for LLVM-JIT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4282 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-25 22:54:41 +00:00
Chris Lattner
a0877726df Tell PassManager that this pass does not invalidate the CFG so that dominator
information and Loop info will not have to be recomputed after this runs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4269 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-23 03:30:47 +00:00
Chris Lattner
0ceeb42c97 Ensure definate initialization
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4263 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-22 23:34:11 +00:00
Chris Lattner
27a08935ca - Two minor improvements to the MachineInstr class to reduce footprint and
overhead: Merge 3 parallel vectors into 1, change regsUsed hash_set to be a
    bitvector.  Sped up LLC a little less than 10% in a debug build!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4261 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-22 23:16:21 +00:00
Vikram S. Adve
cf911de3c6 Significant improvement: GEP used by a load or store no longer generates
a separate ADD; instead just use the indexed load/store instruction!
Also, a bug fix: folding a GEP with a leading non-zero index with
its predecessor was incorrect: now it only happens if the predecessor
is pointing to an indexable type (aka SequentialType).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4168 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-14 16:30:55 +00:00
Vikram S. Adve
1632e882f1 Use vectors instead of hash_maps for issueGaps and conflictLists.
These hash lookups were a major sink of time because they happen so often!
Also, add option to disable scheduling.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4138 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-13 00:40:37 +00:00
Vikram S. Adve
acf0f704f9 Major bug fix: was not adding CD edges for RETURNs!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4137 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-13 00:39:22 +00:00
Vikram S. Adve
cb202e3de5 Major bug fix: spill code for an instruction in a delay slot was
merrily being inserted before/after the instruction!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4116 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-11 16:12:40 +00:00