Bin map file: Fix incorrect address printing for symbols.

We were printing the previous bytecode's start rather than the label's
bytecode.  Use yasm_bc_next_offset() to get the correct offset.

svn path=/trunk/yasm/; revision=2110
This commit is contained in:
Peter Johnson 2008-07-03 04:19:12 +00:00
parent 53b2d01a77
commit bd4a2ffdb8
3 changed files with 6 additions and 6 deletions

View file

@ -681,13 +681,13 @@ map_symrec_output(yasm_symrec *sym, void *d)
yasm_section_get_data(info->section, &bin_section_data_cb);
/* Real address */
yasm_intnum_set_uint(info->intn, precbc->offset);
yasm_intnum_set_uint(info->intn, yasm_bc_next_offset(precbc));
yasm_intnum_calc(info->intn, YASM_EXPR_ADD, bsd->istart);
map_print_intnum(info->intn, info);
fprintf(info->f, " ");
/* Virtual address */
yasm_intnum_set_uint(info->intn, precbc->offset);
yasm_intnum_set_uint(info->intn, yasm_bc_next_offset(precbc));
yasm_intnum_calc(info->intn, YASM_EXPR_ADD, bsd->ivstart);
map_print_intnum(info->intn, info);

View file

@ -73,6 +73,6 @@ Real Virtual Name
---- Section .bss -------------------------------------------------------------
Real Virtual Name
00000020 00000020 stack_ends
00000420 00000420 stack_ends

View file

@ -55,9 +55,9 @@ vfollows: not defined
---- Section .text ------------------------------------------------------------
Real Virtual Name
0000010C 0000010C showax
0000010F 0000010F showax.top
0000011F 0000011F showax.dec_dig
0000010D 0000010D showax
00000112 00000112 showax.top
00000122 00000122 showax.dec_dig
---- Section .data ------------------------------------------------------------