aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Analysis/DataStructure/BottomUpClosure.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Replace DEBUG(std::cerr with DOUT. Removed some iostream #includes.Bill Wendling2006-11-171-31/+29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31811 91177308-0d34-0410-b5e6-96231b3b80d8
* Make these hack flags hidden, like other dsa hack flagsAndrew Lenharth2006-10-231-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31136 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert the aggressive inlining for now, it doesn't handle external correctlyAndrew Lenharth2006-10-231-112/+78
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31135 91177308-0d34-0410-b5e6-96231b3b80d8
* Move some warnings to debug mode.Andrew Lenharth2006-10-131-10/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30933 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate RegisterAnalysis. RegisterPass now does all that is necessary.Chris Lattner2006-08-271-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29921 91177308-0d34-0410-b5e6-96231b3b80d8
* Do partial inlining in BU. This resolves more call sites. Also add options ↵Andrew Lenharth2006-06-191-61/+171
| | | | | | to merge in globals during recursion and to back annotate DSNodes when function pointers are resolved. This makes PA work for a whole lot more things (unresolved call sites being what has been killing various DSA based passes) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28859 91177308-0d34-0410-b5e6-96231b3b80d8
* friendlier error messageAndrew Lenharth2006-04-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27829 91177308-0d34-0410-b5e6-96231b3b80d8
* Add explicit iostream #includesChris Lattner2006-01-221-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25513 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate all remaining tabs and trailing spaces.Jeff Cohen2005-07-271-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22523 91177308-0d34-0410-b5e6-96231b3b80d8
* Correctly handle global-argument aliases induced in mainChris Lattner2005-04-251-2/+30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21537 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove trailing whitespaceMisha Brukman2005-04-211-18/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21416 91177308-0d34-0410-b5e6-96231b3b80d8
* add support for taking and resolving the address of free.Chris Lattner2005-04-211-2/+31
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21396 91177308-0d34-0410-b5e6-96231b3b80d8
* Grow the EQ classes for globals at the end of the BU pass. This shrinksChris Lattner2005-03-251-0/+93
| | | | | | | memory usage in the TD pass for 254.gap from 31.3MB to 3.9MB. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20834 91177308-0d34-0410-b5e6-96231b3b80d8
* remove a debugging timer.Chris Lattner2005-03-251-4/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20827 91177308-0d34-0410-b5e6-96231b3b80d8
* Two changes here:Chris Lattner2005-03-251-47/+41
| | | | | | | | | | | | 1. Instead of copying Local graphs to the BU graphs to start with, use spliceFrom to do the job (which is constant time in this case). On 176.gcc, this chops off .17s from the bu pass. 2. When building SCC graphs, simplify the logic and use spliceFrom to do the heavy lifting, instead of cloneInto/delete. This slices another .14s off 176.gcc. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20826 91177308-0d34-0410-b5e6-96231b3b80d8
* don't bother |'ing in 0'sChris Lattner2005-03-241-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20815 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a crash while promoting a value out of a loop from a global variableChris Lattner2005-03-241-1/+10
| | | | | | | when using ds-aa git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20802 91177308-0d34-0410-b5e6-96231b3b80d8
* a hack to allow count-aa to work with ds-aa :(Chris Lattner2005-03-231-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20791 91177308-0d34-0410-b5e6-96231b3b80d8
* Mark external globals incomplete in the BU Globals graph, fixingChris Lattner2005-03-221-0/+3
| | | | | | | Analysis/DSGraph/2005-03-22-IncompleteGlobal.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20773 91177308-0d34-0410-b5e6-96231b3b80d8
* Now that the dead ctor is gone, nothing uses the old node mapping exported byChris Lattner2005-03-221-6/+3
| | | | | | | cloneInto: make it an internally used mapping. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20760 91177308-0d34-0410-b5e6-96231b3b80d8
* now that the second argument is always this->ReturnNodes, don't bother ↵Chris Lattner2005-03-221-2/+2
| | | | | | passing it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20758 91177308-0d34-0410-b5e6-96231b3b80d8
* remove the second argument to cloneIntoChris Lattner2005-03-221-4/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20754 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a major problem where we didn't add call graph edges for call sites withChris Lattner2005-03-211-6/+10
| | | | | | | more than 1 callee. This fixes Analysis/DSGraph/FunctionPointerTable-const.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20740 91177308-0d34-0410-b5e6-96231b3b80d8
* remove some pointless assertsChris Lattner2005-03-201-1/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20713 91177308-0d34-0410-b5e6-96231b3b80d8
* Transform BU pass to not use the horrible DSCallSiteIterator class.Chris Lattner2005-03-201-40/+54
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20708 91177308-0d34-0410-b5e6-96231b3b80d8
* Create an equivalence class of global variables that DSA will never be ableChris Lattner2005-03-191-4/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | to tell apart anyway, and only track the leader for of these equivalence classes in our graphs. This dramatically reduces the number of GlobalValue*'s that appear in scalar maps, which A) reduces memory usage, by eliminating many many scalarmap entries and B) reduces time for operations that need to execute an operation for each global in the scalar map. As an example, this reduces the memory used to analyze 176.gcc from 1GB to 511MB, which (while it's still way too much) is better because it doesn't hit swap anymore. On eon, this shrinks the local graphs from 14MB to 6.8MB, shrinks the bu+td graphs of povray from 50M to 40M, shrinks the TD graphs of 130.li from 8.8M to 3.6M, etc. This change also speeds up DSA on large programs where this makes a big difference. For example, 130.li goes from 1.17s -> 0.56s, 134.perl goes from 2.14 -> 0.93s, povray goes from 15.63s->7.99s (!!!). This also apparently either fixes the problem that caused DSA to crash on perlbmk and gcc, or it hides it, because DSA now works on these. These both take entirely too much time in the TD pass (147s for perl, 538s for gcc, vs 7.67/5.9s in the bu pass for either one), but this is a known problem that I'll deal with later. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20696 91177308-0d34-0410-b5e6-96231b3b80d8
* do not bother inlining nullary functions without return values. The onlyChris Lattner2005-03-181-0/+7
| | | | | | | | | | effect these calls can have is due to global variables, and these passes all use the globals graph to capture their effect anyway. This speeds up the BU pass very slightly on perlbmk, reducing the number of dsnodes allocated from 98913 to 96423. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20676 91177308-0d34-0410-b5e6-96231b3b80d8
* fix crashes when we only have a prototype for main.Chris Lattner2005-03-151-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20627 91177308-0d34-0410-b5e6-96231b3b80d8
* Start using retnodes_* for iteration.Chris Lattner2005-03-151-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20618 91177308-0d34-0410-b5e6-96231b3b80d8
* Make sure to remove incomplete markers before we add to them! :)Chris Lattner2005-03-131-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20585 91177308-0d34-0410-b5e6-96231b3b80d8
* After finishing BU analysis, move all global variables from the globalsChris Lattner2005-03-131-0/+21
| | | | | | | graph into main and mark them complete. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20583 91177308-0d34-0410-b5e6-96231b3b80d8
* IndCallGraphMap is now a pointer to a new'd map.Chris Lattner2005-02-071-3/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20065 91177308-0d34-0410-b5e6-96231b3b80d8
* If we have an indirect call site that calls N functions, inline the N functionsChris Lattner2005-02-041-57/+98
| | | | | | | | | | | | | into a temporary graph, remember it for later, then inline the tmp graph into the call site. In the case where there are other call sites to the same set of functions, this permits us to just inline the temporary graph instead of all of the callees. This turns N*M inlining situations into an N+M inlining situation. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20036 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate some duplicated debug codeChris Lattner2005-02-011-21/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19980 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate self-recursion as a special case.Chris Lattner2005-02-011-58/+39
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19979 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate use of DSCallSiteIterator in key loop. This is a half step toChris Lattner2005-02-011-62/+120
| | | | | | | a tasty speedup. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19978 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not revisit nodes in the SCC traversal. This speeds up the BU pass a bit.Chris Lattner2005-02-011-7/+29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19968 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix some scary bugs that VC++ detected.Chris Lattner2005-01-311-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19941 91177308-0d34-0410-b5e6-96231b3b80d8
* * Make some methods more const correct.Chris Lattner2005-01-301-15/+27
| | | | | | | | | | | | | | | | | * Change the FunctionCalls and AuxFunctionCalls vectors into std::lists. This makes many operations on these lists much more natural, and avoids *exteremely* expensive copying of DSCallSites (e.g. moving nodes around between lists, erasing a node from not the end of the vector, etc). With a profile build of analyze, this speeds up BU DS from 25.14s to 12.59s on 176.gcc. I expect that it would help TD even more, but I don't have data for it. This effectively eliminates removeIdenticalCalls and children from the profile, going from 6.53 to 0.27s. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19939 91177308-0d34-0410-b5e6-96231b3b80d8
* Make -ds-aa more useful, allowing it to be updated as xforms hack on the ↵Chris Lattner2005-01-241-0/+55
| | | | | | program. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19818 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug that was preventing povray and namd from pool allocating correctly.Chris Lattner2004-11-081-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17632 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix commentChris Lattner2004-10-311-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17377 91177308-0d34-0410-b5e6-96231b3b80d8
* 'Pass' should now not be derived from by clients. Instead, they should deriveChris Lattner2004-09-201-1/+1
| | | | | | | | from ModulePass. Instead of implementing Pass::run, then should implement ModulePass::runOnModule. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16436 91177308-0d34-0410-b5e6-96231b3b80d8
* Changes For Bug 352Reid Spencer2004-09-011-2/+2
| | | | | | | | | Move include/Config and include/Support into include/llvm/Config, include/llvm/ADT and include/llvm/Support. From here on out, all LLVM public header files must be under include/llvm/. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16137 91177308-0d34-0410-b5e6-96231b3b80d8
* Headers movedChris Lattner2004-07-071-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14665 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor changes, remove some debugging code that got checked in somehow.Chris Lattner2004-03-041-7/+10
| | | | | | | | Make sure to scope the NodeMap passed into cloneInto so that it doesn't point to nodes that are deleted. Add some FIXME's for future performance enhancements. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12115 91177308-0d34-0410-b5e6-96231b3b80d8
* Only clone global nodes between graphs if both graphs have the global.Chris Lattner2004-02-271-0/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11928 91177308-0d34-0410-b5e6-96231b3b80d8
* Instead of cloning the globals for main into the globals graph at the end ofChris Lattner2004-02-211-17/+11
| | | | | | | | | | BU propagation, clone the globals into the GG of EACH FUNCTION that finishes processing! The GlobalsGraph *must* include all globals and effects from all functions in the program. Fixing this makes pool allocation work better on 175.vpr, but it still ultimately crashes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11686 91177308-0d34-0410-b5e6-96231b3b80d8
* There is no need to merge the globals graph into the function graphs at theChris Lattner2004-02-201-5/+1
| | | | | | | | | end of the BU and CBU passes. The globals will be marked incomplete, so it doesn't matter if they are missing some info, and merging isn't guaranteed to bring everything in anyway! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11684 91177308-0d34-0410-b5e6-96231b3b80d8
* When we complete the bottom-up pass, make sure to merge the globals in ↵Chris Lattner2004-02-171-0/+17
| | | | | | | | | 'main' into the globals graph. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11562 91177308-0d34-0410-b5e6-96231b3b80d8