On 1/31/25 6:04 AM, Masahiro Yamada wrote:
Since commit bede169618c6 ("kbuild: enable objtool for *.mod.o and additional kernel objects"), Clang LTO builds do not perform any optimizations when CONFIG_OBJTOOL is disable (e.g., for ARCH=arm64). This is because every LLVM bitcode file is immediately converted to ELF format before the object files are linked together. This commit fixes the breakage. Fixes: bede169618c6 ("kbuild: enable objtool for *.mod.o and additional kernel objects") Reported-by: Yonghong Song <yonghong.song@xxxxxxxxx> Signed-off-by: Masahiro Yamada <masahiroy@xxxxxxxxxx>
Thanks for the fix! I tested x86_64 and arm64 for with and without lto, everything works fine. So Tested-by: Yonghong Song <yonghong.song@xxxxxxxxx>