Commit Graph

831 Commits

Author SHA1 Message Date
Chris Lattner
e2954c84e9 shuffle code around a bit, implement and, or, xor
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4502 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 20:04:26 +00:00
Chris Lattner
51b49a9633 Add PHI node support, add comment for branch function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4500 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 19:45:49 +00:00
Chris Lattner
2df035bb3c Implement unconditional branching support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4498 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 19:27:56 +00:00
Chris Lattner
e9913f2cff * Fix nonconstant shift case
* Turn table into 2d table


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4496 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 01:41:55 +00:00
Chris Lattner
b1761fc4df Use a more table driven approach to handling types. Seems to simplify the
code a bit


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4493 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 01:15:18 +00:00
Chris Lattner
d5a87f80b7 Make switch statements denser, but only because of the follow-on patch
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4492 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 00:49:56 +00:00
Chris Lattner
796df73e6e * Remove dead variable
* Shift amount is always guaranteed to be 8 bits


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4491 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-02 00:44:25 +00:00
Nick Hildenbrandt
7e9fea736d Fixed bug in Regression/CBackend/2002-10-30-FunctionPointerAlloca.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4486 91177308-0d34-0410-b5e6-96231b3b80d8
2002-11-01 17:37:09 +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
Brian Gaeke
a1719c9130 InstSelectSimple.cpp: Include llvm/iOther.h for ShiftInst.
Add ISel::visitShiftInst() to instruction select shift instructions.
 Add a comment in visitAdd about how to do 64 bit adds.

X86InstrInfo.def: Add register-to-register move opcodes and shift opcodes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4477 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-31 23:03:59 +00:00
Chris Lattner
59b2b86f35 Reassociate pass now works
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4473 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-31 17:16:18 +00:00
Vikram S. Adve
601899d196 Bug fix: need to initialize new CallArgsDescriptor pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4453 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 20:38:49 +00:00
Vikram S. Adve
9691807669 In getID(), don't call getValidSymbolName to mangle external names!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4451 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 20:16:38 +00:00
Chris Lattner
cc0b0c59e8 Add lots more info
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4450 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 06:04:46 +00:00
Chris Lattner
8548ee75eb Make sure to set the destination register correctly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4444 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 01:49:01 +00:00
Chris Lattner
b752e9a2ae Set the destination register field based on the target specific flags
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4442 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 01:15:31 +00:00
Chris Lattner
9d17740295 Add flag to specify when no value is produced by an instruction
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4441 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 01:09:34 +00:00
Chris Lattner
443d0122d7 Sparc backend doesn't use target specific flags yet
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4440 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 01:07:12 +00:00
Chris Lattner
e5f5221b5e Implement the new optional getRegisterInfo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4437 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 00:56:18 +00:00
Chris Lattner
3dffa7953f Print machine code after instruction selection
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4434 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 00:47:49 +00:00
Chris Lattner
42c7786227 Make sure to pass the LLVM basic block in
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4433 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-30 00:47:40 +00:00
Chris Lattner
36b36037a3 Construct annotation, to make sure it's attached to function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4429 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 23:40:58 +00:00
Misha Brukman
a3bbcb5b66 Fix spelling of `propagate'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4423 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 23:06:16 +00:00
Chris Lattner
b4f68ed32e Convert backend to use passes, implement X86TargetMachine
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4421 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 22:37:54 +00:00
Chris Lattner
c66583ef3b These are no longer virtual methods
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4420 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 22:01:44 +00:00
Chris Lattner
c56406c236 * Privatize the TargetName
* Move optSizeForSubWordData to TargetData
* Remove unused fields


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4417 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 21:48:17 +00:00
Chris Lattner
62eaf7ef60 Implement findOptimalStorageSize a bit more generally
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4416 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 21:47:50 +00:00
Chris Lattner
6334205cb5 Allow TargetMachine to refuse static code gen
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4415 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 21:12:46 +00:00
Chris Lattner
055c965bff Rename X86InstructionInfo to X86InstrInfo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4413 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 21:05:24 +00:00
Chris Lattner
33f53b554a Minor renaming
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4410 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 20:48:56 +00:00
Chris Lattner
eef7454e1c Remove unneccesary #includes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4408 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 20:47:46 +00:00
Chris Lattner
600e699794 Rename Sparc.h to TargetMachineImpls.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4407 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 20:47:26 +00:00
Chris Lattner
b85c7f4b91 Reenable X86 backend, even though it doesn't do much, at least it compiles
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4404 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 20:29:34 +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
Vikram S. Adve
aabb595c4f Bug fix: align size for dynamic allocas according to stack pointer
alignment restrictions.  This is incomplete for one case.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4397 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 19:37:31 +00:00
Chris Lattner
341a937169 Switch to generating machineinstr's instead of MInstructions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4396 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:43:55 +00:00
Chris Lattner
a535fabe7d Be compatible with sparc backend
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4395 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:43:38 +00:00
Chris Lattner
9bbf439e38 Implement MachineInstrInfo interface
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4394 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:43:19 +00:00
Chris Lattner
79c033765c Switch to different flag set
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4393 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:42:40 +00:00
Chris Lattner
adc101bbcd Move TargetInstrDescriptors to MachineInstrInfo.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4391 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:37:48 +00:00
Chris Lattner
f44f905196 *** empty log message ***
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4390 91177308-0d34-0410-b5e6-96231b3b80d8
2002-10-29 17:35:41 +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