mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-01 15:11:24 +00:00
Fix off-by-one error.
(low two bits always zero, so off by one bit of encoded value). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@134247 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
4db3cffe94
commit
eb03c3b228
@ -491,7 +491,7 @@ Thumb2SizeReduce::ReduceSpecial(MachineBasicBlock &MBB, MachineInstr *MI,
|
||||
// The immediate must be in range, the destination register must be a low
|
||||
// reg, the predicate must be "always" and the condition flags must not
|
||||
// be being set.
|
||||
if (Imm & 3 || Imm > 1024)
|
||||
if (Imm & 3 || Imm > 1020)
|
||||
return false;
|
||||
if (!isARMLowRegister(MI->getOperand(0).getReg()))
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user