[llvm-commits] CVS: llvm/utils/TableGen/InstrInfoEmitter.cpp

Chris Lattner lattner at cs.uiuc.edu
Sun Aug 1 01:38:27 PDT 2004



Changes in directory llvm/utils/TableGen:

InstrInfoEmitter.cpp updated: 1.11 -> 1.12

---
Log message:

Instructions no longer need to have names.


---
Diffs of the changes:  (+6 -1)

Index: llvm/utils/TableGen/InstrInfoEmitter.cpp
diff -u llvm/utils/TableGen/InstrInfoEmitter.cpp:1.11 llvm/utils/TableGen/InstrInfoEmitter.cpp:1.12
--- llvm/utils/TableGen/InstrInfoEmitter.cpp:1.11	Sun Aug  1 00:04:00 2004
+++ llvm/utils/TableGen/InstrInfoEmitter.cpp	Sun Aug  1 03:38:17 2004
@@ -97,7 +97,12 @@
 
 void InstrInfoEmitter::emitRecord(const CodeGenInstruction &Inst, unsigned Num,
                                   Record *InstrInfo, std::ostream &OS) {
-  OS << "  { \"" << Inst.Name << "\",\t-1, -1, 0, false, 0, 0, 0, 0";
+  OS << "  { \"";
+  if (Inst.Name.empty())
+    OS << Inst.TheDef->getName();
+  else
+    OS << Inst.Name;
+  OS << "\",\t-1, -1, 0, false, 0, 0, 0, 0";
 
   // Emit all of the target indepedent flags...
   if (Inst.isReturn)     OS << "|M_RET_FLAG";





More information about the llvm-commits mailing list