diff options
author | Alan Modra <amodra@gmail.com> | 2001-05-22 10:23:50 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2001-05-22 10:23:50 +0000 |
commit | 6386f3a76709a4d55f17b30449280e1b3ed01ed9 (patch) | |
tree | d54b59808b66538a730f1e79a93186fdeafaf493 /gas/config | |
parent | c801568a3aea2906c9134468c7389acab7f54763 (diff) | |
download | gdb-6386f3a76709a4d55f17b30449280e1b3ed01ed9.zip gdb-6386f3a76709a4d55f17b30449280e1b3ed01ed9.tar.gz gdb-6386f3a76709a4d55f17b30449280e1b3ed01ed9.tar.bz2 |
* symbols.c (resolve_symbol_value): Remove "finalize" param,
instead use finalize_syms directly. Don't treat expressions
specially with regard to finalize_syms. Update calls to self.
(resolve_local_symbol): Update call to resolve_symbol_value.
(S_GET_VALUE): Likewise. Return resolve_symbol_value if
!finalize_syms.
* symbols.h (resolve_symbol_value): Update prototype.
* config/obj-aout.c (obj_crawl_symbol_chain): Update call
to resolve_symbol_value.
* config/obj-bout.c (obj_crawl_symbol_chain): Likewise.
* config/obj-coff.c (do_relocs_for): Likewise.
(yank_symbols): Likewise.
(fixup_segment): Likewise.
* config/obj-vms.c (obj_crawl_symbol_chain): Likewise.
* config/tc-mips.c (md_convert_frag): Likewise.
* config/tc-ppc.c (ppc_frob_symbol): Likewise.
(ppc_fix_adjustable): Likewise.
* dwarf2dbg.c (dwarf2dbg_estimate_size_before_relax): Likewise.
(dwarf2dbg_convert_frag): Likewise.
* ehopt.c (eh_frame_estimate_size_before_relax): Likewise.
(eh_frame_convert_frag): Likewise.
* expr.c (make_expr_symbol): Likewise.
* write.c (adjust_reloc_syms): Likewise.
(write_object_file): Likewise.
(relax_segment): Likewise.
(fixup_segment): Likewise.
(finalize_syms): Init to zero, and update comment.
(write_object_file): Set finalize_syms to 1 rather than 2.
* doc/internals.texi (sy_value): Mention finalize_syms.
(S_GET_VALUE): Remove restriction on when S_GET_VALUE can be called.
Diffstat (limited to 'gas/config')
-rw-r--r-- | gas/config/obj-aout.c | 2 | ||||
-rw-r--r-- | gas/config/obj-bout.c | 2 | ||||
-rw-r--r-- | gas/config/obj-coff.c | 8 | ||||
-rw-r--r-- | gas/config/obj-vms.c | 2 | ||||
-rw-r--r-- | gas/config/tc-mips.c | 2 | ||||
-rw-r--r-- | gas/config/tc-ppc.c | 18 |
6 files changed, 16 insertions, 18 deletions
diff --git a/gas/config/obj-aout.c b/gas/config/obj-aout.c index 4bd323e..e5ffdf1 100644 --- a/gas/config/obj-aout.c +++ b/gas/config/obj-aout.c @@ -466,7 +466,7 @@ obj_crawl_symbol_chain (headers) S_SET_SEGMENT (symbolP, SEG_TEXT); } /* if pusing data into text */ - resolve_symbol_value (symbolP, finalize_syms); + resolve_symbol_value (symbolP); /* Skip symbols which were equated to undefined or common symbols. */ diff --git a/gas/config/obj-bout.c b/gas/config/obj-bout.c index 22ff671..f13ddaf 100644 --- a/gas/config/obj-bout.c +++ b/gas/config/obj-bout.c @@ -260,7 +260,7 @@ obj_crawl_symbol_chain (headers) S_SET_SEGMENT (symbolP, SEG_TEXT); } /* if pusing data into text */ - resolve_symbol_value (symbolP, finalize_syms); + resolve_symbol_value (symbolP); /* Skip symbols which were equated to undefined or common symbols. */ diff --git a/gas/config/obj-coff.c b/gas/config/obj-coff.c index 37aa640..1961fec 100644 --- a/gas/config/obj-coff.c +++ b/gas/config/obj-coff.c @@ -1972,7 +1972,7 @@ do_relocs_for (abfd, h, file_cursor) /* Turn the segment of the symbol into an offset. */ if (symbol_ptr) { - resolve_symbol_value (symbol_ptr, finalize_syms); + resolve_symbol_value (symbol_ptr); if (! symbol_ptr->sy_resolved) { char *file; @@ -2953,7 +2953,7 @@ yank_symbols () S_SET_SEGMENT (symbolP, SEG_E0); } /* push data into text */ - resolve_symbol_value (symbolP, finalize_syms); + resolve_symbol_value (symbolP); if (S_GET_STORAGE_CLASS (symbolP) == C_NULL) { @@ -4186,7 +4186,7 @@ fixup_segment (segP, this_segment_type) /* Make sure the symbols have been resolved; this may not have happened if these are expression symbols. */ if (add_symbolP != NULL && ! add_symbolP->sy_resolved) - resolve_symbol_value (add_symbolP, finalize_syms); + resolve_symbol_value (add_symbolP); if (add_symbolP != NULL) { @@ -4216,7 +4216,7 @@ fixup_segment (segP, this_segment_type) } if (sub_symbolP != NULL && ! sub_symbolP->sy_resolved) - resolve_symbol_value (sub_symbolP, finalize_syms); + resolve_symbol_value (sub_symbolP); if (add_symbolP != NULL && add_symbolP->sy_mri_common) diff --git a/gas/config/obj-vms.c b/gas/config/obj-vms.c index 3d16875..969b96e 100644 --- a/gas/config/obj-vms.c +++ b/gas/config/obj-vms.c @@ -532,7 +532,7 @@ obj_crawl_symbol_chain (headers) symbolPP = &symbol_rootP; /* -> last symbol chain link. */ while ((symbolP = *symbolPP) != NULL) { - resolve_symbol_value (symbolP, finalize_syms); + resolve_symbol_value (symbolP); /* OK, here is how we decide which symbols go out into the brave new symtab. Symbols that do are: diff --git a/gas/config/tc-mips.c b/gas/config/tc-mips.c index 907dda4..0e1ad87 100644 --- a/gas/config/tc-mips.c +++ b/gas/config/tc-mips.c @@ -11356,7 +11356,7 @@ md_convert_frag (abfd, asec, fragp) ext = false; } - resolve_symbol_value (fragp->fr_symbol, finalize_syms); + resolve_symbol_value (fragp->fr_symbol); val = S_GET_VALUE (fragp->fr_symbol); if (op->pcrel) { diff --git a/gas/config/tc-ppc.c b/gas/config/tc-ppc.c index d1f61e7..0860645 100644 --- a/gas/config/tc-ppc.c +++ b/gas/config/tc-ppc.c @@ -4221,7 +4221,7 @@ ppc_frob_symbol (sym) ppc_last_function = sym; if (symbol_get_tc (sym)->size != (symbolS *) NULL) { - resolve_symbol_value (symbol_get_tc (sym)->size, finalize_syms); + resolve_symbol_value (symbol_get_tc (sym)->size); SA_SET_SYM_FSIZE (sym, (long) S_GET_VALUE (symbol_get_tc (sym)->size)); } @@ -4281,7 +4281,7 @@ ppc_frob_symbol (sym) - S_GET_VALUE (sym)); else { - resolve_symbol_value (symbol_get_tc (sym)->next, finalize_syms); + resolve_symbol_value (symbol_get_tc (sym)->next); a->x_csect.x_scnlen.l = (S_GET_VALUE (symbol_get_tc (sym)->next) - S_GET_VALUE (sym)); } @@ -4334,7 +4334,7 @@ ppc_frob_symbol (sym) } else { - resolve_symbol_value (next, finalize_syms); + resolve_symbol_value (next); a->x_csect.x_scnlen.l = (S_GET_VALUE (next) - S_GET_VALUE (sym)); } @@ -4365,8 +4365,7 @@ ppc_frob_symbol (sym) { while (symbol_get_tc (csect)->next != (symbolS *) NULL) { - resolve_symbol_value (symbol_get_tc (csect)->next, - finalize_syms); + resolve_symbol_value (symbol_get_tc (csect)->next); if (S_GET_VALUE (symbol_get_tc (csect)->next) > S_GET_VALUE (sym)) break; @@ -4412,7 +4411,7 @@ ppc_frob_symbol (sym) /* The value is the offset from the enclosing csect. */ block = symbol_get_tc (sym)->within; csect = symbol_get_tc (block)->within; - resolve_symbol_value (csect, finalize_syms); + resolve_symbol_value (csect); S_SET_VALUE (sym, S_GET_VALUE (sym) - S_GET_VALUE (csect)); } else if (S_GET_STORAGE_CLASS (sym) == C_BINCL @@ -4629,7 +4628,7 @@ ppc_fix_adjustable (fix) { valueT val; - resolve_symbol_value (fix->fx_addsy, finalize_syms); + resolve_symbol_value (fix->fx_addsy); val = S_GET_VALUE (fix->fx_addsy); if (ppc_toc_csect != (symbolS *) NULL && fix->fx_addsy != (symbolS *) NULL @@ -4649,7 +4648,7 @@ ppc_fix_adjustable (fix) continue; if (symbol_get_tc (sy)->class != XMC_TC) break; - resolve_symbol_value (sy, finalize_syms); + resolve_symbol_value (sy); if (val == S_GET_VALUE (sy)) { fix->fx_addsy = sy; @@ -4733,8 +4732,7 @@ ppc_fix_adjustable (fix) && S_GET_SEGMENT (fix->fx_addsy) == bss_section && ! S_IS_EXTERNAL (fix->fx_addsy)) { - resolve_symbol_value (symbol_get_frag (fix->fx_addsy)->fr_symbol, - finalize_syms); + resolve_symbol_value (symbol_get_frag (fix->fx_addsy)->fr_symbol); fix->fx_offset += (S_GET_VALUE (fix->fx_addsy) - S_GET_VALUE (symbol_get_frag (fix->fx_addsy)->fr_symbol)); |