Index: content/browser/power_profiler/power_profiler_service.cc |
diff --git a/content/browser/power_profiler/power_profiler_service.cc b/content/browser/power_profiler/power_profiler_service.cc |
index bd44429bea6be0a93451d89b5dff483e258fa205..951034c3918125a81e45b7f18ab92bb12ea33596 100644 |
--- a/content/browser/power_profiler/power_profiler_service.cc |
+++ b/content/browser/power_profiler/power_profiler_service.cc |
@@ -9,26 +9,17 @@ |
#include "base/threading/sequenced_worker_pool.h" |
#include "content/public/browser/browser_thread.h" |
-namespace { |
- |
-// Default sampling period, as recommended by Intel Power Gadget. |
-// Section 3.1 of http://software.intel.com/en-us/blogs/2013/10/03/using-the-intel-power-gadget-api-on-windows |
-const int kDefaultSamplePeriodMs = 50; |
- |
-} // namespace |
- |
namespace content { |
PowerProfilerService::PowerProfilerService() |
: status_(UNINITIALIZED), |
- sample_period_(base::TimeDelta::FromMilliseconds(kDefaultSamplePeriodMs)), |
data_provider_(PowerDataProvider::Create()) { |
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
// No provider supported for current platform. |
if (!data_provider_.get()) |
return; |
- |
+ sample_period_ = data_provider_->GetSamplingRate(); |
status_ = INITIALIZED; |
task_runner_ = BrowserThread::GetBlockingPool()->GetSequencedTaskRunner( |
BrowserThread::GetBlockingPool()->GetSequenceToken()); |