1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 11:02:59 +02:00
Commit Graph

157 Commits

Author SHA1 Message Date
Chris Lattner
866bf47eff Print out what the root of the call graph is.
llvm-svn: 2223
2002-04-10 20:31:44 +00:00
Chris Lattner
5e12c7caf5 Move FunctionArgument out of iOther.h into Argument.h and rename class to
be 'Argument' instead of FunctionArgument.

llvm-svn: 2216
2002-04-09 19:48:49 +00:00
Chris Lattner
b2038512b2 Add explicit #includes of Function.h to make up for the removed #include
in iOther.h

llvm-svn: 2209
2002-04-09 19:08:28 +00:00
Chris Lattner
7ae20d642d Add #includes to make up for #includes pruned out of header files.
llvm-svn: 2207
2002-04-09 18:37:46 +00:00
Chris Lattner
0a8a112014 Don't leak all of the Loop objects created...
llvm-svn: 2196
2002-04-09 05:43:19 +00:00
Chris Lattner
5f86cf1a1c * General cleanups
* In calcLiveVarSetsForBB, do not leak a ValueSet every time the function
  is called!

llvm-svn: 2189
2002-04-09 05:14:14 +00:00
Chris Lattner
c8166cec07 s/Method/Function
llvm-svn: 2180
2002-04-08 22:03:57 +00:00
Chris Lattner
56e96eb88f isLabelType is obsolete
llvm-svn: 2175
2002-04-08 21:59:08 +00:00
Chris Lattner
0962b63d7c Play around with #includes
llvm-svn: 2174
2002-04-08 21:58:53 +00:00
Chris Lattner
49808e463c Add #includes that were pruned from already #included files
llvm-svn: 2173
2002-04-08 21:56:50 +00:00
Chris Lattner
44f14449c4 ConstantHandling moved into VMCore library
llvm-svn: 2165
2002-04-08 20:18:09 +00:00
Chris Lattner
bc15ae64dd Change references to the Method class to be references to the Function
class.  The Method class is obsolete (renamed) and all references to it
are being converted over to Function.

llvm-svn: 2144
2002-04-07 20:49:59 +00:00
Chris Lattner
5cbfde5744 Call nodes are never equivalent
Shadow nodes are never critical.

llvm-svn: 2102
2002-04-04 19:21:51 +00:00
Chris Lattner
d4c7ce8d78 Add hack to get timing of analysis
llvm-svn: 2101
2002-04-04 19:21:27 +00:00
Chris Lattner
3b604e846a * 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
19689af3bb Support resolving function arguments/return values to pointers that index
into other objects.

llvm-svn: 2094
2002-04-01 22:20:48 +00:00
Chris Lattner
62756e4208 Avoid incorrectly adding null values to the scalar map!
llvm-svn: 2085
2002-04-01 00:45:09 +00:00
Chris Lattner
e66e651b68 Critical shadow nodes no do not know their parent explictly.
llvm-svn: 2084
2002-04-01 00:15:30 +00:00
Chris Lattner
61f6065cef 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
a68c92a3d4 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
f9097b54be Increase limit for perimeter
llvm-svn: 2081
2002-04-01 00:12:58 +00:00
Chris Lattner
42145d8a25 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
Chris Lattner
8528806b33 * 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
d2c39a02f7 Print out the instruction instead of just the address!
llvm-svn: 2063
2002-03-31 07:15:20 +00:00
Chris Lattner
aba1ef6fc9 * 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
f1a2a9c168 * 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
5df9c977e1 s/Method/Function
llvm-svn: 2043
2002-03-29 17:08:29 +00:00
Chris Lattner
cab0ce8244 Implement getEscapingAllocations & getNonEscapingAllocations
llvm-svn: 2021
2002-03-28 19:33:00 +00:00
Chris Lattner
513ecd7256 * Rename UnlinkUndistinguishableShadowNodes & RemoveUnreachableShadowNodes
to reflect that they can eliminate arbitrary nodes.
* Rename the ShadowNodeEliminate.cpp file to EliminateNodes.cpp for the
  same reason

llvm-svn: 2020
2002-03-28 19:16:48 +00:00
Chris Lattner
fa67ad938c Ooops, I did such a great job pruning nodes, that I accidentally deleted
ALL allocation nodes... hrm... bad.

llvm-svn: 2018
2002-03-28 18:38:38 +00:00
Chris Lattner
55186e7abf Many changes
* Simplify a lot of the inlining stuff.  There are still problems, but not
  many
* Break up the Function representation to have a vector for every different
  node type so it is fast to find nodes of a particular flavor.
* Do more intelligent merging of call values
* Allow elimination of unreachable shadow and allocation nodes
* Generalize indistinguishability testing to allow merging of identical calls.
* Increase shadow node merging power

llvm-svn: 2010
2002-03-28 17:56:03 +00:00
Chris Lattner
d771725ed1 * Add #define to enabled debug messages
* Move removeEdgesTo to be a member of DSNode
* Implement (but #ifdef out) the new, spiffier, method of determining
  shadow node equivalence.  This cannot be enabled until more is
  implemented.

llvm-svn: 2004
2002-03-27 19:48:03 +00:00
Chris Lattner
4c6e9cda3f * Implement DSNode::removeAllIncomingEdges
* Implement Critical Shadow node handling
* Implement routines to determine whether an allocation node is a malloc
  or alloca

llvm-svn: 2003
2002-03-27 19:46:05 +00:00
Chris Lattner
a16c85b43d * Add critical node support
* Optimize graph after building it.  This should be unneccesary in the future

llvm-svn: 2002
2002-03-27 19:45:12 +00:00
Chris Lattner
9aff5a8047 * Destroy alloca nodes when a graph gets inlined
* Add links to all subtrees when a shadow node gets resolved
* Add critical node handling

llvm-svn: 2001
2002-03-27 19:44:33 +00:00
Chris Lattner
2a3d6c83ff * Optimizers return true on change
* Implement indistinguishable shadow node elimination

llvm-svn: 1999
2002-03-27 00:55:13 +00:00
Chris Lattner
ae0192e2f6 Fix long line
llvm-svn: 1998
2002-03-27 00:54:31 +00:00
Chris Lattner
8a44f81684 * Because of optimization, the shadow nodes between arguments might get
removed.  Check to see if they are there.
* Repeat optimizations while changing

llvm-svn: 1997
2002-03-27 00:53:57 +00:00
Chris Lattner
d5b115e687 Initial checkin of Datastructure analysis.
Has bugs, but shouldn't crash in theory.

llvm-svn: 1994
2002-03-26 22:39:06 +00:00
Chris Lattner
57efd6ffd1 change refs to Method to Function
Change references to MEthodArgument to FunctionArgument

llvm-svn: 1989
2002-03-26 17:55:33 +00:00
Chris Lattner
c481e92886 Rename Method to Function
llvm-svn: 1957
2002-03-23 22:51:58 +00:00
Vikram S. Adve
92fb8b1f9c Fixed several problems with handling arguments to Phis.
llvm-svn: 1910
2002-03-18 03:47:26 +00:00
Vikram S. Adve
cd6cb1962f Big bug fix: killed uses were being inserted instead of erased!
Also added a set of debug options.

llvm-svn: 1909
2002-03-18 03:45:41 +00:00
Chris Lattner
8cc6186707 Fix test/Regression/Other/2002-03-14-ValueToLarge.ll. Note that this
fix could be better, but we don't have the infrastructure to find out what
size types are yet.

llvm-svn: 1876
2002-03-14 22:35:50 +00:00
Chris Lattner
35c1c7353b Bugfix for test/Regression/Other/2002-03-11-ExprAssertion.ll
llvm-svn: 1856
2002-03-11 20:50:24 +00:00
Chris Lattner
0c7a32d2f4 Initial checkin
llvm-svn: 1831
2002-03-07 20:16:38 +00:00
Chris Lattner
0f0ed63279 Clean up call graph, add comments, and fix test/Regression/Other/2002-01-31-CallGraph.ll
llvm-svn: 1828
2002-03-06 20:19:35 +00:00
Chris Lattner
cc1fa55c61 Pull interprocedural analyses out of Analysis library into their own lib
llvm-svn: 1827
2002-03-06 18:44:29 +00:00
Chris Lattner
ed067d6d91 Move call graph printing support out of Writer.h into Callgraph.h
remove dead global function

llvm-svn: 1825
2002-03-06 18:00:49 +00:00
Chris Lattner
962e012ad5 Take CallGraph out of the CFG namespace. It has nothing to do with CFGs
llvm-svn: 1820
2002-03-06 17:16:43 +00:00