aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Analysis
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-06-24 00:33:16 +0000
committerDan Gohman <gohman@apple.com>2009-06-24 00:33:16 +0000
commitb6b9e9e159928b79ec0f132ee7f5faf876887ee9 (patch)
tree4f8c6ce7f05e22e5beb40e3e11624d51833ecb85 /lib/Analysis
parentf05118e304be294d811252fea3b4c4ef0f46406d (diff)
downloadexternal_llvm-b6b9e9e159928b79ec0f132ee7f5faf876887ee9.zip
external_llvm-b6b9e9e159928b79ec0f132ee7f5faf876887ee9.tar.gz
external_llvm-b6b9e9e159928b79ec0f132ee7f5faf876887ee9.tar.bz2
Include the maximum trip count expression in ScalarEvolution's print output.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74035 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Analysis')
-rw-r--r--lib/Analysis/ScalarEvolution.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/Analysis/ScalarEvolution.cpp b/lib/Analysis/ScalarEvolution.cpp
index 6e5dfbb..60a6e91 100644
--- a/lib/Analysis/ScalarEvolution.cpp
+++ b/lib/Analysis/ScalarEvolution.cpp
@@ -4340,6 +4340,15 @@ static void PrintLoopInfo(raw_ostream &OS, ScalarEvolution *SE,
}
OS << "\n";
+ OS << "Loop " << L->getHeader()->getName() << ": ";
+
+ if (!isa<SCEVCouldNotCompute>(SE->getMaxBackedgeTakenCount(L))) {
+ OS << "max backedge-taken count is " << *SE->getMaxBackedgeTakenCount(L);
+ } else {
+ OS << "Unpredictable max backedge-taken count. ";
+ }
+
+ OS << "\n";
}
void ScalarEvolution::print(raw_ostream &OS, const Module* ) const {