diff options
author | Chris Lattner <sabre@nondot.org> | 2010-11-15 05:19:05 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-11-15 05:19:05 +0000 |
commit | 63274cbc5d6bb988ede7eafedddc00ec860cdd89 (patch) | |
tree | e8ec394db8cf1bf2a0c413278cb9da46d8de42fb /llvm/utils/TableGen/CodeEmitterGen.cpp | |
parent | 85854eb4d91aa27a5b2748b5341a9b60f0dafa91 (diff) | |
download | bcm5719-llvm-63274cbc5d6bb988ede7eafedddc00ec860cdd89.tar.gz bcm5719-llvm-63274cbc5d6bb988ede7eafedddc00ec860cdd89.zip |
add fields to the .td files unconditionally, simplifying tblgen a bit.
Switch the ARM backend to use 'let' instead of 'set' with this change.
llvm-svn: 119120
Diffstat (limited to 'llvm/utils/TableGen/CodeEmitterGen.cpp')
-rw-r--r-- | llvm/utils/TableGen/CodeEmitterGen.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/utils/TableGen/CodeEmitterGen.cpp b/llvm/utils/TableGen/CodeEmitterGen.cpp index e7b022af15f..debc8776134 100644 --- a/llvm/utils/TableGen/CodeEmitterGen.cpp +++ b/llvm/utils/TableGen/CodeEmitterGen.cpp @@ -230,9 +230,9 @@ void CodeEmitterGen::run(raw_ostream &o) { } } - if (R->getValue("PostEncoderMethod")) - Case += " Value = " + - R->getValueAsString("PostEncoderMethod") + "(MI, Value);\n"; + std::string PostEmitter = R->getValueAsString("PostEncoderMethod"); + if (!PostEmitter.empty()) + Case += " Value = " + PostEmitter + "(MI, Value);\n"; std::vector<std::string> &InstList = CaseMap[Case]; InstList.push_back(InstName); |