Vikram S. Adve
2ccb900add
Add support to print constant arrays and structures.
...
Align data larger than an L1 cache line on L1 cache line boundary.
llvm-svn: 1228
2001-11-09 02:19:29 +00:00
Vikram S. Adve
bc23cf5521
Do the same for float->int that we did for int->float earlier.
...
Also check IsPointerType() in addition to IsIntegral() in several places.
llvm-svn: 1227
2001-11-09 02:18:16 +00:00
Vikram S. Adve
e6642f93d4
Added function UltraSparcInstrInfo::CreateCodeToCopyFloatToInt.
...
llvm-svn: 1226
2001-11-09 02:16:40 +00:00
Vikram S. Adve
f34fa6956d
Added class UltraSparcCacheInfo.
...
llvm-svn: 1225
2001-11-09 02:16:04 +00:00
Vikram S. Adve
367f34f7cc
Bug fix: Need to include the stack offset "bias" in assembly code itself.
...
Added class UltraSparcCacheInfo.
Added function to convert float to int by copying via memory.
llvm-svn: 1224
2001-11-09 02:15:52 +00:00
Vikram S. Adve
313a36f2d3
Use node->getOpCode() instead of node->getMachineInstr()->getOpCode().
...
Much nicer.
llvm-svn: 1223
2001-11-09 02:14:20 +00:00
Vikram S. Adve
e76d3bcb31
Cache parameters for target machine.
...
llvm-svn: 1222
2001-11-09 02:11:25 +00:00
Vikram S. Adve
7977a283e6
Added class MachineCacheInfo.
...
Also added function to convert float to int by copying via memory.
llvm-svn: 1221
2001-11-09 02:11:03 +00:00
Chris Lattner
0043cc1109
Remove false optimization that basically broke everything
...
llvm-svn: 1219
2001-11-09 01:08:10 +00:00
Chris Lattner
54e9f453c9
* Add better caching of data to avoid silly recusions
...
* Only check to see if uses of instructions can be converted for expressions... so we don't look at all of the uses of a constant. This was making the code unnecessarily conservative
llvm-svn: 1218
2001-11-08 22:06:31 +00:00
Chris Lattner
2b48b9694c
Add method decl
...
llvm-svn: 1217
2001-11-08 20:55:05 +00:00
Chris Lattner
2a4e3cfab7
Remove unneeded forward decl
...
llvm-svn: 1216
2001-11-08 20:54:51 +00:00
Chris Lattner
583e95e0b2
Improve raising significantly
...
llvm-svn: 1214
2001-11-08 20:19:56 +00:00
Chris Lattner
cf66422978
Print the method that makes an instruction invalid
...
llvm-svn: 1213
2001-11-08 19:29:51 +00:00
Ruchira Sasanka
dc709780aa
corrected insertCode4Spilled ... bug.
...
llvm-svn: 1212
2001-11-08 19:11:30 +00:00
Vikram S. Adve
b92658976a
Eliminate cleaning step for individual %.bc files created by our gcc.
...
llvm-svn: 1211
2001-11-08 18:42:08 +00:00
Vikram S. Adve
7048762a3e
Took out .clean.bc target.
...
llvm-svn: 1210
2001-11-08 18:25:05 +00:00
Vikram S. Adve
17bfd13a39
Run cleaning pass only when linking multiple files.
...
llvm-svn: 1209
2001-11-08 18:14:20 +00:00
Vikram S. Adve
04a251d785
Add cleaning pass after linking.
...
llvm-svn: 1208
2001-11-08 18:13:17 +00:00
Ruchira Sasanka
19a5165c29
Uncommented LR spill code insertion
...
llvm-svn: 1207
2001-11-08 16:43:25 +00:00
Vikram S. Adve
7543782956
Keep *.s files while we're debugging the native code.
...
Also, fix rule for $(LLCLIBS).
llvm-svn: 1206
2001-11-08 14:31:05 +00:00
Vikram S. Adve
56e61ec517
Bug fix: need to use .reserve for uninitialized data.
...
llvm-svn: 1205
2001-11-08 14:29:57 +00:00
Vikram S. Adve
7a3c4070d6
Add rule for %.clean.bc.
...
llvm-svn: 1204
2001-11-08 05:28:08 +00:00
Vikram S. Adve
3b193679f0
Bug fix: cannot modify Phi operands while iterating over them!
...
llvm-svn: 1203
2001-11-08 05:25:33 +00:00
Vikram S. Adve
e4e91e3835
Add handle to object MachineFrameInfo.
...
llvm-svn: 1202
2001-11-08 05:23:45 +00:00
Vikram S. Adve
e6ecf513a1
Include handle to TargetMachine in each Machine...Info class.
...
llvm-svn: 1201
2001-11-08 05:22:43 +00:00
Vikram S. Adve
06d8c600ea
Add method CreateCodeToCopyIntToFloat.
...
Include handle to TargetMachine in each Machine...Info object.
llvm-svn: 1200
2001-11-08 05:22:15 +00:00
Vikram S. Adve
621b90440b
Major change to how defs are found when adding dependences (they
...
are now found as part of the initial walk of the machine code).
Also memory load/store instructions can be generated for non-memory
LLVM instructions, which wasn't handled before. It is now.
llvm-svn: 1199
2001-11-08 05:20:23 +00:00
Vikram S. Adve
80310bba37
MachineCodeForMethod is now an annotation on class Method.
...
llvm-svn: 1198
2001-11-08 05:18:18 +00:00
Vikram S. Adve
c2f8911114
Add handle to TargetMachine object in all Machine...Info classes.
...
llvm-svn: 1197
2001-11-08 05:15:08 +00:00
Vikram S. Adve
81908213ae
Added support for bitwise logical operators. Use different labels for
...
for these than for boolean logicals to avoid making Burg diverge.
See Burg manual for more information.
llvm-svn: 1196
2001-11-08 05:14:02 +00:00
Vikram S. Adve
03f12f521f
Fixed function getEscapedString to follow the Sparc assembly rules
...
for symbol names! (And renamed it to getValidSymbolName).
Fixed format for float and other constants.
llvm-svn: 1195
2001-11-08 05:12:37 +00:00
Vikram S. Adve
f889a11590
Fix bugs in FITOS/D instruction generation.
...
The space for optional args in the stack frame is now being computed,
so finish the code generation for the variable `alloca'.
Finally, made a major overhaul of how stack frame is managed.
llvm-svn: 1194
2001-11-08 05:04:09 +00:00
Vikram S. Adve
503d3098fa
Added new function UltraSparcInstrInfo::CreateCodeToCopyIntToFloat.
...
Also major overhaul of how stack frame is managed.
llvm-svn: 1193
2001-11-08 04:57:53 +00:00
Vikram S. Adve
7a1524f971
Removed class RegStackOffsets and used class MachineCodeForMethod
...
directly to manage stack frame.
llvm-svn: 1192
2001-11-08 04:56:41 +00:00
Vikram S. Adve
6fcb28924b
Use MachineFrameInfo as base class of UltraSparcFrameInfo, and made
...
a major overhaul of this class and how stack frames are managed.
llvm-svn: 1191
2001-11-08 04:55:13 +00:00
Vikram S. Adve
1ef453c2ff
Machine-independent interface to target's stack frame layout parameters.
...
llvm-svn: 1190
2001-11-08 04:52:27 +00:00
Vikram S. Adve
e316915197
Use different op labels for bitwise logical operations and boolean logical
...
operations in BURG input trees.
llvm-svn: 1189
2001-11-08 04:51:39 +00:00
Vikram S. Adve
70dd1d4ee4
Added a second constructor for and improved class TmpInstruction.
...
llvm-svn: 1188
2001-11-08 04:50:33 +00:00
Vikram S. Adve
bdbb802c2f
Added two minor methods.
...
llvm-svn: 1187
2001-11-08 04:49:52 +00:00
Vikram S. Adve
d9f8598104
Removed class RegStackOffsets and used class MachineCodeForMethod
...
directly to manage stack frame.
llvm-svn: 1186
2001-11-08 04:48:50 +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
07900bde2d
Old file which was moved to include/llvm/Target some time back.
...
llvm-svn: 1184
2001-11-08 04:46:08 +00:00
Vikram S. Adve
b375b89e00
Removed MachineCodeForMethod object and made it an annotation.
...
llvm-svn: 1183
2001-11-08 04:38:58 +00:00
Chris Lattner
c1c54a2a92
Add analysis pass.
...
llvm-svn: 1182
2001-11-07 21:16:29 +00:00
Chris Lattner
83f1528061
Initial checkin of pointer safety checker
...
llvm-svn: 1181
2001-11-07 21:16:12 +00:00
Chris Lattner
b1f672812b
Correct problem that allows indirect function calls
...
llvm-svn: 1179
2001-11-07 20:12:30 +00:00
Chris Lattner
31e9e4d219
* Switch to operation on pointers with PointerTy more consistently
...
* Fix misspeling
* Catch SIGFPE for traps
* info XXX now prints the raw contents of the GenericValue
* Switch to calloc instead of malloc (temporarily I hope) to bandaid Olden benchmarks
* Implement binary And & Or
* Convert expressions like this:
PointerTy SrcPtr = getOperandValue(I->getPtrOperand(), SF).PointerVal;
to:
GenericValue SRC = getOperandValue(I->getPtrOperand(), SF);
PointerTy SrcPtr = SRC.PointerVal;
because the prior way confuses purify.
* Taint the initial values of the value planes
* Handling 'print bb4' in the interpreter without crashing
* Print nicer stack frames with concise return type
* printf doesn't suck nearly as badly as it used to
llvm-svn: 1177
2001-11-07 19:46:27 +00:00
Chris Lattner
75586e2ace
1. -Winline emits spurious warnings that aren't useful right now
...
2. Fix the "rebuild everything if I change one file" problem
llvm-svn: 1176
2001-11-07 14:50:58 +00:00
Chris Lattner
e147d062fa
Killing warnings
...
llvm-svn: 1175
2001-11-07 14:01:59 +00:00
Chris Lattner
3b7199e36c
Add #includes to enable buiding in Release mode
...
llvm-svn: 1174
2001-11-07 13:49:45 +00:00
Chris Lattner
5e030830a3
Squelch warnings about not returning a value
...
llvm-svn: 1173
2001-11-07 13:49:12 +00:00
Vikram S. Adve
b8157d5a29
Roll back all these changes that have broken Makefile.target again.
...
llvm-svn: 1172
2001-11-07 12:29:40 +00:00
Chris Lattner
28e969d689
Okay, so this is a huge hack. Fixme later
...
llvm-svn: 1171
2001-11-07 05:31:53 +00:00
Chris Lattner
eaec4ede57
*Print Stack traces better.
...
* Use the cache writer for all it's problems.
* print arguments to methods in stack traces.
*Print the current stack from for up/down commands.
llvm-svn: 1170
2001-11-07 05:31:27 +00:00
Chris Lattner
1f01726487
* Use cached writer to speed up printing and get symbolic types more consistently
...
* When a segfault or bus error occurs, stop the program, print a stack trace, and dump the user in the debugger mode
llvm-svn: 1169
2001-11-07 04:23:00 +00:00
Chris Lattner
7db7958bd4
Implement CachedWriter class to allow module level printing of various components very quickly
...
llvm-svn: 1168
2001-11-07 04:21:57 +00:00
Chris Lattner
0758abd126
New class to provide high performance writing.
...
llvm-svn: 1167
2001-11-07 04:20:50 +00:00
Chris Lattner
51862ef777
Add %p format to printf, which MUST be used when printing pointer values.
...
llvm-svn: 1166
2001-11-07 02:57:33 +00:00
Chris Lattner
c23094efb4
Implement log and drand48 for TSP bm
...
llvm-svn: 1165
2001-11-06 22:53:25 +00:00
Chris Lattner
74a4698aaa
Minor fixes
...
llvm-svn: 1164
2001-11-06 22:53:17 +00:00
Chris Lattner
68289f0b89
Add notes
...
llvm-svn: 1163
2001-11-06 22:53:11 +00:00
Chris Lattner
5cc318819c
Implement sqrt, implement printf better, simpler.
...
llvm-svn: 1161
2001-11-06 21:52:18 +00:00
Chris Lattner
6c4681ca28
Fix minor bug for shifts
...
llvm-svn: 1160
2001-11-06 21:51:48 +00:00
Chris Lattner
2f2d947f73
Print out the abridged form of the call instruction.
...
llvm-svn: 1159
2001-11-06 21:28:12 +00:00
Chris Lattner
82b7872326
Build .bc from .c better.
...
llvm-svn: 1158
2001-11-06 20:44:15 +00:00
Chris Lattner
21af446166
Don't forget to make the clean version.
...
llvm-svn: 1157
2001-11-06 20:23:50 +00:00
Vikram S. Adve
096a76aa92
Really fix Makefile to compile individual tests and Olden codes.
...
by using a better naming scheme.
llvm-svn: 1156
2001-11-06 17:09:49 +00:00
Vikram S. Adve
2f4b825ca1
Moved *.c files into subdirectory TestSources to avoid overwriting
...
corresponding *.ll files.
llvm-svn: 1155
2001-11-06 17:06:06 +00:00
Ruchira Sasanka
074d52d60d
Fixed bug - added code in pushUnconstrainedIGNodes() to check whether a node
...
is already pushed to stack by a previous call to the same method.
llvm-svn: 1154
2001-11-06 15:25:38 +00:00
Chris Lattner
0c993260fe
Reorder paramters to make the command line more easily modifiable
...
llvm-svn: 1153
2001-11-06 08:34:56 +00:00
Chris Lattner
0136101e37
Fix bugs
...
llvm-svn: 1152
2001-11-06 08:34:29 +00:00
Chris Lattner
4031cdde57
Fix many bugs. Implement PHI transforms & other cycles
...
llvm-svn: 1151
2001-11-06 08:34:17 +00:00
Chris Lattner
9d3292d327
Give me PHI's space back
...
llvm-svn: 1150
2001-11-06 08:33:46 +00:00
Vikram S. Adve
928833ecea
Bug fix: uninitialized variable.
...
llvm-svn: 1147
2001-11-06 05:11:05 +00:00
Vikram S. Adve
f5b4f47cff
Bug fix: Printing AdIBef and AdIAft outside the scope where they
...
were declared, and in some cases when they were unintialized.
llvm-svn: 1146
2001-11-06 05:01:54 +00:00
Chris Lattner
29644b3849
Print PHI nodes with zero operands even if they are illegal
...
llvm-svn: 1145
2001-11-06 01:48:45 +00:00
Chris Lattner
710c3861b5
Fix bug with ADD nodes and malloc promotion
...
llvm-svn: 1144
2001-11-05 21:13:30 +00:00
Chris Lattner
7bb67c8ab8
Fix makefile to compile olden and main benchmarks
...
llvm-svn: 1142
2001-11-05 19:43:24 +00:00
Chris Lattner
7e89a616e6
Don't print spurious linking warnings about methods that are never used.
...
Cleanup ExprTypeConvert a bit.
llvm-svn: 1141
2001-11-05 19:43:10 +00:00
Chris Lattner
0ecba60d26
Use the expression map correctly.
...
llvm-svn: 1140
2001-11-05 18:30:53 +00:00
Chris Lattner
ad480c5a34
Make the olden benchmarks compile again
...
llvm-svn: 1139
2001-11-05 18:25:37 +00:00
Vikram S. Adve
596721384b
Modified graph construction to use one pass to find all defs.
...
Avoids having to handle some special cases that cause complex interactions
with instr. selection.
llvm-svn: 1138
2001-11-05 04:04:23 +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
6cb546970f
Put it back!
...
llvm-svn: 1136
2001-11-05 00:48:27 +00:00
Vikram S. Adve
daa6058a13
Removed by mistake; will add it back immediately.
...
llvm-svn: 1135
2001-11-05 00:48:05 +00:00
Vikram S. Adve
d3be60db35
Make gcc generate assembly files (%.ll) until Chris has a stable
...
version of his gccas. Plus another dumb bug fix (the bug, not the fix).
llvm-svn: 1134
2001-11-05 00:35:56 +00:00
Vikram S. Adve
4d04e00072
Delete rule to disassemble %.bc -- need to make it effective only when
...
%.ll is not a pre-existing file.
llvm-svn: 1133
2001-11-05 00:23:25 +00:00
Vikram S. Adve
491d8dde35
Replaced another HERE.
...
llvm-svn: 1132
2001-11-05 00:22:16 +00:00
Vikram S. Adve
e943db9be9
Put common rules for compiling programs into Makefile.target.
...
llvm-svn: 1130
2001-11-05 00:18:30 +00:00
Chris Lattner
db750679a3
New file for expression tree conversion
...
llvm-svn: 1128
2001-11-04 23:24:20 +00:00
Chris Lattner
3084cb65ff
Refactor code to share stuff
...
llvm-svn: 1127
2001-11-04 23:24:06 +00:00
Chris Lattner
cb3da314d9
* Relax restriction that prevented malloc promotion in certain cases
...
llvm-svn: 1125
2001-11-04 22:11:10 +00:00
Vikram S. Adve
80cf60687d
Generate code for Rem instruction.
...
llvm-svn: 1124
2001-11-04 21:59:14 +00:00
Chris Lattner
dc194d54f9
Fix obscure nasty bug with bytecode writing that could cause the last byte to be dropped.
...
llvm-svn: 1123
2001-11-04 21:32:41 +00:00
Chris Lattner
36c5a79153
* Disable debug output
...
* fix minor bug with taking datasize of unsized array type
* Insert code to support speculative changes later
llvm-svn: 1122
2001-11-04 21:32:11 +00:00
Chris Lattner
40a2d9076b
Convert backward conversion of expression trees into a new more powerful bidirectional approach. Add transforms for more instructions.
...
llvm-svn: 1121
2001-11-04 20:21:12 +00:00
Vikram S. Adve
ea5d1f5db8
Fixed instruction information for RDCCR and WRCCR.
...
Fixed selection to create a TmpInstruction for each integer CC register
(since it is an implicit side-effect, unlike FP CC registers which are
explicit operands).
llvm-svn: 1120
2001-11-04 19:34:49 +00:00
Chris Lattner
33d9cb9903
Minor method rename
...
llvm-svn: 1119
2001-11-04 08:08:34 +00:00
Chris Lattner
f00563d39d
Add transformations for Load and GetElementPtr. Fix broken transform with shr.
...
llvm-svn: 1118
2001-11-04 07:42:17 +00:00
Chris Lattner
eb7b620d58
Fix cast instructions that end up in bad places in GCC output
...
llvm-svn: 1117
2001-11-04 07:40:51 +00:00
Ruchira Sasanka
471babe2d2
Added an assertion since it seems like AdjList returns an errornous size in method
...
IGNode::pushOnStack().
llvm-svn: 1116
2001-11-03 22:01:09 +00:00
Chris Lattner
033324fc0c
Avoid making a broken transformation!
...
llvm-svn: 1115
2001-11-03 21:30:22 +00:00
Chris Lattner
ec83fc091e
Add new cleanup pass:
...
// 1. PHI nodes with multiple entries for the same predecessor. GCC sometimes
// generates code that looks like this:
//
// bb7: br bool %cond1004, label %bb8, label %bb8
// bb8: %reg119 = phi uint [ 0, %bb7 ], [ 1, %bb7 ]
//
// which is completely illegal LLVM code. To compensate for this, we insert
// an extra basic block, and convert the code to look like this:
//
// bb7: br bool %cond1004, label %bbX, label %bb8
// bbX: br label bb8
// bb8: %reg119 = phi uint [ 0, %bbX ], [ 1, %bb7 ]
//
llvm-svn: 1114
2001-11-03 21:08:59 +00:00
Chris Lattner
34f8595c0b
Add a helper function to PHI node
...
llvm-svn: 1113
2001-11-03 21:08:00 +00:00
Ruchira Sasanka
51fc1c2d72
Added support for correct spilling of %ccr
...
llvm-svn: 1112
2001-11-03 20:41:22 +00:00
Ruchira Sasanka
9d8950d240
Added code to support correct saving of %ccr across calls
...
llvm-svn: 1111
2001-11-03 19:59:59 +00:00
Chris Lattner
784c623efb
* Export method to merge identically named methods
...
* Add code to fix PHI nodes that are missing arguments. These PHI nodes can
be generated by GCC if there is an uninitialized variable flowing into a merge
point. For example:
int foo(int y) {
int X;
if (y) X = 1;
return X;
}
llvm-svn: 1110
2001-11-03 19:51:56 +00:00
Chris Lattner
cf5befef63
Expose method to merge identically named methods
...
llvm-svn: 1109
2001-11-03 19:49:54 +00:00
Ruchira Sasanka
ca632ed71a
Arranged stack frame - needs furhter organization
...
llvm-svn: 1108
2001-11-03 17:14:44 +00:00
Ruchira Sasanka
97b93aea81
Moved InsertCallerSaveInstr to the SparcRegInfo.cpp and made machine independent
...
llvm-svn: 1107
2001-11-03 17:14:13 +00:00
Ruchira Sasanka
b7a397253f
Arranged stack frame - needs furhter organization
...
Moved InsertCallerSaveInstr to the SparcRegInfo.cpp
llvm-svn: 1106
2001-11-03 17:13:27 +00:00
Ruchira Sasanka
629a15247a
Commented out code so that copies are inserted for all phi args
...
CahedCopyMap was disabled to insert phi elimination code for all phi args
llvm-svn: 1105
2001-11-03 17:09:59 +00:00
Chris Lattner
d7c742f46a
Be lenient on types so that programs that are not very typesafe will work
...
llvm-svn: 1104
2001-11-03 10:15:32 +00:00
Chris Lattner
629d7a7849
Changes to compile the TSP benchmark successfully. Favor warning instead of assertion failures.
...
llvm-svn: 1103
2001-11-03 10:04:22 +00:00
Chris Lattner
1f3947c1d1
Add code to link method together with the same name if one is vararg and the other isn't.
...
This resolves definitions like this:
%list * "foo"(...)
%list * "foo"(int)
together which can often occur because C programmers don't put prototypes in like they should. GRR
llvm-svn: 1102
2001-11-03 09:19:00 +00:00
Chris Lattner
3855f2c806
Don't forget to link type names together too. Fix for Olden/mst benchmark
...
llvm-svn: 1094
2001-11-03 05:18:24 +00:00
Chris Lattner
34ec31bb74
Remove debugging info
...
llvm-svn: 1093
2001-11-03 03:31:39 +00:00
Chris Lattner
4f1ca018aa
Fix major bugs in type resolution
...
llvm-svn: 1092
2001-11-03 03:27:53 +00:00
Chris Lattner
1e60d6b762
Add extra code for debugging linker problems
...
llvm-svn: 1091
2001-11-03 03:27:29 +00:00
Chris Lattner
c7724169bf
Fix the linker. This bug was not fun to track down. grr
...
llvm-svn: 1090
2001-11-03 03:26:47 +00:00
Chris Lattner
866cbddec8
Dramatically simplify recursive type processing. Fixed a few bugs, a few still remain :(
...
Why does this stuff have to come up NOW?
llvm-svn: 1089
2001-11-02 07:51:31 +00:00
Chris Lattner
f29b231c77
Improve some debugging code
...
llvm-svn: 1088
2001-11-02 07:46:26 +00:00
Chris Lattner
50f68acb37
Support floating point numbers in expodential form so that small numbers don't get truncated, which broke the health benchmark
...
llvm-svn: 1087
2001-11-01 22:06:08 +00:00
Chris Lattner
e80af939da
Print floating point numbers in expodential form so that small numbers don't get truncated, which broke the health benchmark
...
llvm-svn: 1086
2001-11-01 22:06:00 +00:00
Chris Lattner
9bc6b190cc
* Add comments for peepholes
...
* Implement new peephole:
// Peephole optimize the following instructions:
// %t1 = cast {<...>} * %StructPtr to <ty> *
//
// Into: %t2 = getelementptr {<...>} * %StructPtr, <0, 0, 0, ...>
// %t1 = cast <eltype> * %t1 to <ty> *
This peephole eliminated 9 evil casts in the health benchmark, and
completely turned the addList method around. :)
llvm-svn: 1085
2001-11-01 17:05:27 +00:00
Chris Lattner
71c842cddf
Add DCE as integral part of the level raising to avoid processing instructions that are dead
...
llvm-svn: 1084
2001-11-01 07:00:51 +00:00
Chris Lattner
7567f6c15f
Expose the low level DCE mechanism to external users
...
Refactor code to support it
llvm-svn: 1083
2001-11-01 07:00:27 +00:00
Chris Lattner
63ac2b335a
Expose the low level DCE mechanism to external users
...
llvm-svn: 1082
2001-11-01 07:00:21 +00:00
Chris Lattner
f652674162
Implement new simpler constructors for if you don't have a index list
...
llvm-svn: 1081
2001-11-01 05:58:42 +00:00
Chris Lattner
9a13ececd8
* Implement expression type conversion for constant values
...
* Fix a problem setting a name on a constant value that died because no symbol table was passed in
* Add some comments describing the passes
* Implement a new peephole:
// Peephole optimize the following instructions:
// %t = cast <T1>* %P to <T2> * ;; If T1 is losslessly convertable to T2
// store <T2> %V, <T2>* %t
//
// Into:
// %t = cast <T2> %V to <T1>
// store <T1> %t2, <T1>* %P
llvm-svn: 1080
2001-11-01 05:57:59 +00:00
Chris Lattner
04648a4cc6
Simplify DCE code a lot
...
llvm-svn: 1079
2001-11-01 05:55:29 +00:00
Chris Lattner
977f0044fc
Implement constant propogation of null pointer values.
...
llvm-svn: 1078
2001-11-01 05:55:13 +00:00
Chris Lattner
3003edc9f1
Add simpler to use ctors. Add getType() overload to specialize getelementptr's type
...
llvm-svn: 1077
2001-11-01 05:54:28 +00:00
Chris Lattner
3e8ef98515
Add new isNullValue method
...
llvm-svn: 1076
2001-11-01 05:53:56 +00:00
Chris Lattner
1267be2319
* Convert getelementptr/store pairs into a single store
...
* Convert getelementptr/load pairs into a single load
llvm-svn: 1075
2001-11-01 03:12:34 +00:00
Chris Lattner
025f9fcf80
Initial checkin of level raising code, after move and cleanup and expands from the opt directory
...
llvm-svn: 1074
2001-11-01 02:42:08 +00:00
Chris Lattner
8ac538db47
Initial checkin of level raising code
...
llvm-svn: 1073
2001-11-01 02:41:52 +00:00
Chris Lattner
e326957333
Move the Raise xform from opt to transforms
...
llvm-svn: 1072
2001-11-01 02:41:09 +00:00
Chris Lattner
246f157af4
Propogate name to the malloc itself instead of to the cast
...
llvm-svn: 1071
2001-11-01 02:40:36 +00:00
Chris Lattner
d307537327
Move level change xfor into the transforms directory
...
llvm-svn: 1070
2001-11-01 02:39:49 +00:00
Chris Lattner
d67f2a4493
Add some useful accessors
...
llvm-svn: 1069
2001-11-01 02:39:36 +00:00
Chris Lattner
9fb50fe167
crunch the output of GCC a bit to make it nicer
...
llvm-svn: 1068
2001-10-31 06:36:48 +00:00
Chris Lattner
55c72cb47a
Start testing the new cleangcc pass
...
llvm-svn: 1067
2001-10-31 06:36:34 +00:00
Chris Lattner
7e6a0d8c17
Use the correct prototype for malloc and free
...
llvm-svn: 1066
2001-10-31 06:36:23 +00:00
Chris Lattner
20726ed31b
Implement code to convert %malloc and %free FUNCTION CALLS into the instruction equivalent
...
llvm-svn: 1065
2001-10-31 06:35:59 +00:00
Chris Lattner
9db8b765cd
Implemented constant propogation of cast instructions
...
llvm-svn: 1064
2001-10-31 05:07:57 +00:00
Chris Lattner
ae6de303fc
Fix dumb copy and paste typos
...
llvm-svn: 1063
2001-10-31 04:33:33 +00:00
Chris Lattner
34b9518c88
Initial version of GCC cleanup pass: just removes extraneous global symbol table entries for types
...
llvm-svn: 1062
2001-10-31 04:33:19 +00:00
Chris Lattner
b3f4d1bc73
New GCC cleanup pass interface
...
llvm-svn: 1061
2001-10-31 04:32:53 +00:00
Chris Lattner
7a2d677332
Add hook for GCC cleanup pass
...
llvm-svn: 1060
2001-10-31 04:29:44 +00:00
Chris Lattner
129aac7468
Build new gccas tool
...
llvm-svn: 1059
2001-10-31 04:29:30 +00:00
Chris Lattner
1a30617664
Initial checkin of GCCAS
...
llvm-svn: 1058
2001-10-31 04:28:11 +00:00
Chris Lattner
49d9307ca6
Initial checkin of heapsort benchmark
...
llvm-svn: 1057
2001-10-31 02:28:25 +00:00
Chris Lattner
2a2b531294
Fix bug when inlining a method that refers to a global variable
...
llvm-svn: 1056
2001-10-31 02:27:26 +00:00
Chris Lattner
0d5c295536
Implement memset memcpy, calloc
...
llvm-svn: 1055
2001-10-30 22:37:01 +00:00
Chris Lattner
7551ec25e7
Initial checkin of ary3 "benchmark" from prog lang shootout
...
llvm-svn: 1051
2001-10-30 22:17:57 +00:00
Chris Lattner
487b1b8cc1
Implement xor operator
...
llvm-svn: 1050
2001-10-30 20:54:36 +00:00
Chris Lattner
3f741a560a
Initialize map for purify
...
llvm-svn: 1049
2001-10-30 20:28:46 +00:00
Chris Lattner
8bd5c77731
callExternalMethod now returns the return value of the function
...
llvm-svn: 1048
2001-10-30 20:28:23 +00:00
Chris Lattner
7fd51b54e5
Implement a gross function name map that must be used when linking statically
...
This is for use with purify
llvm-svn: 1047
2001-10-30 20:28:00 +00:00
Chris Lattner
5946b1150d
* Add some assertions for checking internal error conditions
...
* Implement the 'rem' instruction
* Fix getelementptr to work right
* Copy the return result of an external function call into the receiving value
* Convert stuff to new style casts
llvm-svn: 1046
2001-10-30 20:27:31 +00:00
Chris Lattner
b20b290c5e
Add easy way to enable purify support
...
llvm-svn: 1045
2001-10-30 20:24:08 +00:00
Chris Lattner
c85ee99b42
Don't fail to load runtime if running LLI from the current directory
...
llvm-svn: 1044
2001-10-30 16:40:37 +00:00
Chris Lattner
ff2a07f4df
Initialize isRecursive. Found by Purify
...
llvm-svn: 1043
2001-10-30 16:39:16 +00:00
Chris Lattner
92fcd608cf
Fix ordering problem. Found by purify. :)
...
llvm-svn: 1042
2001-10-30 16:38:49 +00:00
Chris Lattner
cdb5936f45
Add testcase for missed SCCP optimization
...
llvm-svn: 1040
2001-10-30 03:22:59 +00:00
Chris Lattner
62d1fb6777
Print out a label if we step into the first instruction of a basic block
...
llvm-svn: 1038
2001-10-29 20:44:34 +00:00
Chris Lattner
490d2a8461
* Fix pow wrapper to actually work
...
* Implement rudimentary printf support for lli
llvm-svn: 1037
2001-10-29 20:27:45 +00:00
Chris Lattner
05fbeedde8
Implement getelementptr instruction as well as the load and store forms
...
that incorporate gep
llvm-svn: 1036
2001-10-29 19:32:19 +00:00
Chris Lattner
eec6046adf
I screwed up the macros, so of course strtol didn't work. *sigh*
...
llvm-svn: 1035
2001-10-29 17:47:10 +00:00
Chris Lattner
cba9036e34
Fix broken assertion. Didn't allow for pointer case
...
llvm-svn: 1034
2001-10-29 17:27:38 +00:00
Chris Lattner
3e95c716aa
Pull method symbols over when linking. Otherwise the result of the link will appear stripped
...
llvm-svn: 1033
2001-10-29 16:55:41 +00:00
Chris Lattner
72f866eda3
Fix blatent bugs in checkin
...
llvm-svn: 1032
2001-10-29 16:40:32 +00:00
Chris Lattner
b86620e9b1
Expose the WriteTypeSymbolic function from the library. Refactor code to make
...
this function explicit. Cause WriteAsOperand to use symbolic types as available.
llvm-svn: 1031
2001-10-29 16:37:48 +00:00
Chris Lattner
790409a07a
Expose some more printing functionality from the assembly writer library
...
llvm-svn: 1030
2001-10-29 16:36:49 +00:00
Chris Lattner
7bfee414aa
Be careful to output symbolic type name if possible for a type. This makes
...
debugging the Olden/health benchmark actually possible.
llvm-svn: 1029
2001-10-29 16:05:51 +00:00
Chris Lattner
13babb6805
Remember to print out the next instruction if stepping over an external method call
...
llvm-svn: 1028
2001-10-29 16:05:19 +00:00
Chris Lattner
689049e1cd
Fix problem next'ing over an external method
...
llvm-svn: 1027
2001-10-29 14:08:33 +00:00
Chris Lattner
c6503e8a2f
Oops, accidentally broke reading from stdin when doing command line arguments
...
llvm-svn: 1026
2001-10-29 14:00:48 +00:00
Chris Lattner
1711dcbd29
Test bitwise operations
...
llvm-svn: 1025
2001-10-29 13:56:42 +00:00
Chris Lattner
41a8289eb8
Check in to use moved stringizing code
...
llvm-svn: 1024
2001-10-29 13:39:38 +00:00
Chris Lattner
e10ec076e9
Systems headers use <> not ""
...
llvm-svn: 1023
2001-10-29 13:29:50 +00:00
Chris Lattner
8c857b86fd
Checkin of C string stuff. Fix several bugs, including most escape codes being
...
printed as '\\n' instead of their correct code. Also print things in octal instead of hex.
llvm-svn: 1022
2001-10-29 13:28:00 +00:00
Chris Lattner
239a1bdfe1
Remove C string capability from VMCore library. Move to Support
...
llvm-svn: 1021
2001-10-29 13:27:09 +00:00
Chris Lattner
3bb79584d5
Include functionality to get a string array constant as a string
...
llvm-svn: 1020
2001-10-29 13:24:31 +00:00
Chris Lattner
0936089b67
Remove useCSyntax flag
...
llvm-svn: 1019
2001-10-29 13:22:49 +00:00
Chris Lattner
108d8d46b9
Initial checkin of name mangling code moved from linker
...
llvm-svn: 1018
2001-10-28 23:44:03 +00:00
Chris Lattner
84085ac517
Initial checkin of name mangling code. Moved from Linker.h
...
llvm-svn: 1017
2001-10-28 23:31:10 +00:00
Vikram S. Adve
66aea7a58c
Make newlines be newlines! This should now work in both lli and native code.
...
llvm-svn: 1016
2001-10-28 22:44:02 +00:00
Chris Lattner
fc361b1d55
Remove non linking related stuff
...
llvm-svn: 1015
2001-10-28 22:43:06 +00:00
Chris Lattner
328c9afafe
Remove unneccesary function prototypes
...
llvm-svn: 1014
2001-10-28 22:40:59 +00:00
Chris Lattner
9cd1451b89
Fix some illegal uses of the ## operator
...
llvm-svn: 1013
2001-10-28 22:38:22 +00:00
Vikram S. Adve
5ff15721c9
Minor fix I omitted to check in.
...
llvm-svn: 1012
2001-10-28 22:19:06 +00:00
Vikram S. Adve
eada6b128a
Support printing control characters in standard C/assembly style,
...
if you specify useCSyntax = true. The old style is still the default.
llvm-svn: 1011
2001-10-28 21:48:05 +00:00
Vikram S. Adve
33ec4a3c23
Record constants that need to be emitted in the assembly code.
...
llvm-svn: 1010
2001-10-28 21:46:23 +00:00
Vikram S. Adve
979800ede8
Allow combinations of True/Anti/Output flags for each edge to
...
support, e.g., dependences on Call instructions.
llvm-svn: 1009
2001-10-28 21:45:02 +00:00
Vikram S. Adve
df6913549a
Add edges between call instructions and (a) load/store instructions, and
...
(b) any instructions that use or set CC registers. Whether or not the
latter are needed really should be machine-dependent.
llvm-svn: 1008
2001-10-28 21:43:33 +00:00
Vikram S. Adve
2f72cdd756
Generate SETX for 64-bit integers!
...
llvm-svn: 1007
2001-10-28 21:41:46 +00:00
Vikram S. Adve
a5619eb835
Add SETX instruction for 64-bit constants.
...
Add M_CC_FLAG for many instructions that use int or fp CC registers.
llvm-svn: 1006
2001-10-28 21:41:01 +00:00