[Bug 294369] powerpc64: panic in zfs_write() during buildworld
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 27 Jul 2026 16:56:23 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=294369
--- Comment #5 from commit-hook@FreeBSD.org ---
A commit in branch main references this bug:
URL:
https://cgit.FreeBSD.org/src/commit/?id=b68f2fe1932cbc9809245e2c5a2db2bc0944cc5d
commit b68f2fe1932cbc9809245e2c5a2db2bc0944cc5d
Author: Jessica Clarke <jrtc27@FreeBSD.org>
AuthorDate: 2026-07-27 16:54:04 +0000
Commit: Jessica Clarke <jrtc27@FreeBSD.org>
CommitDate: 2026-07-27 16:54:04 +0000
Merge commit 26bf39cdba0b from llvm-project (by Jessica Clarke):
[ELF][PowerPC] Don't assume TOC pointer is valid in IPLT entries
(#207555)
Unlike normal PLT entries, IPLT entries can be called indirectly even
when in PIEs/DSOs, and so there's no guarantee on what's in the TOC
pointer register at that time. Therefore we must emit variants of the
existing code that work without it, whether r12-relative (playing the
same role as MIPS's $25) in the same number of instructions, or first
retrieving PC in an i386-like manner, being careful not to clobber LR.
On 32-bit PowerPC even direct calls to IPLT entries face the same issue,
since we'd use the TOC base of the resolver, which may not be the same
as the caller, even within the same object.
Normal canonical PLTs still look broken on 64-bit PowerPC as they use
the TOC pointer register too, and similarly on 32-bit PowerPC for PIEs.
We should probably treat these cases the same as PIE on i386 (except
including PDEs for 64-bit PowerPC), where it's an error due to the use
of %ebx in PLT entries.
Bump LLD_FREEBSD_VERSION for this fix as otherwise an existing system
linker will be deemed new enough to use and produce broken kernels for
TARGET=powerpc (regardless of TARGET_ARCH/MACHINE/MACHINE_ARCH) builds.
PR: 294369
MFC after: 1 week
contrib/llvm-project/lld/ELF/Arch/PPC.cpp | 13 +++---
contrib/llvm-project/lld/ELF/Arch/PPC64.cpp | 5 ++-
contrib/llvm-project/lld/ELF/Thunks.cpp | 69 +++++++++++++++++++++--------
contrib/llvm-project/lld/ELF/Thunks.h | 9 ++--
lib/clang/include/lld/Common/Version.inc | 2 +-
5 files changed, 67 insertions(+), 31 deletions(-)
--
You are receiving this mail because:
You are on the CC list for the bug.