summaryrefslogtreecommitdiff
path: root/opcodes/arm-dis.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2003-08-19 13:05:41 +0000
committerNick Clifton <nickc@redhat.com>2003-08-19 13:05:41 +0000
commit4d231f6b7d0299cac1680c50a1b89380b2157811 (patch)
tree127853fd39eecd45e67de8453a0574e69a12e52b /opcodes/arm-dis.c
parent4432ac04ace6a455c172d1c182d3fc233b93baae (diff)
downloadgdb-4d231f6b7d0299cac1680c50a1b89380b2157811.tar.gz
Add support for unindexed form of Addressing Mode 5
Diffstat (limited to 'opcodes/arm-dis.c')
-rw-r--r--opcodes/arm-dis.c20
1 files changed, 14 insertions, 6 deletions
diff --git a/opcodes/arm-dis.c b/opcodes/arm-dis.c
index 97ec8423485..ac36e88006b 100644
--- a/opcodes/arm-dis.c
+++ b/opcodes/arm-dis.c
@@ -445,9 +445,11 @@ print_insn_arm (pc, info, given)
case 'A':
func (stream, "[%s", arm_regnames [(given >> 16) & 0xf]);
- if ((given & 0x01000000) != 0)
+
+ if ((given & (1 << 24)) != 0)
{
int offset = given & 0xff;
+
if (offset)
func (stream, ", %s#%d]%s",
((given & 0x00800000) == 0 ? "-" : ""),
@@ -459,12 +461,18 @@ print_insn_arm (pc, info, given)
else
{
int offset = given & 0xff;
- if (offset)
- func (stream, "], %s#%d",
- ((given & 0x00800000) == 0 ? "-" : ""),
- offset * 4);
+
+ func (stream, "]");
+
+ if (given & (1 << 21))
+ {
+ if (offset)
+ func (stream, ", %s#%d",
+ ((given & 0x00800000) == 0 ? "-" : ""),
+ offset * 4);
+ }
else
- func (stream, "]");
+ func (stream, ", {%d}", offset);
}
break;