From 9d4dfbf3790af4d35484301d63ee9e1a791ad9e5 Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Mon, 19 Jul 1993 16:49:01 +0000 Subject: [PATCH] fix net-equip pr 2975: tm-m68k.c(m68k_ip): adjust for pc-rel offset before using value, not after --- gas/ChangeLog | 6 ++++++ gas/config/tc-m68k.c | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/gas/ChangeLog b/gas/ChangeLog index 672cad5715f..fb772ad7426 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,9 @@ +Mon Jul 19 12:35:39 1993 Ken Raeburn (raeburn@cambridge.cygnus.com) + + * config/tc-m68k.c (m68k_ip, case AINDX): Add 6 to operand + expression (to take the pc-rel instruction itself into account) + before using the expression, instead of after. + Fri Jul 16 08:56:04 1993 Ian Lance Taylor (ian@cygnus.com) * read.c (float_cons): Simplified parsing logic. If diff --git a/gas/config/tc-m68k.c b/gas/config/tc-m68k.c index d176838a298..f0d419b5706 100644 --- a/gas/config/tc-m68k.c +++ b/gas/config/tc-m68k.c @@ -2443,8 +2443,8 @@ m68k_ip (instring) { if (opP->reg == PC || opP->reg == ZPC) { - add_fix (siz1 == 3 ? 'l' : 'w', opP->con1, 1); opP->con1->e_exp.X_add_number += 6; + add_fix (siz1 == 3 ? 'l' : 'w', opP->con1, 1); } else add_fix (siz1 == 3 ? 'l' : 'w', opP->con1, 0); @@ -2458,8 +2458,8 @@ m68k_ip (instring) { if (opP->reg == PC || opP->reg == ZPC) { - add_fix (siz2 == 3 ? 'l' : 'w', opP->con2, 1); opP->con1->e_exp.X_add_number += 6; + add_fix (siz2 == 3 ? 'l' : 'w', opP->con2, 1); } else add_fix (siz2 == 3 ? 'l' : 'w', opP->con2, 0); -- 2.30.2