Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 932815

Summary: sys-devel/clang-18.1.6 OoM with GCC14 and lto enabled - i586-pc-linux-gnu/bin/ld: /usr/lib/llvm/18/lib/libLLVM.so.18.1: error adding symbols: memory exhausted
Product: Gentoo Linux Reporter: immolo <immoloism>
Component: Current packagesAssignee: LLVM support project <llvm>
Status: CONFIRMED ---    
Severity: normal CC: immoloism
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: build.log

Description immolo 2024-05-27 00:03:46 UTC
Created attachment 894488 [details]
build.log

While compiling a new i586 system I have found it seems to no long be able to compile clang-18.1.6 with -flto enable as it leads to an memory exhausted error.

I'm using a faster amd64 machine for the compile in a chroot, testing the following:

-flto -j32 - fail
-flto -j1 - fail
-flto -Wl,--no-keep-memory -Wl,--reduce-memory-overheads -j1 - fail
No -flto and -j32 - Pass

Further testing is required to see if this issue exists while compiling clang with itself as it has been known RAM usage has increased since 
-fno-lifetime-dse was added to clang when being compiled with GCC.