summaryrefslogtreecommitdiff
path: root/utils/TableGen
diff options
context:
space:
mode:
authorOwen Anderson <resistor@mac.com>2011-08-01 18:44:37 +0000
committerOwen Anderson <resistor@mac.com>2011-08-01 18:44:37 +0000
commit7f76baed5ef5383cb4d27df8864f305d728b75ae (patch)
tree99a458f2c41d3946d4979d345a8f2fe6e1dcf944 /utils/TableGen
parent423b81e6924f882f8b1cf7a7d4126b25b5f915aa (diff)
downloadllvm-7f76baed5ef5383cb4d27df8864f305d728b75ae.tar.gz
llvm-7f76baed5ef5383cb4d27df8864f305d728b75ae.tar.bz2
llvm-7f76baed5ef5383cb4d27df8864f305d728b75ae.tar.xz
Enhance the fixed length disassembler to better handle operand decoding failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136635 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'utils/TableGen')
-rw-r--r--utils/TableGen/FixedLenDecoderEmitter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/utils/TableGen/FixedLenDecoderEmitter.cpp b/utils/TableGen/FixedLenDecoderEmitter.cpp
index b87634bfee..5d42e71e5e 100644
--- a/utils/TableGen/FixedLenDecoderEmitter.cpp
+++ b/utils/TableGen/FixedLenDecoderEmitter.cpp
@@ -744,8 +744,8 @@ void FilterChooser::emitBinaryParser(raw_ostream &o, unsigned &Indentation,
}
if (Decoder != "")
- o.indent(Indentation) << " " << Decoder
- << "(MI, tmp, Address, Decoder);\n";
+ o.indent(Indentation) << " if (!" << Decoder
+ << "(MI, tmp, Address, Decoder)) return false;\n";
else
o.indent(Indentation) << " MI.addOperand(MCOperand::CreateImm(tmp));\n";