commit | 168705049c55feec88aec65af0aef07fc1376ce6 | [log] [tgz] |
---|---|---|
author | Eric Christopher <echristo@apple.com> | Sat Sep 18 18:50:27 2010 +0000 |
committer | Eric Christopher <echristo@apple.com> | Sat Sep 18 18:50:27 2010 +0000 |
tree | 622283036aeeb10ddf80d85524f4df832966c0e1 | |
parent | 895dda6fb541a4c56b58dafaaa767b980b27b0c6 [diff] [blame] |
Handle the odd case where we only have one instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114293 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/utils/TableGen/AsmWriterEmitter.cpp b/utils/TableGen/AsmWriterEmitter.cpp index 23f13c2..44622e9 100644 --- a/utils/TableGen/AsmWriterEmitter.cpp +++ b/utils/TableGen/AsmWriterEmitter.cpp
@@ -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"