aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-mn10300.c
diff options
context:
space:
mode:
authorAlexandre Oliva <aoliva@redhat.com>2000-05-27 21:40:22 +0000
committerAlexandre Oliva <aoliva@redhat.com>2000-05-27 21:40:22 +0000
commit3c07fb76e69e648d58d507fdb05cf8d461d87dcb (patch)
treeae68e0748ce471bd1581d19097069ee2846ae237 /gas/config/tc-mn10300.c
parent2f0b56c07dc063037f82a003c2146af0afe9b378 (diff)
downloadgdb-3c07fb76e69e648d58d507fdb05cf8d461d87dcb.zip
gdb-3c07fb76e69e648d58d507fdb05cf8d461d87dcb.tar.gz
gdb-3c07fb76e69e648d58d507fdb05cf8d461d87dcb.tar.bz2
* config/tc-mn10300.c (md_assemble): Copy size to real_size before
it is modified, and use the real_size to compute the frag address for dwarf2 line info.
Diffstat (limited to 'gas/config/tc-mn10300.c')
-rw-r--r--gas/config/tc-mn10300.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/gas/config/tc-mn10300.c b/gas/config/tc-mn10300.c
index 30b4139..9cbaf19 100644
--- a/gas/config/tc-mn10300.c
+++ b/gas/config/tc-mn10300.c
@@ -902,7 +902,7 @@ md_assemble (str)
struct mn10300_opcode *next_opcode;
const unsigned char *opindex_ptr;
int next_opindex, relaxable;
- unsigned long insn, extension, size = 0;
+ unsigned long insn, extension, size = 0, real_size;
char *f;
int i;
int match;
@@ -1480,6 +1480,8 @@ keep_going:
if (opcode->format == FMT_D4)
size = 6;
+ real_size = size;
+
if (relaxable && fc > 0)
{
int type;
@@ -1760,7 +1762,7 @@ keep_going:
/* We want the offset of the start of this instruction within the
the current frag. */
- addr = frag_now->fr_address + frag_now_fix () - size;
+ addr = frag_now->fr_address + frag_now_fix () - real_size;
/* And record the information. */
dwarf2_gen_line_info (addr, &debug_line);