[llvm-commits] [llvm] r114293 - /llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp
Eric Christopher
echristo at apple.com
Sat Sep 18 11:50:27 PDT 2010
Author: echristo
Date: Sat Sep 18 13:50:27 2010
New Revision: 114293
URL: http://llvm.org/viewvc/llvm-project?rev=114293&view=rev
Log:
Handle the odd case where we only have one instruction.
Modified:
llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp
Modified: llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp?rev=114293&r1=114292&r2=114293&view=diff
==============================================================================
--- llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp (original)
+++ llvm/trunk/utils/TableGen/AsmWriterEmitter.cpp Sat Sep 18 13:50:27 2010
@@ -403,6 +403,9 @@
<< " } else {\n"
<< Commands[0]
<< " }\n\n";
+ } else if (Commands.size() == 1) {
+ // Emit a single possibility.
+ O << Commands[0] << "\n\n";
} else {
O << " switch ((Bits >> " << (BitsLeft+AsmStrBits) << ") & "
<< ((1 << NumBits)-1) << ") {\n"
More information about the llvm-commits
mailing list