]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
SHT_SYMTAB_SHNDX handling
authorAlan Modra <amodra@gmail.com>
Thu, 2 Sep 2021 00:26:11 +0000 (09:56 +0930)
committerAlan Modra <amodra@gmail.com>
Thu, 2 Sep 2021 04:18:21 +0000 (13:48 +0930)
commitb03b65e2aa3243bc0224ba3f933a3e94f1eed8a1
treea2bc19c802d9ae973d9af4a0203bbe4594759c5f
parent36f61bf2ad936edfb76eda706eb3b081a61d5a5a
SHT_SYMTAB_SHNDX handling

.symtab_shndx section contents is an array, one entry for each symbol
in .symtab, present when the number of symbols exceeds a little less
than 64k.  Since the mapping is 1-1 with symbols there is no need to
keep both dest_index and destshndx_index in elf_sym_strtab.  Instead,
just make sure that the shndx pointers to the swap functions are kept
NULL when .symtab_shndx does not exist.  Also, strtabcount in the
linker's elf hash table is incremented in lock-step with the output
symcount, so that can disappear too.
bfd/elf-bfd.h
bfd/elf.c
bfd/elflink.c