Vikram S. Adve
689adb19b0
Change interface to MachineInstr::substituteValue to specify more precisely
...
which args can be substituted: defsOnly, defsAndUses or usesOnly.
llvm-svn: 7154
2003-07-10 19:45:07 +00:00
Vikram S. Adve
c468882155
Allow explicit physical registers for implicit operands.
...
llvm-svn: 6468
2003-05-31 07:39:06 +00:00
Vikram S. Adve
7366fa1aa6
(1) Added special register class containing (for now) %fsr.
...
Fixed spilling of %fcc[0-3] which are part of %fsr.
(2) Moved some machine-independent reg-class code to class TargetRegInfo
from SparcReg{Class,}Info.
(3) Renamed MachienOperand::opIsDef to MachineOperand::opIsDefOnly()
and related functions and flags. Fixed several bugs where only
"isDef" was being checked, not "isDefAndUse".
llvm-svn: 6341
2003-05-27 00:05:23 +00:00
Chris Lattner
5da071b265
Remove obsolete ctor
...
llvm-svn: 5301
2003-01-15 19:47:02 +00:00
Chris Lattner
b4d58d7f9e
Rename MachineInstrInfo -> TargetInstrInfo
...
llvm-svn: 5272
2003-01-14 22:00:31 +00:00
Chris Lattner
a2ad874c95
Add support for 3 new forms of MachineOperand
...
llvm-svn: 5217
2003-01-13 00:23:24 +00:00
Chris Lattner
fd1ecadb1d
* Add printing support for FrameIndex operands
...
llvm-svn: 5194
2002-12-28 20:37:37 +00:00
Chris Lattner
f895418b47
Implement printing of MBB arguments
...
llvm-svn: 5053
2002-12-15 20:35:25 +00:00
Chris Lattner
d8ea18b695
Print is const!
...
llvm-svn: 4737
2002-11-17 23:22:13 +00:00
Chris Lattner
17ec8a8dd0
Remove only uses of markDef/markDefAndUse methods
...
llvm-svn: 4719
2002-11-17 22:14:08 +00:00
Chris Lattner
6c614a9931
Remove fixme
...
llvm-svn: 4447
2002-10-30 02:02:37 +00:00
Chris Lattner
ac6e97410b
Add special code to make printing SSA form machine instructions nicer
...
llvm-svn: 4446
2002-10-30 01:55:38 +00:00
Chris Lattner
4e9fb1f52e
Use MRegisterInfo, if available, to print symbolic register names
...
llvm-svn: 4438
2002-10-30 00:58:19 +00:00
Chris Lattner
214808f8ac
Implement structured machine code printing
...
llvm-svn: 4435
2002-10-30 00:48:05 +00:00
Chris Lattner
27ccb70df6
Implement autoinserting ctor
...
llvm-svn: 4426
2002-10-29 23:19:00 +00:00
Vikram S. Adve
a1b4f0f85e
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.
llvm-svn: 4399
2002-10-29 19:41:18 +00:00
Chris Lattner
07e26837a9
Move TargetInstrDescriptors extern to the one .cpp file that refers to it:
...
MachineInstr.cpp
llvm-svn: 4392
2002-10-29 17:40:30 +00:00
Chris Lattner
660bf10981
Use higher level methods, don't use TargetInstrDescriptors directly!
...
llvm-svn: 4389
2002-10-29 17:35:39 +00:00
Chris Lattner
5c7d638208
Remove all traces of the "Opcode Mask" field in the MachineInstr class
...
llvm-svn: 4359
2002-10-28 21:17:20 +00:00
Chris Lattner
bee314fc94
Remove more default arguments that are never used
...
llvm-svn: 4358
2002-10-28 21:02:40 +00:00
Chris Lattner
307fb1a314
Remove default operands that are never used
...
llvm-svn: 4357
2002-10-28 20:59:49 +00:00
Chris Lattner
ca4a9d20b8
* 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.
llvm-svn: 4356
2002-10-28 20:48:39 +00:00
Chris Lattner
864d279667
Remove two arguments that are never specified
...
llvm-svn: 4348
2002-10-28 19:46:59 +00:00
Chris Lattner
340bb96e64
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
llvm-svn: 4329
2002-10-28 04:24:49 +00:00
Chris Lattner
9668c8c8db
Add #includes now that MachineInstr.h doesn't include llvm/Target/MachineInstrInfo.h
...
llvm-svn: 4327
2002-10-28 02:28:39 +00:00
Chris Lattner
ce64eddb71
- 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!
llvm-svn: 4261
2002-10-22 23:16:21 +00:00
Vikram S. Adve
97c348d9ec
Add method MachineInstr::replace to rewrite a machine instruction in place.
...
llvm-svn: 3843
2002-09-20 00:47:49 +00:00
Vikram S. Adve
751130215f
Dump routine now writes out allocated register numbers if available.
...
llvm-svn: 3737
2002-09-16 15:18:53 +00:00
Vikram S. Adve
fa99db77a8
Add method MachineInstr::substituteValue() which substitutes
...
one Value with another one in all operands and implicit references
of the machine instruction.
llvm-svn: 3306
2002-08-14 16:52:58 +00:00
Chris Lattner
959a5fbf8e
* Removed extraneous #includes
...
* Fixed file headers to be consistent with the rest of LLVM
* Other minor fixes
llvm-svn: 3278
2002-08-09 20:08:06 +00:00
Chris Lattner
10073a9080
*** empty log message ***
...
llvm-svn: 3075
2002-07-25 06:17:51 +00:00
Vikram S. Adve
f089faa7f6
Add support for marking each operand as a %hh, %hm, %lm or %lo.
...
Represent previous bools and these ones with flags in a single byte
per operand.
llvm-svn: 2860
2002-07-10 21:45:04 +00:00
Vikram S. Adve
6c013a9689
Moved class MachineCodeForBasicBlock to MachineCodeForBasicBlock.{cpp,h}.
...
An (explicit or implicit) operand may now be both a def and a use.
Also add a set of regs used by each instruction.
dump() no longer takes an optional argument, which doesn't work in gdb.
llvm-svn: 2821
2002-07-08 22:38:45 +00:00
Vikram S. Adve
d79d2c3892
Improve printing during dumps.
...
llvm-svn: 2311
2002-04-25 04:31:18 +00:00
Chris Lattner
95f65b6f84
s/method/function
...
llvm-svn: 2177
2002-04-08 22:01:15 +00:00
Vikram S. Adve
307916c008
Bug fix in setting CC register.
...
Also use distinct names for the three types of SetMachineOperand
to avoid painful overloading problems and errors.
llvm-svn: 1904
2002-03-18 03:35:24 +00:00
Chris Lattner
4cec147d4e
* Prune #includes
...
* Remove MachineCodeFor(Method|VMInstr) code to their own .cpp files
llvm-svn: 1649
2002-02-03 07:46:01 +00:00
Chris Lattner
7f74a56e24
Changes to build successfully with GCC 3.02
...
llvm-svn: 1503
2002-01-20 22:54:45 +00:00
Chris Lattner
2413b160ec
Renamed inst_const_iterator -> const_inst_iterator
...
Renamed op_const_iterator -> const_op_iterator
Renamed PointerType::getValueType() -> PointerType::getElementType()
llvm-svn: 1408
2001-12-04 00:03:30 +00:00
Ruchira Sasanka
ec62f24009
Added naming to inserted phi copy values - for easy debugging
...
llvm-svn: 1325
2001-11-15 20:46:40 +00:00
Vikram S. Adve
fbb8a64749
Modify AllocateLocalVar method to take a size argument.
...
llvm-svn: 1318
2001-11-15 15:22:26 +00:00
Ruchira Sasanka
64f7567391
Small changed to printing a machine operand - It the operand is a def, it prints
...
a star after it - only for debugging
llvm-svn: 1309
2001-11-14 20:05:23 +00:00
Vikram S. Adve
4b9c46da24
Bug fix in offset alignment computations: don't subtract the padding
...
value from size *before* subtracting size from offset!
llvm-svn: 1283
2001-11-12 23:26:23 +00:00
Vikram S. Adve
6e004c0818
Improved printing routines.
...
llvm-svn: 1263
2001-11-12 14:19:47 +00:00
Vikram S. Adve
3b02a35a80
Adjust all stack variable offsets to be aligned by size.
...
llvm-svn: 1261
2001-11-12 05:17:23 +00:00
Vikram S. Adve
1d5c6e0939
Fix errors in computing downgrowing offsets, and in
...
computing size of extra outgoing args.
llvm-svn: 1256
2001-11-11 21:23:33 +00:00
Vikram S. Adve
c53037205b
Major overhaul of stack frame management.
...
llvm-svn: 1185
2001-11-08 04:47:06 +00:00
Vikram S. Adve
59a13288a6
Make reg. numbers signed ints.
...
llvm-svn: 1137
2001-11-05 03:56:02 +00:00
Vikram S. Adve
cc80b02834
Added class MachineCodeForMethod.
...
llvm-svn: 947
2001-10-22 13:51:33 +00:00
Ruchira Sasanka
59e864eb92
Added implict operand printing for operator( ostream, MachineInstr&)
...
llvm-svn: 912
2001-10-18 22:40:02 +00:00
Vikram S. Adve
6d19dc9080
1. Add a bottom-up pass on BURG trees that is used to fix constant operands.
...
Needs to be bottom up because constant values may be forward-substituted
to their uses (i.e., into the parent in the BURG tree).
2. Move most of the constant-fixup code into machine-indepedent file
InstrSelectionSupport.cpp.
llvm-svn: 859
2001-10-17 23:57:50 +00:00
Vikram S. Adve
c36a504cfe
Moved code generation support routines to InstrSelectionSupport.cpp.
...
llvm-svn: 717
2001-10-10 20:49:07 +00:00
Chris Lattner
3856934386
Convert more code to use new style casts
...
Eliminate old style casts from value.h
llvm-svn: 696
2001-10-01 20:11:19 +00:00
Vikram S. Adve
e44abbb99d
Improved dump for disp type operand.
...
llvm-svn: 679
2001-09-30 23:44:19 +00:00
Vikram S. Adve
bb81dae651
Minor changes.
...
llvm-svn: 613
2001-09-18 12:56:28 +00:00
Ruchira Sasanka
bae3812a95
added setRegForValue to MachineOperand class
...
llvm-svn: 591
2001-09-15 19:07:45 +00:00
Chris Lattner
706ee8e5ec
Eliminate MainTreeNode function
...
llvm-svn: 550
2001-09-11 23:22:43 +00:00
Chris Lattner
acfa507663
Fix a bug I introduced (assertion failed: Unknown operand type), and convert to predicate style for type checks
...
llvm-svn: 531
2001-09-10 19:43:38 +00:00
Chris Lattner
e4fe7bc4a5
Implement the subset of the GetConstantValueAsSignedInt function that is needed, locally.
...
llvm-svn: 524
2001-09-09 23:01:32 +00:00
Chris Lattner
c49f5f35db
Fix problems with freeing memory twice
...
llvm-svn: 520
2001-09-09 22:26:29 +00:00
Chris Lattner
57de997eff
Fix build breakage. :(
...
llvm-svn: 511
2001-09-09 19:52:23 +00:00
Chris Lattner
23fcc08d38
The header file for a translation unit should always be included first
...
System headers should be last
llvm-svn: 475
2001-09-07 17:18:30 +00:00
Vikram S. Adve
5f72f42aee
Moved function PrintMachineInstructions here.
...
llvm-svn: 392
2001-08-28 23:02:39 +00:00
Vikram S. Adve
1700068262
Always set isDef for operand in position resultPos.
...
llvm-svn: 357
2001-08-13 16:32:45 +00:00
Ruchira Sasanka
6dec5fe042
Changed SetMachineOpernad calls in Set3OperandsFromInstr so that the
...
result position is a def (i.e., added true to the end of call) -- Ruchira
llvm-svn: 356
2001-08-13 16:26:28 +00:00
Ruchira Sasanka
c82322c526
*** empty log message ***
...
llvm-svn: 351
2001-08-07 21:01:23 +00:00
Ruchira Sasanka
4ac2975f5a
added a default isDef arg to SetMachineOperand method - Ruchira
...
llvm-svn: 350
2001-08-07 20:16:52 +00:00
Vikram S. Adve
ff7070bbb9
Allow machine instructions with variable numbers of arguments.
...
This is used only by Phi for now.
llvm-svn: 336
2001-07-31 21:49:28 +00:00
Vikram S. Adve
bff682dfac
Eliminate separate enum for operand register type.
...
Use union for alternative data for different operand types.
Add iterator over Value* operands in a MachineInstr.
llvm-svn: 307
2001-07-28 04:06:37 +00:00
Chris Lattner
78a307b170
Eliminated the Unique class in favor of NonCopyable and NonCopyableV
...
llvm-svn: 280
2001-07-23 18:26:21 +00:00
Chris Lattner
b299068101
Eliminate lots of unnecessary #includes and forward decls
...
there are probably more to kill
llvm-svn: 261
2001-07-21 23:24:48 +00:00
Chris Lattner
dd511760d9
Renamed include/llvm/Codegen to include/llvm/CodeGen
...
llvm-svn: 253
2001-07-21 20:58:30 +00:00
Vikram S. Adve
ab9e557102
Instruction selection via pattern matching on instruction trees using BURG.
...
llvm-svn: 231
2001-07-21 12:41:50 +00:00