From c78f2a39945339752a163949a2d7c27f28635d99 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 28 Feb 2010 20:49:53 +0000 Subject: enhance the new isel to use SelectNodeTo for most patterns, even some the old isel didn't. There are several parts of this that make me feel dirty, but it's no worse than the old isel. I'll clean up the parts I can do without ripping out the old one next. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97415 91177308-0d34-0410-b5e6-96231b3b80d8 --- utils/TableGen/DAGISelMatcher.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'utils/TableGen/DAGISelMatcher.cpp') diff --git a/utils/TableGen/DAGISelMatcher.cpp b/utils/TableGen/DAGISelMatcher.cpp index d939edb563..085682fd1b 100644 --- a/utils/TableGen/DAGISelMatcher.cpp +++ b/utils/TableGen/DAGISelMatcher.cpp @@ -39,8 +39,12 @@ ScopeMatcher::~ScopeMatcher() { void ScopeMatcher::printImpl(raw_ostream &OS, unsigned indent) const { OS.indent(indent) << "Scope\n"; - for (unsigned i = 0, e = getNumChildren(); i != e; ++i) - getChild(i)->print(OS, indent+2); + for (unsigned i = 0, e = getNumChildren(); i != e; ++i) { + if (getChild(i) == 0) + OS.indent(indent+1) << "NULL POINTER\n"; + else + getChild(i)->print(OS, indent+2); + } } void RecordMatcher::printImpl(raw_ostream &OS, unsigned indent) const { -- cgit v1.2.3