From f8f8a6bc32f85d471feb4e0f4ea10f41dbbaf8ab Mon Sep 17 00:00:00 2001 From: Diego Astiazaran Date: Wed, 7 Aug 2019 18:35:28 +0000 Subject: [PATCH] [Tooling] Expose ExecutorConcurrency option. D65628 requires a flag to specify the number of threads for a clang-doc step. It would be good to use ExecutorConcurrency after exposing it instead of creating a new one that has the same purpose. Differential Revision: https://reviews.llvm.org/D65833 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@368196 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/Tooling/AllTUsExecution.h | 1 + lib/Tooling/AllTUsExecution.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/include/clang/Tooling/AllTUsExecution.h b/include/clang/Tooling/AllTUsExecution.h index e670f54234..f051119392 100644 --- a/include/clang/Tooling/AllTUsExecution.h +++ b/include/clang/Tooling/AllTUsExecution.h @@ -71,6 +71,7 @@ private: unsigned ThreadCount; }; +extern llvm::cl::opt ExecutorConcurrency; extern llvm::cl::opt Filter; } // end namespace tooling diff --git a/lib/Tooling/AllTUsExecution.cpp b/lib/Tooling/AllTUsExecution.cpp index ca9db7a561..6bda195f69 100644 --- a/lib/Tooling/AllTUsExecution.cpp +++ b/lib/Tooling/AllTUsExecution.cpp @@ -147,7 +147,7 @@ llvm::Error AllTUsToolExecutor::execute( return llvm::Error::success(); } -static llvm::cl::opt ExecutorConcurrency( +llvm::cl::opt ExecutorConcurrency( "execute-concurrency", llvm::cl::desc("The number of threads used to process all files in " "parallel. Set to 0 for hardware concurrency. " -- 2.50.1