Commit Graph

13 Commits

Author SHA1 Message Date
Tobias Grosser
73362c820b RegionInfo: Do not assert if a BB is not part of the dominance tree.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110665 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-10 09:54:35 +00:00
Owen Anderson
90c579de5a Reapply r110396, with fixes to appease the Linux buildbot gods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110460 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-06 18:33:48 +00:00
Owen Anderson
1f74590e9d Revert r110396 to fix buildbots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110410 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-06 00:23:35 +00:00
Owen Anderson
9ccaf53ada Don't use PassInfo* as a type identifier for passes. Instead, use the address of the static
ID member as the sole unique type identifier.  Clean up APIs related to this change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110396 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-05 23:42:04 +00:00
Dan Gohman
811edc1f1a Fix namespace polution.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110056 91177308-0d34-0410-b5e6-96231b3b80d8
2010-08-02 18:50:06 +00:00
Daniel Dunbar
329878f4dd RegionInfo: Make sure to free cached nodes; Tobias, please check!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109650 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-28 20:28:50 +00:00
Tobias Grosser
0e6fcf4be3 RegionInfo: Add getMaxRegionExit()
getMaxRegionExit returns the exit of the maximal refined region starting
at a specific basic block.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109496 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-27 08:39:43 +00:00
Tobias Grosser
082d587d35 Add function to query RegionInfo about loops.
* contains(Loop), * getOutermostLoop()
* Improve getNameStr() to return a sensible name, if basic blocks are not named.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109490 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-27 04:17:13 +00:00
Dan Gohman
a29dbd2dcc Use DominatorTree::properlyDominates instead of dominates with an
explicit inequality check.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109398 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-26 17:34:05 +00:00
Gabor Greif
f95eef695d use cascading operator-> feature
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109104 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-22 13:49:27 +00:00
Gabor Greif
11aa60d05a use -> instead of (*).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109094 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-22 11:12:32 +00:00
Gabor Greif
3d8586eb63 cache dereferenced iterator
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109093 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-22 11:07:46 +00:00
Tobias Grosser
f96b006367 Add new RegionInfo pass.
The RegionInfo pass detects single entry single exit regions in a function,
where a region is defined as any subgraph that is connected to the remaining
graph at only two spots.
Furthermore an hierarchical region tree is built.
Use it by calling "opt -regions analyze" or "opt -view-regions".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109089 91177308-0d34-0410-b5e6-96231b3b80d8
2010-07-22 07:46:31 +00:00