Attention is currently required from: Arthur Heymans.
Arthur Heymans has posted comments on this change by Arthur Heymans. ( https://review.coreboot.org/c/coreboot/+/84012?usp=email )
The change is no longer submittable: All-Comments-Resolved is unsatisfied now.
Change subject: libpayload: Allow LTO with clang ......................................................................
Patch Set 1:
(1 comment)
File payloads/libpayload/Kconfig:
https://review.coreboot.org/c/coreboot/+/84012/comment/8a968471_6e5b331d?usp... : PS1, Line 89: final binary size, but may increase compilation time.
How well is this tested with clang? Should we leave a warning?
hackily. Clang forwards the actual linking to /usr/bin/gcc for some reason. So if you add -fuse-ld=lld and have a compatible version installed then it works.
coreinfo with clang and lto does work.
WDYT?
https://discourse.llvm.org/t/clang-linker-frontend-forwards-linking-to-gcc-o... FYI
https://github.com/llvm/llvm-project/blob/main/clang/lib/Driver/ToolChains/B... Does not support x86 bare metal. That might be worth looking into as it looks somewhat easy.