initialization_util.h 681 B

12345678910111213141516171819202122
  1. // Copyright 2016 The Chromium Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style license that can be
  3. // found in the LICENSE file.
  4. #ifndef BASE_TASK_THREAD_POOL_INITIALIZATION_UTIL_H_
  5. #define BASE_TASK_THREAD_POOL_INITIALIZATION_UTIL_H_
  6. #include "base/base_export.h"
  7. namespace base {
  8. // Computes a value that may be used as the maximum number of threads in a
  9. // ThreadGroup. Developers may use other methods to choose this maximum.
  10. BASE_EXPORT int RecommendedMaxNumberOfThreadsInThreadGroup(
  11. int min,
  12. int max,
  13. double cores_multiplier,
  14. int offset);
  15. } // namespace base
  16. #endif // BASE_TASK_THREAD_POOL_INITIALIZATION_UTIL_H_