From d1aca7c8b4ea45fbee18fc18a21ed963175dd7bc Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Thu, 4 Mar 2010 00:28:05 +0000 Subject: enhance comment output to specify what recorded slot numbers a ComplexPat will match into. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97696 91177308-0d34-0410-b5e6-96231b3b80d8 --- utils/TableGen/DAGISelMatcherEmitter.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'utils/TableGen/DAGISelMatcherEmitter.cpp') diff --git a/utils/TableGen/DAGISelMatcherEmitter.cpp b/utils/TableGen/DAGISelMatcherEmitter.cpp index 1f04050..1f9e093 100644 --- a/utils/TableGen/DAGISelMatcherEmitter.cpp +++ b/utils/TableGen/DAGISelMatcherEmitter.cpp @@ -375,9 +375,12 @@ EmitMatcher(const Matcher *N, unsigned Indent, unsigned CurrentIdx, OS << "OPC_CheckComplexPat, " << getComplexPat(Pattern) << ','; if (!OmitComments) { OS.PadToColumn(CommentIndent) << "// " << Pattern.getSelectFunc(); - OS << ": " << Pattern.getNumOperands() << " operands"; + OS << ':'; + for (unsigned i = 0, e = Pattern.getNumOperands(); i != e; ++i) + OS << " #" << cast(N)->getFirstResult()+i; + if (Pattern.hasProperty(SDNPHasChain)) - OS << " + chain result and input"; + OS << " + chain result"; } OS << '\n'; return 2; -- cgit v1.1