Chris Lattner
a9e1535afc
* Add debug support for PATypeHolder
...
* PATypeHolder is now not a template
llvm-svn: 2108
2002-04-04 19:26:02 +00:00
Chris Lattner
1be6266721
Make the release build compile
...
llvm-svn: 2107
2002-04-04 19:24:48 +00:00
Chris Lattner
a8bef43fbb
PATypeHolder is now not a template
...
llvm-svn: 2106
2002-04-04 19:24:34 +00:00
Chris Lattner
53659e8676
Add debug support
...
llvm-svn: 2105
2002-04-04 19:24:11 +00:00
Chris Lattner
30752bd910
* Make PATypeHolder not take a type argument
...
* Eliminate by inlining the old newTH, newTH, and TypeDone functions
* OPAQUE is now just a token that gets returned by the lexer, not a type
Parser now creates type, not lexer
llvm-svn: 2104
2002-04-04 19:23:55 +00:00
Chris Lattner
f269b9d236
Lexer doesn't create typehandle gross stuff now, parser does.
...
llvm-svn: 2103
2002-04-04 19:22:17 +00:00
Chris Lattner
9ba54b2f31
Call nodes are never equivalent
...
Shadow nodes are never critical.
llvm-svn: 2102
2002-04-04 19:21:51 +00:00
Chris Lattner
d6c8dd1473
Add hack to get timing of analysis
...
llvm-svn: 2101
2002-04-04 19:21:27 +00:00
Chris Lattner
d7b6c331ea
* Eliminate commented out code
...
* Do not demand a shadow node when resolving
* Raise arbitrary inline limit
llvm-svn: 2100
2002-04-04 19:21:06 +00:00
Chris Lattner
0e9fa3a509
Deparameterize PATypeHolder
...
llvm-svn: 2099
2002-04-04 19:20:18 +00:00
Chris Lattner
16381517e3
Add method to get # nodes in the graph
...
llvm-svn: 2098
2002-04-04 19:20:00 +00:00
Chris Lattner
08a6e84038
Make the release build work
...
llvm-svn: 2097
2002-04-04 19:19:27 +00:00
Chris Lattner
e92d7b4289
Fix the release build
...
llvm-svn: 2096
2002-04-04 19:18:17 +00:00
Chris Lattner
35ef4a1431
* Add dump() virtual function to AbstractType user to help track down bugs
...
* PATypeHolder is now a nontemplated class, because it was (almost) only
ever instantiated with 'Type' as the parameter.
llvm-svn: 2095
2002-04-04 19:18:00 +00:00
Chris Lattner
4f47bb8ae6
Support resolving function arguments/return values to pointers that index
...
into other objects.
llvm-svn: 2094
2002-04-01 22:20:48 +00:00
Vikram S. Adve
313ca14124
Case numbers were not updated when Sparc.burg.in was changed
...
to add separate label for bitwise NOT operator.
llvm-svn: 2091
2002-04-01 20:28:48 +00:00
Chris Lattner
8c61bc0859
Move the PromoteMemoryToRegister pass to be run _after_ the raise pointer
...
references pass, so it is given the chance to do some good!
llvm-svn: 2089
2002-04-01 19:45:11 +00:00
Chris Lattner
8cb8e4608c
Add a new replaceWith method useful for replacing instructions
...
llvm-svn: 2088
2002-04-01 17:52:16 +00:00
Chris Lattner
1ec764b309
Allow scalars that point to multiple nodes when building the scalar map.
...
llvm-svn: 2087
2002-04-01 01:26:53 +00:00
Chris Lattner
cf09a2a2cd
Add extra case here to avoid getting spurious output
...
llvm-svn: 2086
2002-04-01 00:45:33 +00:00
Chris Lattner
7203e9f05a
Avoid incorrectly adding null values to the scalar map!
...
llvm-svn: 2085
2002-04-01 00:45:09 +00:00
Chris Lattner
f224b6b511
Critical shadow nodes no do not know their parent explictly.
...
llvm-svn: 2084
2002-04-01 00:15:30 +00:00
Chris Lattner
b4648bb38f
Minor cleanups (use dyn_cast instead of testing manually)
...
Shadow nodes now don't explicitly know their parent.
llvm-svn: 2083
2002-04-01 00:14:41 +00:00
Chris Lattner
6b06aa557e
Allow merging of identical call nodes. Make the shadow node pointed to
...
by the call node noncritical before the call is destroyed.
llvm-svn: 2082
2002-04-01 00:13:56 +00:00
Chris Lattner
a7b3b50381
Increase limit for perimeter
...
llvm-svn: 2081
2002-04-01 00:12:58 +00:00
Chris Lattner
71fc90439b
Shadow nodes don't need to know their explicit parent, they just need to
...
know what type to be.
llvm-svn: 2080
2002-04-01 00:12:36 +00:00
Chris Lattner
d63afb418e
Unify the destruction code used for node pairs vs normal nodes. This was
...
causing a problem before because global values with incoming edges didn't
copy the incoming edges to the node they were being merged from, causing
the poolalloc pass to die.
llvm-svn: 2079
2002-03-31 19:57:44 +00:00
Vikram S. Adve
4973f73ad1
1. Fix a leftover bug in generating memory instructions.
...
2. Fix type used for TmpInstruction holding the return address.
llvm-svn: 2075
2002-03-31 19:07:35 +00:00
Vikram S. Adve
02662bd390
Added function getCallInstIndirectAddrVal() to set call interference
...
for that value.
llvm-svn: 2074
2002-03-31 19:04:50 +00:00
Vikram S. Adve
07c874547b
Minor cleanup in printing constants. I think this included a bug
...
fix related to putting a read-write variable in a read-only section,
but I'm not sure now.
llvm-svn: 2073
2002-03-31 19:03:58 +00:00
Vikram S. Adve
429621cad0
Add method getCallInstIndirectAddrVal() to add call interference
...
for this value.
llvm-svn: 2072
2002-03-31 18:58:49 +00:00
Vikram S. Adve
c533f04176
Add method clearCallInterference().
...
llvm-svn: 2071
2002-03-31 18:58:14 +00:00
Vikram S. Adve
f434a9ed5f
Include temp. values when computing max. size of stack frame!
...
llvm-svn: 2070
2002-03-31 18:57:49 +00:00
Vikram S. Adve
5bf8890305
Fix a bug in previous bug fix.
...
llvm-svn: 2069
2002-03-31 18:56:51 +00:00
Vikram S. Adve
aa2373d2ed
Bug fix: address used by indirect call instruction should also
...
be marked as having a Call Interference, even though it may not
be live after the call.
llvm-svn: 2068
2002-03-31 18:54:37 +00:00
Chris Lattner
0dc225cbf6
Add debug output
...
llvm-svn: 2066
2002-03-31 07:17:46 +00:00
Chris Lattner
041468ff3f
* Fix nondeleted type handle which could cause type pool corruption (and
...
a memory leak)
* Fix memory leak of Argument nodes on function prototypes
llvm-svn: 2065
2002-03-31 07:16:49 +00:00
Chris Lattner
d45f4df2ae
* Move the isEquivalentTo implementations here. They can probably be put
...
someplace nicer in the file though.
* Add new dump method for debugging
llvm-svn: 2064
2002-03-31 07:16:08 +00:00
Chris Lattner
49c3ea8c1e
Print out the instruction instead of just the address!
...
llvm-svn: 2063
2002-03-31 07:15:20 +00:00
Chris Lattner
ed9bfd95a9
* Move isEquivalentTo implementations to NodeImpl
...
* Implement a new form of node folding to catch cases missed in Addtree
* Add removeIndistinguishableNodePairs to merge calls (todo) and globals
llvm-svn: 2062
2002-03-31 07:14:52 +00:00
Chris Lattner
a2cdaba6ed
* Convert CallMap to be a vector, because the keys can change, and the map
...
doesn't resort!
* Be more generous with the cached matches that we allow now.
* Recursive calls should all work now!
llvm-svn: 2061
2002-03-31 07:13:27 +00:00
Chris Lattner
aeef4cbb21
* Allow access to DSNode iterator as DSNode::iterator/begin/end
...
* Add debugging "dump" method to DSNode
* Fix bugs in DSNode iterator
llvm-svn: 2060
2002-03-31 07:11:20 +00:00
Vikram S. Adve
bd4e68c280
Fix CreateUIntSetInstruction() to handle sign extensions correctly.
...
llvm-svn: 2059
2002-03-31 00:13:12 +00:00
Chris Lattner
847b6e2ee7
* Catch and ignore (for now) return instructions in tranformed functions
...
* Add more debugging output
* Fix problems refering to wrong versions of various graphs
* Build the pool descriptor map!
* Clear the nodemapping map after building pool descriptor to avoid assert
* Transform the NEw function body, not the old one...
* Matrix.ll now works!
llvm-svn: 2058
2002-03-30 20:53:14 +00:00
Chris Lattner
a84b29784e
Initial checkin of file:
...
Define an iterator to operate over data structure outgoing links and
graph implementation so generic graph functions can be used.
llvm-svn: 2057
2002-03-30 09:13:23 +00:00
Chris Lattner
ca9f4d39f3
* Clean up data structures [AllocDSNode -> DSNode]
...
* TransformFunctionInfo now has call field form field mapping. May be
removed in the future.
* Moved the computation of "Scalars" into transformFunctionBody so
transformFunction didn't have to recompute it.
* Implement the node mapping calculation in preparation to calculate
PoolDescriptors to pass to transformFunctionBody
* Print out the node mapping [it looks right!]
* Other minor changes
llvm-svn: 2056
2002-03-30 09:12:35 +00:00
Chris Lattner
79f148ddbc
Add accessors and a method to get all the outgoing links for ALL nodes
...
llvm-svn: 2055
2002-03-30 09:07:51 +00:00
Chris Lattner
104dd00d74
Add an accessor
...
llvm-svn: 2054
2002-03-30 04:02:41 +00:00
Chris Lattner
396d5d7c62
Maintain enough information so that the pools for all of the nodes of
...
the graph can be passed around.
llvm-svn: 2053
2002-03-30 04:02:31 +00:00
Chris Lattner
f32d65d5ca
Implement the first batch of transformations to the methods. So far it:
...
* Converts malloc instructions to poolalloc
* Converts free instructions to poolfree
* Convert calls to call the new cloned hacked up versions
Note that this does not modify hacked up stuff yet, just the top level
function
llvm-svn: 2052
2002-03-29 21:25:19 +00:00