Date: Mon, 28 Mar 2022 11:11:44 +0000 From: bugzilla-noreply@freebsd.org To: toolchain@FreeBSD.org Subject: [Bug 261977] lang/gcc12-devel: enable LTO Message-ID: <bug-261977-29464-j1dFwglUUR@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-261977-29464@https.bugs.freebsd.org/bugzilla/> References: <bug-261977-29464@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D261977 --- Comment #14 from Dimitry Andric <dim@FreeBSD.org> --- LTO is a trade-off, where you sacrifice more memory and CPU at link time for possibly faster and/or smaller final binaries. That it eats more resources = is almost guaranteed, but slightly "better" binaries may not be worth the cost= ... (Side note: one annoying aspect is that because it can be so time consuming, these heavy link jobs tend to cluster up, if you do a multi-jobbed build, either via poudriere or some other build system. Which then means that you = have a bunch of huge linking processes running in parallel, eating up even more resources!) That said, I would say the safe, conservative choice is to make use of LTO = an opt-in (either global, or per port), instead of an opt-out? I mean, if you have a huge machine with plenty of CPU and RAM, then by all means LTO the hell out of everything, but most people aren't that lucky (or rich). :-) --=20 You are receiving this mail because: You are on the CC list for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-261977-29464-j1dFwglUUR>