]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
RISC-V: PR27584, surpress local and empty name symbols for nm.
authorNelson Chu <nelson.chu@sifive.com>
Wed, 14 Apr 2021 02:00:05 +0000 (10:00 +0800)
committerNelson Chu <nelson.chu@sifive.com>
Thu, 15 Apr 2021 02:32:36 +0000 (10:32 +0800)
commitddfe525f2875e76e0c32ff348fc0d3d6aa5fb4a3
treee4452f5c8dff39d9d510d56081143e757c507a88
parentf6a1f9574955cd2678c66e658d770adda9331995
RISC-V: PR27584, surpress local and empty name symbols for nm.

The local ".L0" symbol are usually generated to mark where the
auipc instruction is, and clang also uses ".LBB" to do the same
thing.  Besides, clang also uses the empty name symbols for label
differences.  Arm surpress their mapping symbols by regarding them
as special symbols, and MIPS surpress all local symbols.  Therefore,
RISC-V probably need to surpress the local and empty name symbols
for nm and related tools.  User can use "--special-syms" to show
these surpressed symbols.

bfd/
    PR27584
    * elfnn-riscv.c (riscv_elf_is_target_special_symbol): Added to
    omit local and empty symbols since they usually generated to
    mark the auipc instructions.
bfd/ChangeLog
bfd/elfnn-riscv.c