Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 909196 - dev-lang/python[lto] compiles in single thread, ignores -flto cflags
Summary: dev-lang/python[lto] compiles in single thread, ignores -flto cflags
Status: UNCONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-06-26 16:03 UTC by om3i
Modified: 2023-06-26 17:55 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description om3i 2023-06-26 16:03:54 UTC
To be more specific, the linker plugin only performs half of the compilation in a single thread. This is because configure.ac overrides the user-specified flags:
-flto=12 -flto-compression-level=0
with these flags:
LTOFLAGS="-flto ... -flto-partition=none"
I understand that single-threaded lto may produce better optimization, but I don't think it's worth the trade-off.

Reproducible: Always
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-06-26 16:13:32 UTC
This is more nuanced than it appears, in that the reason we do USE=lto for the configure argument is because for years, the configure test was broken.

This has finally been fixed in autoconf-archive via https://github.com/autoconf-archive/autoconf-archive/pull/279, but it's not yet in a release.