aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target
Commit message (Collapse)AuthorAgeFilesLines
* Another API change to MRegisterInfo::foldMemoryOperand. Instead of aAlkis Evlogimenos2004-03-142-5/+4
| | | | | | | MachineBasicBlock::iterator take a MachineInstr*. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12392 91177308-0d34-0410-b5e6-96231b3b80d8
* Change MRegisterInfo::foldMemoryOperand to return the foldedAlkis Evlogimenos2004-03-142-171/+166
| | | | | | | instruction to make the API more flexible. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12386 91177308-0d34-0410-b5e6-96231b3b80d8
* It helps if I save the file. :)Chris Lattner2004-03-132-6/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12357 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename the intrinsic enum values for llvm.va_* from Intrinsic::va_* toChris Lattner2004-03-136-27/+24
| | | | | | | Intrinsic::va*. This avoid conflicting with macros in the stdlib.h file. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12356 91177308-0d34-0410-b5e6-96231b3b80d8
* Make -print-machineinstrs show us the code both before and after reg. alloc.Brian Gaeke2004-03-121-1/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12344 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for a wider range of CMOV instructions.Alkis Evlogimenos2004-03-121-2/+54
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12336 91177308-0d34-0410-b5e6-96231b3b80d8
* ADd support for select instructionsChris Lattner2004-03-122-0/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12316 91177308-0d34-0410-b5e6-96231b3b80d8
* Move implementations of functions here, which avoids #including <cstdlib> in theMisha Brukman2004-03-111-0/+86
| | | | | | | header file and all those who #include it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12297 91177308-0d34-0410-b5e6-96231b3b80d8
* Get rid of the abort in PhyRegAlloc::finishSavingState().Brian Gaeke2004-03-111-5/+6
| | | | | | | | | Make an explicit call to it from runOnFunction() if we know we're supposed to write into the global. This is lame (esp. the const_cast), but it solves the problem. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12291 91177308-0d34-0410-b5e6-96231b3b80d8
* Give pass a nameBrian Gaeke2004-03-111-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12290 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix compilation on Sparc: assert(0) => abort()Misha Brukman2004-03-112-10/+10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12289 91177308-0d34-0410-b5e6-96231b3b80d8
* In PhyRegAlloc::saveState(), dump Arguments' saved-state, and try toBrian Gaeke2004-03-112-10/+31
| | | | | | | | | | | | | | make the output more compact. Divorce state-saving from the doFinalization method; for some reason it's not getting called when I want it to, at Reoptimizer time. Put the guts in PhyRegAlloc::finishSavingState(). Put an abort() in it so that I can be really really sure that it's getting called. Update comments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12286 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove ghostly directory from the buildBrian Gaeke2004-03-111-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12285 91177308-0d34-0410-b5e6-96231b3b80d8
* Move all the SaveState options and stuff inton one spot at the top of the file.Brian Gaeke2004-03-101-8/+10
| | | | | | | | | De-constify SaveStateToModule; we have to set both it and SaveRegAllocState explicitly in the reoptimizer. Make SaveRegAllocState an 'external location' option. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12278 91177308-0d34-0410-b5e6-96231b3b80d8
* Only call verifySavedState if SaveRegAllocState is set AND debugging flag is on.Brian Gaeke2004-03-101-3/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12277 91177308-0d34-0410-b5e6-96231b3b80d8
* Check if printing of implicit uses is required for all types of shiftAlkis Evlogimenos2004-03-092-0/+6
| | | | | | | instructions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12258 91177308-0d34-0410-b5e6-96231b3b80d8
* Hmm, who left this sitting around in my treeBrian Gaeke2004-03-094-16/+16
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12255 91177308-0d34-0410-b5e6-96231b3b80d8
* Differentiate between extended precision floats (80-bit) and double ↵Alkis Evlogimenos2004-03-091-1/+1
| | | | | | precision floats (64-bit) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12254 91177308-0d34-0410-b5e6-96231b3b80d8
* Use newly added API to emit bytes for instructions that gas misassemblesAlkis Evlogimenos2004-03-092-132/+106
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12253 91177308-0d34-0410-b5e6-96231b3b80d8
* Add emitInstruction() API so that we can get the bytes of a simple instructionAlkis Evlogimenos2004-03-092-3/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12252 91177308-0d34-0410-b5e6-96231b3b80d8
* Constify things a bitAlkis Evlogimenos2004-03-091-9/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12251 91177308-0d34-0410-b5e6-96231b3b80d8
* Change PhyRegAlloc::saveStateForValue()'s arg type to deal withBrian Gaeke2004-03-081-1/+1
| | | | | | | AllocInfo.Instruction becoming an int. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12247 91177308-0d34-0410-b5e6-96231b3b80d8
* Save argument list alloc state by recording it as the operands of InstructionBrian Gaeke2004-03-081-2/+10
| | | | | | | #-1. Other minor changes to deal with AllocInfo.Instruction becoming an int. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12246 91177308-0d34-0410-b5e6-96231b3b80d8
* Make AllocInfo's Instruction an int, so that we can overload it for arguments.Brian Gaeke2004-03-081-4/+4
| | | | | | | (Instruction #-1's operands = argument list). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12245 91177308-0d34-0410-b5e6-96231b3b80d8
* Avoid allocating special registers a bit more robustlyChris Lattner2004-03-082-6/+22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12207 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement folding explicit load instructions into binary operations. For aChris Lattner2004-03-082-0/+162
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | testcase like this: int %test(int* %P, int %A) { %Pv = load int* %P %B = add int %A, %Pv ret int %B } We now generate: test: mov %ECX, DWORD PTR [%ESP + 4] mov %EAX, DWORD PTR [%ESP + 8] add %EAX, DWORD PTR [%ECX] ret Instead of: test: mov %EAX, DWORD PTR [%ESP + 4] mov %ECX, DWORD PTR [%ESP + 8] mov %EAX, DWORD PTR [%EAX] add %EAX, %ECX ret ... saving one instruction, and often a register. Note that there are a lot of other instructions that could use this, but they aren't handled. I'm not really interested in adding them, but mul/div and all of the FP instructions could be supported as well if someone wanted to add them. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12204 91177308-0d34-0410-b5e6-96231b3b80d8
* Rearrange and refactor some code. No functionality changes.Chris Lattner2004-03-082-202/+192
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12203 91177308-0d34-0410-b5e6-96231b3b80d8
* Add memory operand version of conditional move.Alkis Evlogimenos2004-03-072-3/+10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12190 91177308-0d34-0410-b5e6-96231b3b80d8
* Support return values of basic integer types.Brian Gaeke2004-03-064-96/+148
| | | | | | | | Emit RETL instruction to return instead of funny JMPL. Fix indentation. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12186 91177308-0d34-0410-b5e6-96231b3b80d8
* Sort stanzas into Sparc V8 book page number order.Brian Gaeke2004-03-062-34/+46
| | | | | | | Add RET, RETL. Rename SAVE, RESTORE & JMPL for consistency. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12185 91177308-0d34-0410-b5e6-96231b3b80d8
* Hack it so we do not try to allocate values to G0.Brian Gaeke2004-03-062-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12184 91177308-0d34-0410-b5e6-96231b3b80d8
* Make prolog align stack properly. Make epilog not touch any registers.Brian Gaeke2004-03-062-8/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12183 91177308-0d34-0410-b5e6-96231b3b80d8
* Emit register names in lowercase, as required by the assembler.Brian Gaeke2004-03-062-2/+22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12182 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach getRegClassForType where to find FP registersBrian Gaeke2004-03-062-6/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12180 91177308-0d34-0410-b5e6-96231b3b80d8
* Asm output is looking a lot better; not correct for all operands yet though.Brian Gaeke2004-03-052-2/+124
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12143 91177308-0d34-0410-b5e6-96231b3b80d8
* Support -print-machineinstrsBrian Gaeke2004-03-042-12/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12124 91177308-0d34-0410-b5e6-96231b3b80d8
* make -print-machineinstrs work for both SparcV9 and X86Brian Gaeke2004-03-043-10/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12122 91177308-0d34-0410-b5e6-96231b3b80d8
* Add assertion for scale verification.Alkis Evlogimenos2004-03-041-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12120 91177308-0d34-0410-b5e6-96231b3b80d8
* Asm printer support, based on x86 - only prints mnemonics for nowBrian Gaeke2004-03-046-4/+924
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12113 91177308-0d34-0410-b5e6-96231b3b80d8
* Double-FP pseudo-registers.Brian Gaeke2004-03-042-6/+72
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12112 91177308-0d34-0410-b5e6-96231b3b80d8
* Subtract instructions; minor cleanupsBrian Gaeke2004-03-046-18/+32
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12111 91177308-0d34-0410-b5e6-96231b3b80d8
* Floating point regsBrian Gaeke2004-03-042-4/+34
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12110 91177308-0d34-0410-b5e6-96231b3b80d8
* Simple copyConstantToReg support, SETHIi and ORriBrian Gaeke2004-03-046-16/+88
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12107 91177308-0d34-0410-b5e6-96231b3b80d8
* Support add - note, still missing important copyConstantToRegister stuffBrian Gaeke2004-03-036-10/+614
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12106 91177308-0d34-0410-b5e6-96231b3b80d8
* SPECIFY a target data to initialize the CBE target with. Until now we haveChris Lattner2004-03-031-1/+1
| | | | | | | | | been using the default target data layout object to lower malloc instructions, causing us to allocate more memory than we needed! This could improve the performance of the CBE generated code substantially! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12088 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new constructorChris Lattner2004-03-031-0/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12087 91177308-0d34-0410-b5e6-96231b3b80d8
* Doxygenify some comments.Misha Brukman2004-03-014-18/+42
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12064 91177308-0d34-0410-b5e6-96231b3b80d8
* Add this back, as its absence introduces assertions, and it seems to work nowChris Lattner2004-03-011-4/+1
| | | | | | | that Instructions are annotable again git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12045 91177308-0d34-0410-b5e6-96231b3b80d8
* fix bug in previous checkinTanya Lattner2004-03-011-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12044 91177308-0d34-0410-b5e6-96231b3b80d8
* TargetCacheInfo has been removed; its only uses were to propagate a constantBrian Gaeke2004-03-019-49/+6
| | | | | | | | | | (16) into certain areas of the SPARC V9 back-end. I'm fairly sure the US IIIi's dcache has 32-byte lines, so I'm not sure where the 16 came from. However, in the interest of not breaking things any more than they already are, I'm going to leave the constant alone. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12043 91177308-0d34-0410-b5e6-96231b3b80d8