summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-03 19:12:52 +0000
committerjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-10-03 19:12:52 +0000
commite2bc92bfd8863ee4d9293d6711a516dade843742 (patch)
treea3f84fd370c949efc42e4ce897dde2f2fe63665a
parentbf124375ab566296664d22bbda10ae20988f0ad0 (diff)
downloadchromium_src-e2bc92bfd8863ee4d9293d6711a516dade843742.zip
chromium_src-e2bc92bfd8863ee4d9293d6711a516dade843742.tar.gz
chromium_src-e2bc92bfd8863ee4d9293d6711a516dade843742.tar.bz2
Histogram display refresh rate on windows
This reports every time wequery the display mode, which is quite frequent, but since the display rate can change over time this will have the effect of weighting each refresh rate by overall usage instead of by pure user count. BUG=262437 (this doesn't fix the bug, but makes it easier to analyze the effects) R=isherman@chromium.org, jbauman@chromium.org, kbr@chromium.org Review URL: https://codereview.chromium.org/25705005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@226811 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--tools/metrics/histograms/histograms.xml7
-rw-r--r--ui/surface/accelerated_surface_win.cc4
2 files changed, 11 insertions, 0 deletions
diff --git a/tools/metrics/histograms/histograms.xml b/tools/metrics/histograms/histograms.xml
index 880dfb6..b6258d6 100644
--- a/tools/metrics/histograms/histograms.xml
+++ b/tools/metrics/histograms/histograms.xml
@@ -4874,6 +4874,13 @@ other types of suffix sets.
<summary>Events in Google Now component extension.</summary>
</histogram>
+<histogram name="GPU.AcceleratedSurfaceRefreshRate" units="hz">
+ <summary>
+ Refresh rate of the display in Hz. This is recorded every time we present a
+ frame.
+ </summary>
+</histogram>
+
<histogram name="History.DeleteFTSIndexDatabases">
<summary>
Count of &quot;History Index *&quot; databases deleted. These databases
diff --git a/ui/surface/accelerated_surface_win.cc b/ui/surface/accelerated_surface_win.cc
index 15d78c0..9f184e3 100644
--- a/ui/surface/accelerated_surface_win.cc
+++ b/ui/surface/accelerated_surface_win.cc
@@ -14,6 +14,7 @@
#include "base/debug/trace_event.h"
#include "base/files/file_path.h"
#include "base/lazy_instance.h"
+#include "base/metrics/histogram.h"
#include "base/memory/scoped_ptr.h"
#include "base/message_loop/message_loop_proxy.h"
#include "base/scoped_native_library.h"
@@ -864,6 +865,9 @@ void AcceleratedPresenter::DoPresentAndAcknowledge(
return;
}
+ UMA_HISTOGRAM_CUSTOM_COUNTS("GPU.AcceleratedSurfaceRefreshRate",
+ display_mode.RefreshRate, 0, 121, 122);
+
// I can't figure out how to determine how many scanlines are in the
// vertical blank so clamp it such that scanline / height <= 1.
int clamped_scanline = std::min(raster_status.ScanLine, display_mode.Height);