summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-12-13 00:04:46 +0000
committerChris Lattner <sabre@nondot.org>2007-12-13 00:04:46 +0000
commitf0fbf077d234f362c721976059fbffe9f51c87d0 (patch)
tree825bb068295e92bd7b5d9de504a70e39f85722d4 /llvm/lib/Transforms
parent4d1288a67e06d786cb86058280a4f2d9f024bc45 (diff)
downloadbcm5719-llvm-f0fbf077d234f362c721976059fbffe9f51c87d0.tar.gz
bcm5719-llvm-f0fbf077d234f362c721976059fbffe9f51c87d0.zip
Fix for edge profiling, patch by 'Marc' for PR1857
llvm-svn: 44965
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp b/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp
index 360d2b7db71..ca81176d329 100644
--- a/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp
+++ b/llvm/lib/Transforms/Instrumentation/EdgeProfiling.cpp
@@ -84,7 +84,7 @@ bool EdgeProfiler::runOnModule(Module &M) {
// Okay, we are guaranteed that the edge is no longer critical. If we
// only have a single successor, insert the counter in this block,
// otherwise insert it in the successor block.
- if (TI->getNumSuccessors() == 0) {
+ if (TI->getNumSuccessors() == 1) {
// Insert counter at the start of the block
IncrementCounterInBlock(BB, i++, Counters);
} else {
OpenPOWER on IntegriCloud