| Index: components/task_scheduler_util/common/variations_util.h
|
| diff --git a/components/task_scheduler_util/common/variations_util.h b/components/task_scheduler_util/common/variations_util.h
|
| index f92b29770084ae9117d3cbebe36b907fb98a86cf..314f16c52bbad3b5ca689ed1b3ff2b4ff0d0efd2 100644
|
| --- a/components/task_scheduler_util/common/variations_util.h
|
| +++ b/components/task_scheduler_util/common/variations_util.h
|
| @@ -7,13 +7,11 @@
|
|
|
| #include <map>
|
| #include <string>
|
| -#include <vector>
|
|
|
| #include "build/build_config.h"
|
| #include "base/strings/string_piece.h"
|
| #include "base/task_scheduler/scheduler_worker_params.h"
|
| #include "base/task_scheduler/scheduler_worker_pool_params.h"
|
| -#include "base/threading/platform_thread.h"
|
|
|
| namespace base {
|
| class CommandLine;
|
| @@ -21,34 +19,23 @@ class CommandLine;
|
|
|
| namespace task_scheduler_util {
|
|
|
| -class SchedulerImmutableWorkerPoolParams {
|
| - public:
|
| - SchedulerImmutableWorkerPoolParams(
|
| - const char* name,
|
| - base::ThreadPriority priority_hint,
|
| - base::SchedulerBackwardCompatibility backward_compatibility =
|
| - base::SchedulerBackwardCompatibility::DISABLED);
|
| -
|
| - const char* name() const { return name_; }
|
| - base::ThreadPriority priority_hint() const { return priority_hint_; }
|
| - base::SchedulerBackwardCompatibility backward_compatibility() const {
|
| - return backward_compatibility_;
|
| - }
|
| -
|
| - private:
|
| - const char* name_;
|
| - base::ThreadPriority priority_hint_;
|
| - base::SchedulerBackwardCompatibility backward_compatibility_;
|
| -};
|
| -
|
| -// Returns a SchedulerWorkerPoolParams vector to initialize pools specified in
|
| -// |constant_worker_pool_params_vector|. SchedulerWorkerPoolParams members
|
| -// without a counterpart in SchedulerImmutableWorkerPoolParams are initialized
|
| -// based of |variation_params|. Returns an empty vector on failure.
|
| -std::vector<base::SchedulerWorkerPoolParams> GetWorkerPoolParams(
|
| - const std::vector<SchedulerImmutableWorkerPoolParams>&
|
| - constant_worker_pool_params_vector,
|
| - const std::map<std::string, std::string>& variation_params);
|
| +// Builds a SchedulerWorkerPoolParams from |pool_descriptor| and
|
| +// |backward_compatibility|. Returns an invalid SchedulerWorkerPoolParams on
|
| +// failure.
|
| +//
|
| +// |pool_descriptor| is a semi-colon separated value string with the following
|
| +// items:
|
| +// 0. Minimum Thread Count (int)
|
| +// 1. Maximum Thread Count (int)
|
| +// 2. Thread Count Multiplier (double)
|
| +// 3. Thread Count Offset (int)
|
| +// 4. Detach Time in Milliseconds (int)
|
| +// 5. Standby Thread Policy (string)
|
| +// Additional values may appear as necessary and will be ignored.
|
| +base::SchedulerWorkerPoolParams StringToVariableWorkerPoolParams(
|
| + const base::StringPiece pool_descriptor,
|
| + base::SchedulerBackwardCompatibility backward_compatibility =
|
| + base::SchedulerBackwardCompatibility::DISABLED);
|
|
|
| #if !defined(OS_IOS)
|
| // Serializes variation params from the BrowserScheduler field trial whose key
|
|
|