mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-16 14:31:59 +00:00
Fix PR10755 by checking for invalid predicate codes from UNPREDICTABLE t2IT instructions when decoding their successors.
This is the last disassembly crash detected by exhaustive Thumb2 instruction space. Major thanks to Chandler Carruth for making this kind of exhaustive testing possible. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138625 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
8fd13b6de5
commit
9bd655dcde
@ -376,6 +376,8 @@ void ThumbDisassembler::AddThumbPredicate(MCInst &MI) const {
|
||||
unsigned CC;
|
||||
if (!ITBlock.empty()) {
|
||||
CC = ITBlock.back();
|
||||
if (CC == 0xF)
|
||||
CC = ARMCC::AL;
|
||||
ITBlock.pop_back();
|
||||
} else
|
||||
CC = ARMCC::AL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user