aboutsummaryrefslogtreecommitdiff
path: root/ld/ldemul.h
diff options
context:
space:
mode:
authorDouglas B Rupp <rupp@adacore.com>2020-05-18 21:29:53 +0930
committerAlan Modra <amodra@gmail.com>2020-05-18 22:41:32 +0930
commit3edf7b9f2c79be0bffcc05d7a8b4364924255282 (patch)
treecf499e1cc207f511163402eda4591ac965657fc7 /ld/ldemul.h
parent6e0c75f7c4a94e835842f52aadb4e1a83c3b4e0a (diff)
downloadfsf-binutils-gdb-3edf7b9f2c79be0bffcc05d7a8b4364924255282.zip
fsf-binutils-gdb-3edf7b9f2c79be0bffcc05d7a8b4364924255282.tar.gz
fsf-binutils-gdb-3edf7b9f2c79be0bffcc05d7a8b4364924255282.tar.bz2
Show AIX gc'd symbol address adjustments in map file
* ldemul.h (ldemul_print_symbol): New. (ld_emulation_xfer_type) <print_symbol): Likewise. * ldemul.c (ldemul_print_symbol): New. * ldlang.c (SECTION_NAME_MAP_LANGTH): Move to ... (print_one_symbol): Make global and move declaration to ... (print_all_symbols): Rename print_one_symbol to ldemul_print_symbol (print_input_section): Likewise * ldlang.h: ... here. * emultempl/aix.em (gld${EMULATION_NAME}_print_symbol): New. (ld_emulation_xfer_struct): Use it. * emultempl/armcoff.em (ld_emulation_xfer_struct): Add print_symbol and default to NULL. * emultempl/beos.em (ld_emulation_xfer_struct): Likewise * emultempl/elf.em (ld_emulation_xfer_struct): Likewise * emultempl/generic.em (ld_emulation_xfer_struct): Likewise * emultempl/linux.em (ld_emulation_xfer_struct): Likewise * emultempl/msp430.em (ld_emulation_xfer_struct): Likewise * emultempl/pe.em (ld_emulation_xfer_struct): Likewise * emultempl/pep.em (ld_emulation_xfer_struct): Likewise * emultempl/ticoff.em (ld_emulation_xfer_struct): Likewise * emultempl/vanilla.em (ld_emulation_xfer_struct): Likewise
Diffstat (limited to 'ld/ldemul.h')
-rw-r--r--ld/ldemul.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/ld/ldemul.h b/ld/ldemul.h
index 44e3a92..ca165ac 100644
--- a/ld/ldemul.h
+++ b/ld/ldemul.h
@@ -112,6 +112,8 @@ extern int ldemul_emit_ctf_early
extern void ldemul_examine_strtab_for_ctf
(struct ctf_file *, struct elf_sym_strtab *, bfd_size_type,
struct elf_strtab_hash *);
+extern bfd_boolean ldemul_print_symbol
+ (struct bfd_link_hash_entry *hash_entry, void *ptr);
typedef struct ld_emulation_xfer_struct {
/* Run before parsing the command line and script file.
@@ -236,6 +238,12 @@ typedef struct ld_emulation_xfer_struct {
bfd_link_callback is invoked by per-target code. */
void (*examine_strtab_for_ctf) (struct ctf_file *, struct elf_sym_strtab *,
bfd_size_type, struct elf_strtab_hash *);
+
+ /* Called when printing a symbol to the map file. AIX uses this
+ hook to flag gc'd symbols. */
+ bfd_boolean (*print_symbol)
+ (struct bfd_link_hash_entry *hash_entry, void *ptr);
+
} ld_emulation_xfer_type;
typedef enum {