diff options
author | Teresa Johnson <tejohnson@google.com> | 2016-10-19 17:35:01 +0000 |
---|---|---|
committer | Teresa Johnson <tejohnson@google.com> | 2016-10-19 17:35:01 +0000 |
commit | 740d871c3ea53e7f90f0f1a848189ccdd17acb3d (patch) | |
tree | 8a65762de4ea7bb680e92a47ac0f76f0b55ef1bb /tools/gold | |
parent | 440f75c589ce50fab15de3e8764dd2169d61fe85 (diff) |
[ThinLTO] Default backend threads to heavyweight_hardware_concurrency
Summary:
Changes default backend parallelism from thread::hardware_concurrency to
the new llvm::heavyweight_hardware_concurrency, which for X86 Linux
defaults to the number of physical cores (and will fall back to
thread::hardware_concurrency otherwise). This avoid oversubscribing
the physical cores using hyperthreading.
Reviewers: mehdi_amini, pcc
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D25775
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@284618 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/gold')
-rw-r--r-- | tools/gold/gold-plugin.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/gold/gold-plugin.cpp b/tools/gold/gold-plugin.cpp index 055c462e69a..1366c0f77fd 100644 --- a/tools/gold/gold-plugin.cpp +++ b/tools/gold/gold-plugin.cpp @@ -118,8 +118,8 @@ namespace options { static unsigned OptLevel = 2; // Default parallelism of 0 used to indicate that user did not specify. // Actual parallelism default value depends on implementation. - // Currently only affects ThinLTO, where the default is the - // hardware_concurrency. + // Currently only affects ThinLTO, where the default is + // llvm::heavyweight_hardware_concurrency. static unsigned Parallelism = 0; // Default regular LTO codegen parallelism (number of partitions). static unsigned ParallelCodeGenParallelismLevel = 1; |