Chris Lattner
3462ae3ad7
Rename ConstPoolVal -> Constant
...
Rename ConstPool* -> Constant*
Rename ConstPoolVals.h -> ConstantVals.h
llvm-svn: 1407
2001-12-03 22:26:30 +00:00
Chris Lattner
fb5ae02e1a
Split the PHINode class out from the iOther.h file into the iPHINode.h file
...
llvm-svn: 1405
2001-12-03 18:02:31 +00:00
Chris Lattner
5de2204fe8
Create a new #include "Support/..." directory structure to move things
...
from "llvm/Support/..." that are not llvm dependant.
Move files and fix #includes
llvm-svn: 1400
2001-11-27 00:03:19 +00:00
Chris Lattner
1416a2992e
Remove debugging output
...
llvm-svn: 1383
2001-11-26 19:14:16 +00:00
Chris Lattner
4219baafb5
Support internal linkage
...
llvm-svn: 1382
2001-11-26 19:14:03 +00:00
Chris Lattner
bd422e6686
Implement DCE of global values
...
llvm-svn: 1360
2001-11-26 18:42:17 +00:00
Chris Lattner
2cc6d418fa
Support selectable structure transformations
...
llvm-svn: 1342
2001-11-26 16:59:10 +00:00
Chris Lattner
f80013a917
Support mutation of array indexing
...
llvm-svn: 1341
2001-11-26 16:58:33 +00:00
Chris Lattner
02c43c8609
-cleangcc pass now remove type names that are never referenced and type names for pointers to primitive types.
...
llvm-svn: 1312
2001-11-15 04:34:46 +00:00
Chris Lattner
abf40ba6e8
Better heuristics for handling arrays
...
llvm-svn: 1296
2001-11-14 11:02:49 +00:00
Chris Lattner
1643e8ec7b
Fix minor bug
...
llvm-svn: 1273
2001-11-12 20:13:04 +00:00
Chris Lattner
49ec72411e
Initail checking of structure swapper
...
llvm-svn: 1248
2001-11-10 07:28:25 +00:00
Chris Lattner
5dada09565
Initial checkin of structure mutator
...
llvm-svn: 1246
2001-11-10 07:26:31 +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
3084cb65ff
Refactor code to share stuff
...
llvm-svn: 1127
2001-11-04 23:24:06 +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
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
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
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
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
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
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
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
4816d63844
Initial checkin
...
llvm-svn: 897
2001-10-18 20:05:37 +00:00
Chris Lattner
5398a6eb6c
Convert optimizations to the pass infrastructure
...
llvm-svn: 873
2001-10-18 01:32:34 +00:00
Chris Lattner
a972919f92
Minor cleanup
...
llvm-svn: 812
2001-10-14 23:29:30 +00:00
Chris Lattner
cfc2f446a6
Support indirect calls
...
llvm-svn: 764
2001-10-13 06:52:31 +00:00
Chris Lattner
da55810666
Commit more code over to new cast style
...
llvm-svn: 697
2001-10-02 03:41:24 +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
Chris Lattner
e57fc205f4
Constant pool is dead
...
llvm-svn: 455
2001-09-07 16:42:51 +00:00
Chris Lattner
3e37ec7c0a
Support external methods
...
llvm-svn: 200
2001-07-15 21:43:45 +00:00
Chris Lattner
b1ca9cbceb
Broad superficial changes:
...
* Renamed getOpcode to getOpcodeName
* Changed getOpcodeName to return a const char * instead of string
* Added a getOpcode method to replace getInstType
* Changed code to use getOpcode instead of getInstType
llvm-svn: 152
2001-07-07 19:24:15 +00:00
Chris Lattner
a073acb22d
Changed the fundemental architecture of Operands for Instructions. Now
...
Operands are maintained as a vector<Use> in the User class, and operator
iterators are provided as before. Getting an operand no longer requires
a virtual function call.
WARNING: getOperand(x) where x >= getNumOperands() will now assert instead
of returning null!
llvm-svn: 149
2001-07-07 08:36:50 +00:00
Chris Lattner
d42d492734
Optimizations got their own header files
...
Optimizations now live in the 'opt' namespace
include/llvm/Opt was renamed include/llvm/Optimizations
llvm-svn: 113
2001-06-30 04:36:40 +00:00
Chris Lattner
4cee8d8ffb
Miscellaneous cleanups:
...
* Convert post to pre-increment for for loops
* Use generic programming more
* Use new Value::cast* instructions
* Use new Module, Method, & BasicBlock forwarding methods
* Use new facilities in STLExtras.h
* Use new Instruction::isPHINode() method
llvm-svn: 96
2001-06-27 23:41:11 +00:00
Chris Lattner
874ddadf72
Updates to support
...
* Changes in PHI node structure
llvm-svn: 25
2001-06-11 15:04:40 +00:00
Chris Lattner
2f7c963559
Initial revision
...
llvm-svn: 2
2001-06-06 20:29:01 +00:00