Tighten decoding of addrmode2 instructions to reject more UNPREDICTABLE cases.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137325 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson
2011-08-11 19:00:18 +00:00
parent 59353b436a
commit 71156a6e00
2 changed files with 4 additions and 3 deletions

View File

@ -978,6 +978,8 @@ static bool DecodeAddrMode2IdxInstruction(llvm::MCInst &Inst, unsigned Insn,
else if (!P && writeback)
idx_mode = ARMII::IndexModePost;
if (writeback && (Rn == 15 || Rn == Rt)) return false; // UNPREDICTABLE
if (reg) {
if (!DecodeGPRnopcRegisterClass(Inst, Rm, Address, Decoder)) return false;
ARM_AM::ShiftOpc Opc = ARM_AM::lsl;