Misha Brukman
31b31d94d9
Added asserts to prevent negative shift amounts from being generated.
...
llvm-svn: 7640
2003-08-06 16:28:49 +00:00
Chris Lattner
36498143ba
convert over to using TableGen backends
...
llvm-svn: 7628
2003-08-06 04:36:35 +00:00
Misha Brukman
790a6f5e6c
Stop special-casing annul and predict bits (which are Sparc-specific anyway)
...
since those bits are now hard-coded in Sparc*.td files.
llvm-svn: 7593
2003-08-05 14:35:35 +00:00
Chris Lattner
9c9b4c54fa
No functional changes, comment the fix I just put in
...
llvm-svn: 7590
2003-08-05 03:59:01 +00:00
Chris Lattner
01349f463c
The CodeEmitterGenerator used to consider ANY uninitialized field as being an
...
operand (unless it's annul or predict). Now we only consider fields to be
operands if they are uninitialized AND used in the "Inst" field.
llvm-svn: 7589
2003-08-05 03:53:04 +00:00
Chris Lattner
f0c6964470
DEBUG got moved to Debug.h
...
llvm-svn: 7491
2003-08-01 22:13:59 +00:00
Chris Lattner
2e69d4a1e8
Add new getValueAsBitsInit 'high-level' method
...
llvm-svn: 7467
2003-08-01 04:46:24 +00:00
Chris Lattner
ecca290a2a
Simplify code to match new interfaces
...
llvm-svn: 7464
2003-08-01 04:38:18 +00:00
Chris Lattner
fc6e266410
Minor cleanups
...
llvm-svn: 7462
2003-08-01 04:15:25 +00:00
Chris Lattner
f62c489e35
Factor code out into a new getAllDerivedDefinitions method, which is generally useful
...
llvm-svn: 7461
2003-08-01 04:09:58 +00:00
Chris Lattner
c69df616b8
More minor cleanups of the interface
...
llvm-svn: 7446
2003-07-31 04:43:49 +00:00
Chris Lattner
c5b306b4b9
Rename createEmitter to run because eventually all tablegen backends will
...
be subclasses of a common interface.
llvm-svn: 7445
2003-07-31 04:38:26 +00:00
Chris Lattner
590fd82e42
Don't crash if there is no Inst class in the tablegen file!
...
llvm-svn: 7402
2003-07-29 23:00:08 +00:00
Misha Brukman
ba943afa97
Added a DEBUG() guard to a debug information printout.
...
llvm-svn: 7203
2003-07-18 18:03:45 +00:00
Misha Brukman
c7efa119ac
Fixed a bug: outputting name of variable instead of its value.
...
Also, placed DEBUG() guards around debug information so that the generated file
is much smaller and hence should be faster to preprocess/compile.
llvm-svn: 7180
2003-07-15 21:26:09 +00:00
Misha Brukman
1912eaf0a0
This optimization greatly enhances efficiency of creating new instructions by
...
masking and shifting operands directly into their place in the instruction,
instead of the old-fashioned way of ORing in each bit separately.
llvm-svn: 7179
2003-07-15 21:00:32 +00:00
Misha Brukman
222639708e
Stop using the `Offset' variable, as we are cycling through the bits of a field
...
initializer and the loop index variable already carries the offset information
that we need.
llvm-svn: 7123
2003-07-07 22:30:44 +00:00
Chris Lattner
91ca134e26
Old versions of GCC doesn't have <ostream> :(
...
llvm-svn: 6661
2003-06-06 23:06:20 +00:00
Misha Brukman
72d7da0397
All debug print statements are now output with the DEBUG() guard to make
...
output clean so that tests can automatically diff the output.
llvm-svn: 6643
2003-06-06 00:27:02 +00:00
Misha Brukman
1cca1c68e1
* Stop ignoring cc registers, since we actually use them in branches.
...
* Added comment as to why we are still ignoring predict and annul bits.
llvm-svn: 6636
2003-06-05 23:15:25 +00:00
Misha Brukman
7e66953f17
Stop ignoring the `cc' field, we actually use it now (e.g. conditional move)
...
llvm-svn: 6555
2003-06-03 00:07:17 +00:00
Misha Brukman
027b3d899f
getValueOp() now takes a MachineInstr as well as a MachineOperand.
...
llvm-svn: 6450
2003-05-30 20:32:01 +00:00
Misha Brukman
71b9de7789
Output the opcode name of the instruction being emitted to cerr.
...
llvm-svn: 6386
2003-05-28 18:29:10 +00:00
Misha Brukman
bf453de096
Cannot output `static' in generated cpp code: results in error. It's already
...
specified as a static member in class definition.
llvm-svn: 6370
2003-05-27 22:29:02 +00:00
Misha Brukman
9deee31239
* Now outputting a static function getBinaryCodeForInstr() (JIT-accessible)
...
* For debugging purposes:
+ output the predefined bit pattern of the instruction
* Fixed inefficiency: only load an operand from MachineInstr once
* Bug fix: did not advance bit index when seeing named bit-fields "annul", "cc"
and "predict"
* Added a catch-all for non-supported instructions at the end of switch stmt.
llvm-svn: 6368
2003-05-27 22:19:58 +00:00
Misha Brukman
a7ec8e1a3e
First cut at the Code Generator using the TableGen methodology.
...
llvm-svn: 6321
2003-05-24 00:15:53 +00:00