| Index: components/scheduler/renderer/task_time_reporter.h
|
| diff --git a/components/scheduler/renderer/task_time_reporter.h b/components/scheduler/renderer/task_time_reporter.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..0efaa8f674027a81a7c8407a24000cfdef903d7c
|
| --- /dev/null
|
| +++ b/components/scheduler/renderer/task_time_reporter.h
|
| @@ -0,0 +1,26 @@
|
| +// Copyright 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef COMPONENTS_SCHEDULER_RENDERER_TASK_TIME_REPORTER_H_
|
| +#define COMPONENTS_SCHEDULER_RENDERER_TASK_TIME_REPORTER_H_
|
| +
|
| +#include "base/time/time.h"
|
| +#include "components/scheduler/scheduler_export.h"
|
| +
|
| +namespace scheduler {
|
| +
|
| +// Reports each task duration in a histogram. The histogram ranges from 1
|
| +// microsecond ~ 1 second with 50 bins. All tasks longer than 1 second will be
|
| +// put into the same bin.
|
| +class SCHEDULER_EXPORT TaskTimeReporter {
|
| + public:
|
| + TaskTimeReporter();
|
| + ~TaskTimeReporter();
|
| + void ReportTaskTime(base::TimeDelta duration);
|
| +
|
| + DISALLOW_COPY_AND_ASSIGN(TaskTimeReporter);
|
| +};
|
| +}
|
| +
|
| +#endif // COMPONENTS_SCHEDULER_RENDERER_TASK_TIME_REPORTER_H_
|
|
|