summaryrefslogtreecommitdiffstats
path: root/llvm/utils/TableGen/CodeGenDAGPatterns.cpp
diff options
context:
space:
mode:
authorJim Grosbach <grosbach@apple.com>2014-07-09 18:55:49 +0000
committerJim Grosbach <grosbach@apple.com>2014-07-09 18:55:49 +0000
commit37b8093a8f93c39297c2f4c25337b7550a710202 (patch)
tree10723f4268ea217c98bb0acecb5633d128990437 /llvm/utils/TableGen/CodeGenDAGPatterns.cpp
parentc560a6cadce199a7e11483ffdd0eeacaab3f8241 (diff)
downloadbcm5719-llvm-37b8093a8f93c39297c2f4c25337b7550a710202.tar.gz
bcm5719-llvm-37b8093a8f93c39297c2f4c25337b7550a710202.zip
Change an assert() to a diagnostic.
llvm-svn: 212637
Diffstat (limited to 'llvm/utils/TableGen/CodeGenDAGPatterns.cpp')
-rw-r--r--llvm/utils/TableGen/CodeGenDAGPatterns.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/llvm/utils/TableGen/CodeGenDAGPatterns.cpp b/llvm/utils/TableGen/CodeGenDAGPatterns.cpp
index 00bc9a5bbb9..2602bbcf6f6 100644
--- a/llvm/utils/TableGen/CodeGenDAGPatterns.cpp
+++ b/llvm/utils/TableGen/CodeGenDAGPatterns.cpp
@@ -2119,9 +2119,11 @@ InferAllTypes(const StringMap<SmallVector<TreePatternNode*,1> > *InNamedTypes) {
// If we have input named node types, propagate their types to the named
// values here.
if (InNamedTypes) {
- // FIXME: Should be error?
- assert(InNamedTypes->count(I->getKey()) &&
- "Named node in output pattern but not input pattern?");
+ if (!InNamedTypes->count(I->getKey())) {
+ error("Node '" + std::string(I->getKey()) +
+ "' in output pattern but not input pattern");
+ return true;
+ }
const SmallVectorImpl<TreePatternNode*> &InNodes =
InNamedTypes->find(I->getKey())->second;
OpenPOWER on IntegriCloud