2007-01-04 Paul Brook <paul@codesourcery.com>
authorPaul Brook <paul@codesourcery.com>
Thu, 4 Jan 2007 20:08:36 +0000 (20:08 +0000)
committerPaul Brook <paul@codesourcery.com>
Thu, 4 Jan 2007 20:08:36 +0000 (20:08 +0000)
gas/
* config/tc-arm.c (do_cpsi): Set mmod bit for 2 argument form.
gas/testsuite/
* gas/arm/archv6.s: Add more cpsie tests.
* gas/arm/archv6.d: Ditto.
opcodes/
* arm-dis.c (arm_opcodes): Fix cpsie and cpsid entries.

gas/ChangeLog
gas/config/tc-arm.c
gas/testsuite/ChangeLog
gas/testsuite/gas/arm/archv6.d
gas/testsuite/gas/arm/archv6.s
opcodes/ChangeLog
opcodes/arm-dis.c

index 096ed25..2955f4c 100644 (file)
@@ -1,3 +1,7 @@
+2007-01-04  Paul Brook  <paul@codesourcery.com>
+
+       * config/tc-arm.c (do_cpsi): Set mmod bit for 2 argument form.
+
 2007-01-04  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR gas/3826
index a95fcb6..45b8d2e 100644 (file)
@@ -548,6 +548,7 @@ struct asm_opcode
 #define INDEX_UP       0x00800000
 #define WRITE_BACK     0x00200000
 #define LDM_TYPE_2_OR_3        0x00400000
+#define CPSI_MMOD      0x00020000
 
 #define LITERAL_MASK   0xf000f000
 #define OPCODE_MASK    0xfe1fffff
@@ -6828,7 +6829,11 @@ static void
 do_cpsi (void)
 {
   inst.instruction |= inst.operands[0].imm << 6;
-  inst.instruction |= inst.operands[1].imm;
+  if (inst.operands[1].present)
+    {
+      inst.instruction |= CPSI_MMOD;
+      inst.instruction |= inst.operands[1].imm;
+    }
 }
 
 static void
index 40a5895..df0a747 100644 (file)
@@ -1,3 +1,8 @@
+2007-01-04  Paul Brook  <paul@codesourcery.com>
+
+       * gas/arm/archv6.s: Add more cpsie tests.
+       * gas/arm/archv6.d: Ditto.
+
 2007-01-04  Andreas Schwab  <schwab@suse.de>
 
        * gas/m68k/cpu32.[sd]: New test.
index 1dbaad3..ed78384 100644 (file)
@@ -217,3 +217,5 @@ Disassembly of section .text:
 0+344 <[^>]*> e6ef2475 ?       uxtb r2,r5, ROR #8
 0+348 <[^>]*> 16ef2075 ?       uxtbne r2,r5
 0+34c <[^>]*> 16ef2475 ?       uxtbne r2,r5, ROR #8
+0+350 <[^>]*> f10a00ca ?       cpsie   if,#10
+0+354 <[^>]*> f10a00d5 ?       cpsie   if,#21
index 50378b7..d55c98f 100644 (file)
@@ -214,3 +214,5 @@ label:
        uxtb r2, r5, ROR #8
        uxtbne r2, r5
        uxtbne r2, r5, ROR #8
+       cpsie if, #10
+       cpsie if, #21
index d398506..7e43932 100644 (file)
@@ -1,3 +1,7 @@
+2007-01-04  Paul Brook  <paul@codesourcery.com>
+
+       * arm-dis.c (arm_opcodes): Fix cpsie and cpsid entries.
+
 2007-01-04  Andreas Schwab  <schwab@suse.de>
 
        * m68k-opc.c: Fix encoding of signed bit in the cpu32 tbls insns.
index a1f250c..3523cab 100644 (file)
@@ -814,10 +814,10 @@ static const struct opcode32 arm_opcodes[] =
   {ARM_EXT_V6K, 0x0320f000, 0x0fffff00, "nop%c\t{%0-7d}"},
 
   /* ARM V6 instructions. */
-  {ARM_EXT_V6, 0xf1080000, 0xfffdfe3f, "cpsie\t%8'a%7'i%6'f"},
-  {ARM_EXT_V6, 0xf1080000, 0xfffdfe20, "cpsie\t%8'a%7'i%6'f,#%0-4d"},
-  {ARM_EXT_V6, 0xf10C0000, 0xfffdfe3f, "cpsid\t%8'a%7'i%6'f"},
-  {ARM_EXT_V6, 0xf10C0000, 0xfffdfe20, "cpsid\t%8'a%7'i%6'f,#%0-4d"},
+  {ARM_EXT_V6, 0xf1080000, 0xfffffe3f, "cpsie\t%8'a%7'i%6'f"},
+  {ARM_EXT_V6, 0xf10a0000, 0xfffffe20, "cpsie\t%8'a%7'i%6'f,#%0-4d"},
+  {ARM_EXT_V6, 0xf10C0000, 0xfffffe3f, "cpsid\t%8'a%7'i%6'f"},
+  {ARM_EXT_V6, 0xf10e0000, 0xfffffe20, "cpsid\t%8'a%7'i%6'f,#%0-4d"},
   {ARM_EXT_V6, 0xf1000000, 0xfff1fe20, "cps\t#%0-4d"},
   {ARM_EXT_V6, 0x06800010, 0x0ff00ff0, "pkhbt%c\t%12-15r, %16-19r, %0-3r"},
   {ARM_EXT_V6, 0x06800010, 0x0ff00070, "pkhbt%c\t%12-15r, %16-19r, %0-3r, LSL #%7-11d"},