Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1660)

Unified Diff: chrome/browser/render_widget_host_view_win.cc

Issue 7638: Construct a field trial to see if HIGH or MEDIUM memory model "works better"... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/browser_trial.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/render_widget_host_view_win.cc
===================================================================
--- chrome/browser/render_widget_host_view_win.cc (revision 3603)
+++ chrome/browser/render_widget_host_view_win.cc (working copy)
@@ -11,6 +11,7 @@
#include "base/win_util.h"
#include "chrome/browser/browser_accessibility.h"
#include "chrome/browser/browser_accessibility_manager.h"
+#include "chrome/browser/browser_trial.h"
#include "chrome/browser/render_process_host.h"
// TODO(beng): (Cleanup) we should not need to include this file... see comment
// in |DidBecomeSelected|.
@@ -433,7 +434,21 @@
}
if (!whiteout_start_time_.is_null()) {
TimeDelta whiteout_duration = TimeTicks::Now() - whiteout_start_time_;
- UMA_HISTOGRAM_TIMES(L"MPArch.RWHH_WhiteoutDuration", whiteout_duration);
+
+ // If field trial is active, report results in special histogram.
+ static scoped_refptr<FieldTrial> trial(
+ FieldTrialList::Find(BrowserTrial::kMemoryModelFieldTrial));
+ if (trial.get()) {
+ if (trial->boolean_value())
+ UMA_HISTOGRAM_TIMES(L"MPArch.RWHH_WhiteoutDuration_trial_high_memory",
+ whiteout_duration);
+ else
+ UMA_HISTOGRAM_TIMES(L"MPArch.RWHH_WhiteoutDuration_trial_med_memory",
+ whiteout_duration);
+ } else {
+ UMA_HISTOGRAM_TIMES(L"MPArch.RWHH_WhiteoutDuration", whiteout_duration);
+ }
+
// Reset the start time to 0 so that we start recording again the next
// time the backing store is NULL...
whiteout_start_time_ = TimeTicks();
« no previous file with comments | « chrome/browser/browser_trial.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698