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

Unified Diff: content/browser/gpu/gpu_process_host.h

Issue 418733002: Prevent duplicate navigation to debug URLs from Telemetry. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix comment. Created 6 years, 5 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 | « content/browser/gpu/gpu_internals_ui.cc ('k') | content/browser/gpu/gpu_process_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/gpu/gpu_process_host.h
diff --git a/content/browser/gpu/gpu_process_host.h b/content/browser/gpu/gpu_process_host.h
index 76de960a2fbe7cb8ccac60c485896fcffceeb02b..f4c9acb84877d1d556802c47caa60bf9b3d0c8f2 100644
--- a/content/browser/gpu/gpu_process_host.h
+++ b/content/browser/gpu/gpu_process_host.h
@@ -68,6 +68,7 @@ class GpuProcessHost : public BrowserChildProcessHostDelegate,
CreateGpuMemoryBufferCallback;
static bool gpu_enabled() { return gpu_enabled_; }
+ static int gpu_crash_count() { return gpu_crash_count_; }
// Creates a new GpuProcessHost or gets an existing one, resulting in the
// launching of a GPU process if required. Returns null on failure. It
@@ -187,6 +188,9 @@ class GpuProcessHost : public BrowserChildProcessHostDelegate,
void BlockLiveOffscreenContexts();
+ // Update GPU crash counters. Disable GPU if crash limit is reached.
+ void RecordProcessCrash();
+
std::string GetShaderPrefixKey();
// The serial number of the GpuProcessHost / GpuProcessHostUIShim pair.
@@ -226,6 +230,9 @@ class GpuProcessHost : public BrowserChildProcessHostDelegate,
// Time Init started. Used to log total GPU process startup time to UMA.
base::TimeTicks init_start_time_;
+ // Whether this host recorded a GPU crash or not.
+ bool gpu_crash_recorded_;
+
// Master switch for enabling/disabling GPU acceleration for the current
// browser session. It does not change the acceleration settings for
// existing tabs, just the future ones.
@@ -233,6 +240,11 @@ class GpuProcessHost : public BrowserChildProcessHostDelegate,
static bool hardware_gpu_enabled_;
+ static int gpu_crash_count_;
+ static int gpu_recent_crash_count_;
+ static bool crashed_before_;
+ static int swiftshader_crash_count_;
+
scoped_ptr<BrowserChildProcessHostImpl> process_;
// Track the URLs of the pages which have live offscreen contexts,
« no previous file with comments | « content/browser/gpu/gpu_internals_ui.cc ('k') | content/browser/gpu/gpu_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698