improve comments on OPC_Record to say what we're recording a node.
[oota-llvm.git] / utils / TableGen / DAGISelMatcherEmitter.cpp
index af75d7d71ec2708191478ea1158dca5ed702a2e1..9b37254cbdde575efd9fcf391d4a7fa305a27f35 100644 (file)
@@ -126,7 +126,9 @@ EmitMatcher(const MatcherNode *N, unsigned Indent) {
     OS.PadToColumn(Indent*2) << "OPC_Emit, /*XXX*/\n\n";
     return 1;
   case MatcherNode::Record:
-    OS << "OPC_Record,\n";
+    OS << "OPC_Record,";
+    OS.PadToColumn(CommentIndent) << "// "
+       << cast<RecordMatcherNode>(N)->getWhatFor() << '\n';
     return 1;
   case MatcherNode::MoveChild:
     OS << "OPC_MoveChild, "