[ARM] NEON instructions were erroneously decoded from certain invalid encodings

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@193705 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Artyom Skrobov 2013-10-30 18:10:09 +00:00
parent aa1d078e7f
commit 3f04b50686
2 changed files with 28 additions and 20 deletions

View File

@ -829,7 +829,6 @@ DecodeStatus ThumbDisassembler::getInstruction(MCInst &MI, uint64_t &Size,
Check(result, AddThumbPredicate(MI));
return result;
}
}
MI.clear();
uint32_t NEONCryptoInsn = insn32;
@ -852,6 +851,7 @@ DecodeStatus ThumbDisassembler::getInstruction(MCInst &MI, uint64_t &Size,
Size = 4;
return result;
}
}
MI.clear();
Size = 0;

View File

@ -33,3 +33,11 @@
0xe0 0xef 0xa1 0x0e
# CHECK: vmull.p64 q8, d16, d17
# This used to be incorrectly decoded into an sha256h.32 [0x00,0xff,0x40,0x0c]
# The other similar encodings are stc2 [0x00,0xfd,0x40,0x0c] and cdp2 [0x00,0xfe,0x40,0x0c]
0x00 0xfc 0x40 0x0c
# CHECK-NOT: sha256h.32
# CHECK-NOT: stc2
# CHECK-NOT: cdp2