summaryrefslogtreecommitdiffstats
path: root/llvm/lib/IR/Dominators.cpp
diff options
context:
space:
mode:
authorPiotr Padlewski <prazek@google.com>2015-09-02 19:59:59 +0000
committerPiotr Padlewski <prazek@google.com>2015-09-02 19:59:59 +0000
commit28ffcbe1ccbdd667f9f222a3c9ef9d2e3ed69253 (patch)
treedd82570cbec1f5b65ae0c4a6905de388fa124bd1 /llvm/lib/IR/Dominators.cpp
parent14e815c22bd167afe6bff4e65f09bbdeed029c87 (diff)
downloadbcm5719-llvm-28ffcbe1ccbdd667f9f222a3c9ef9d2e3ed69253.tar.gz
bcm5719-llvm-28ffcbe1ccbdd667f9f222a3c9ef9d2e3ed69253.zip
Constant propagation after hitting assume(cmp) bugfix
Last time code run into assertion `BBE.isSingleEdge()` in lib/IR/Dominators.cpp:200. http://reviews.llvm.org/D12170 llvm-svn: 246696
Diffstat (limited to 'llvm/lib/IR/Dominators.cpp')
-rw-r--r--llvm/lib/IR/Dominators.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/llvm/lib/IR/Dominators.cpp b/llvm/lib/IR/Dominators.cpp
index 775bd92f2ed..d94e31d4875 100644
--- a/llvm/lib/IR/Dominators.cpp
+++ b/llvm/lib/IR/Dominators.cpp
@@ -147,7 +147,8 @@ bool DominatorTree::dominates(const BasicBlockEdge &BBE,
// Assert that we have a single edge. We could handle them by simply
// returning false, but since isSingleEdge is linear on the number of
// edges, the callers can normally handle them more efficiently.
- assert(BBE.isSingleEdge());
+ assert(BBE.isSingleEdge() &&
+ "This function is not efficient in handling multiple edges");
// If the BB the edge ends in doesn't dominate the use BB, then the
// edge also doesn't.
@@ -197,7 +198,8 @@ bool DominatorTree::dominates(const BasicBlockEdge &BBE, const Use &U) const {
// Assert that we have a single edge. We could handle them by simply
// returning false, but since isSingleEdge is linear on the number of
// edges, the callers can normally handle them more efficiently.
- assert(BBE.isSingleEdge());
+ assert(BBE.isSingleEdge() &&
+ "This function is not efficient in handling multiple edges");
Instruction *UserInst = cast<Instruction>(U.getUser());
// A PHI in the end of the edge is dominated by it.
OpenPOWER on IntegriCloud