aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorDJ Delorie <dj@redhat.com>2008-11-25 23:02:02 +0000
committerDJ Delorie <dj@redhat.com>2008-11-25 23:02:02 +0000
commit911c9c13f86f639ce46cd813b73115c9deb14268 (patch)
treeb32482a89c4452c8675ca48c6b53ee67bc23ae50 /gas
parent85f77068e7a88f1a1026d524d4e56dadd44bd802 (diff)
downloadgdb-911c9c13f86f639ce46cd813b73115c9deb14268.zip
gdb-911c9c13f86f639ce46cd813b73115c9deb14268.tar.gz
gdb-911c9c13f86f639ce46cd813b73115c9deb14268.tar.bz2
* config/tc-m32c.c (md_convert_frag): Fix ADJNZ reloc math.
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog4
-rw-r--r--gas/config/tc-m32c.c8
2 files changed, 8 insertions, 4 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index b36db8e..b78e7bf 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,7 @@
+2008-11-25 DJ Delorie <dj@redhat.com>
+
+ * config/tc-m32c.c (md_convert_frag): Fix ADJNZ reloc math.
+
2008-11-21 Sterling Augustine <sterling@tensilica.com>
* config/tc-xtensa.c (check_t1_t2_reads_and_writes): Call
diff --git a/gas/config/tc-m32c.c b/gas/config/tc-m32c.c
index db9cc06..ec0a80c 100644
--- a/gas/config/tc-m32c.c
+++ b/gas/config/tc-m32c.c
@@ -866,22 +866,22 @@ md_convert_frag (bfd * abfd ATTRIBUTE_UNUSED,
case -M32C_MACRO_ADJNZ_2:
rl_addend = 0x31;
- op[2] = addend;
+ op[2] = addend - 2;
operand = M32C_OPERAND_LAB_16_8;
break;
case -M32C_MACRO_ADJNZ_3:
rl_addend = 0x41;
- op[3] = addend;
+ op[3] = addend - 2;
operand = M32C_OPERAND_LAB_24_8;
break;
case -M32C_MACRO_ADJNZ_4:
rl_addend = 0x51;
- op[4] = addend;
+ op[4] = addend - 2;
operand = M32C_OPERAND_LAB_32_8;
break;
case -M32C_MACRO_ADJNZ_5:
rl_addend = 0x61;
- op[5] = addend;
+ op[5] = addend - 2;
operand = M32C_OPERAND_LAB_40_8;
break;