GCC 10 Likely To See "-flto=auto" Option
With OpenSUSE now LTO'ing their Tumbleweed packages by default, SUSE's compiler team is looking at improving the compilation experience and one of those steps is via a proposed "-flto=auto" option.
While "-flto" is commonly called as is, it does support specifying a number to reflect a thread/core count for doing the optimizations and code generation at link-time in parallel. (Or there is also the "jobserver" value option for trying to calculate the number of parallel jobs via GNU Make's job server.) But to date short of using the "jobserver", there hasn't been an "auto" option for determining the optimal number of parallel jobs to use for a given system.
SUSE's Martin Liška is proposing a "-flto=auto" option for automatically detecting the number of cores to be used for the parallel phase. For now the patch is on their mailing list but hopefully this LTO auto option will make it in some form for the GCC 10 compiler update due out next year.
While "-flto" is commonly called as is, it does support specifying a number to reflect a thread/core count for doing the optimizations and code generation at link-time in parallel. (Or there is also the "jobserver" value option for trying to calculate the number of parallel jobs via GNU Make's job server.) But to date short of using the "jobserver", there hasn't been an "auto" option for determining the optimal number of parallel jobs to use for a given system.
SUSE's Martin Liška is proposing a "-flto=auto" option for automatically detecting the number of cores to be used for the parallel phase. For now the patch is on their mailing list but hopefully this LTO auto option will make it in some form for the GCC 10 compiler update due out next year.
24 Comments