https://bugs.llvm.org/show_bug.cgi?id=42289
Bug ID: 42289
Summary: LLD fails to merge similarly named sections
Product: lld
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: ELF
Assignee: unassignedb...@nondot.org
Reporter: ndesaulni...@google.com
CC: llvm-bugs@lists.llvm.org, peter.sm...@linaro.org,
sedat.di...@gmail.com, srhi...@google.com
Blocks: 4068
via: https://github.com/ClangBuiltLinux/linux/issues/431
It seems that ld.bfd merges sections with the same name, whereas ld.lld does
not.
$ ld.bfd -r -o driver.ko ath10k_core.o ath10k_core.mod.o
$ readelf -S driver.ko | grep rodata\.cst32 [71] .rodata.cst32 PROGBITS
0000000000000000 00062d60
$ ld.lld -r -o driver.ko ath10k_core.o ath10k_core.mod.o
$ readelf -S driver.ko | grep rodata\.cst32
[104] .rodata.cst32 PROGBITS 0000000000000000 00a20850
[157] .rodata.cst32 PROGBITS 0000000000000000 00a20e20
This produces dmesg warnings for kernel modules linked with LLD:
$ dmesg | grep sysfs:
[ 1.969125] sysfs: cannot create duplicate filename
'/module/i915/sections/.rodata.cst16'
[ 3.954645] sysfs: cannot create duplicate filename
'/module/bluetooth/sections/.rodata.cst16'
[ 4.009524] sysfs: cannot create duplicate filename
'/module/mac80211/sections/.rodata.cst32'
[ 4.122455] sysfs: cannot create duplicate filename
'/module/ath10k_core/sections/.rodata.cst32'
Referenced Bugs:
https://bugs.llvm.org/show_bug.cgi?id=4068
[Bug 4068] [Meta] Compiling the Linux kernel with clang
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs