NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
toolchain/59390: build with -Wl,-z,pack-relative-relocs by default
>Number: 59390
>Category: toolchain
>Synopsis: build with -Wl,-z,pack-relative-relocs by default
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: toolchain-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat May 03 13:30:00 +0000 2025
>Originator: Taylor R Campbell
>Release: current
>Organization:
Relocation Relativists LLC
>Environment:
>Description:
Now that ld.elf_so supports packed relative relocations (PR bin/59360: ld.elf_so(8): missing RELR support, https://gnats.NetBSD.org/59360), we should enable it in the build on any platforms where GNU binutils supports it, particularly when MKPIE=yes. Should be some hefty savings available for some programs:
(amd64)
$ size apropos.{before,after}
text data bss dec hex filename
221781 44930 72 266783 4121f apropos.before
91637 44978 72 136687 215ef apropos.after
$ size makemandb.{before,after}
text data bss dec hex filename
409881 75868 264 486013 76a7d makemandb.before
250073 75916 264 326253 4fa6d makemandb.after
Unfortunately, this is blocked on CTF tool support for RELR (PR toolchain/59364: ctf tools needs update, https://gnats.NetBSD.org/59364):
ERROR: nbctfmerge: apropos: Cannot get sect .relr.dyn data: Invalid section descriptor
>How-To-Repeat:
binary inspetion
>Fix:
Yes, please!
Home |
Main Index |
Thread Index |
Old Index