OSDN Git Service

Fix thumb2 assembler's ShifterOperandCanHold.
authorNicolas Geoffray <ngeoffray@google.com>
Tue, 3 Feb 2015 13:59:52 +0000 (13:59 +0000)
committerNicolas Geoffray <ngeoffray@google.com>
Tue, 3 Feb 2015 14:01:46 +0000 (14:01 +0000)
Change-Id: Ica3c5f39d52722950725ba622fc67bd7f634918a

compiler/utils/arm/assembler_thumb2.cc

index 0920a3f..895cc26 100644 (file)
@@ -37,13 +37,6 @@ bool Thumb2Assembler::ShifterOperandCanHold(Register rd,
   switch (opcode) {
     case ADD:
     case SUB:
-      if (rn == SP) {
-        if (rd == SP) {
-          return immediate < (1 << 9);    // 9 bits allowed.
-        } else {
-          return immediate < (1 << 12);   // 12 bits.
-        }
-      }
       if (immediate < (1 << 12)) {    // Less than (or equal to) 12 bits can always be done.
         return true;
       }