From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 9683D3959CBE; Thu, 27 May 2021 18:14:01 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9683D3959CBE From: "i at maskray dot me" To: glibc-bugs@sourceware.org Subject: [Bug dynamic-link/27924] New: ld.so: Support DT_RELR relative relocation format Date: Thu, 27 May 2021 18:14:01 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: dynamic-link X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: i at maskray dot me X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: glibc-bugs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Glibc-bugs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 May 2021 18:14:01 -0000 https://sourceware.org/bugzilla/show_bug.cgi?id=3D27924 Bug ID: 27924 Summary: ld.so: Support DT_RELR relative relocation format Product: glibc Version: unspecified Status: UNCONFIRMED Severity: normal Priority: P2 Component: dynamic-link Assignee: unassigned at sourceware dot org Reporter: i at maskray dot me Target Milestone: --- Position independent executables and shared objects built with -Bsymbolic/-Bsymbolic-functions may have many relative relocations (instead= of absolute relocations (e.g. R_X86_64_64)). (The number of R_*_RELATIVE is the dominating factor between a PDE and a PI= E in terms of their size differences.) Relative relocations can be packed in a compact format to save a lot of spa= ce. See the last few messages on https://groups.google.com/g/generic-abi/c/bX460iggiKg An Elf64_Rela takes 24 bytes. 64 consecutive R_*_RELATIVE take 24*64 bytes.= In RELR, this just needs 8*2 bytes. DT_RELR has support in the Linux kernel (arch/arm64/Kconfig ARCH_HAS_RELR) since 2019 https://git.kernel.org/linus/5cf896fb6be3effd9aea455b22213e27be8bdb1d SHT_RELR/DT_RELR has dumper support in llvm-readobj/llvm-readelf.=20 ld.lld --pack-dyn-relocs=3Drelr can encode R_*_RELATIVE in RELR. GNU ld feature request: https://sourceware.org/bugzilla/show_bug.cgi?id=3D2= 7923 --=20 You are receiving this mail because: You are on the CC list for the bug.=