================ @@ -708,6 +712,34 @@ void amdgpu::getAMDGPUTargetFeatures(const Driver &D, options::OPT_m_amdgpu_Features_Group); } +static unsigned GetFullLTOPartitions(const Driver &D, const ArgList &Args) { + const Arg *A = Args.getLastArg(options::OPT_flto_partitions_EQ); + // In the absence of an option, use the number of available threads with a cap + // at 16 partitions. More than 16 partitions rarely benefits code splitting + // and can lead to more empty/small modules each with their own overhead. + if (!A) + return std::max(16u, llvm::hardware_concurrency().compute_thread_count()); ---------------- jmmartinez wrote:
"More than 16 partitions rarely benefits code splitting" -> In that case shouldn't it be the std::min between 16 and thread_count ? https://github.com/llvm/llvm-project/pull/128509 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits