mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-11-03 19:31:34 +00:00
lld relies on a memset that GCC 16 is allowed to optimize away, leaving some symbol fields uninitialized. With lld 21, this makes `ld -r` emit broken section symbols, which breaks LTO kernel module builds (see ClangBuiltLinux/linux#2162). 18 through 20 should have the same bug, but I haven't seen it break there myself. This backports llvm/llvm-project@4d5dffb594 and llvm/llvm-project@070e505ce2, which landed in 22.1.8.