aboutsummaryrefslogtreecommitdiffstats
path: root/utils/TableGen/InstrInfoEmitter.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-08-01 08:38:17 +0000
committerChris Lattner <sabre@nondot.org>2004-08-01 08:38:17 +0000
commit2d12b2cf7513e7ee855deec0de293311d676cb75 (patch)
tree304530fb4af082f5aaad64c9442e7e5565eb760b /utils/TableGen/InstrInfoEmitter.cpp
parenta35ce87e2e7647e401d6535ef34adaf20da5ba72 (diff)
downloadexternal_llvm-2d12b2cf7513e7ee855deec0de293311d676cb75.zip
external_llvm-2d12b2cf7513e7ee855deec0de293311d676cb75.tar.gz
external_llvm-2d12b2cf7513e7ee855deec0de293311d676cb75.tar.bz2
Instructions no longer need to have names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15399 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/TableGen/InstrInfoEmitter.cpp')
-rw-r--r--utils/TableGen/InstrInfoEmitter.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/utils/TableGen/InstrInfoEmitter.cpp b/utils/TableGen/InstrInfoEmitter.cpp
index 383e2a6..3470b2d 100644
--- a/utils/TableGen/InstrInfoEmitter.cpp
+++ b/utils/TableGen/InstrInfoEmitter.cpp
@@ -97,7 +97,12 @@ void InstrInfoEmitter::run(std::ostream &OS) {
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";