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

Unified Diff: gpu/command_buffer/service/shader_manager.h

Issue 2378583003: Ping watchdog thread during GpuChannel destruction (Closed)
Patch Set: feedback Created 4 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
Index: gpu/command_buffer/service/shader_manager.h
diff --git a/gpu/command_buffer/service/shader_manager.h b/gpu/command_buffer/service/shader_manager.h
index 2e828e66f1efdd6bbf7ab0314055ff867fa36825..1aec8df1aa563ac029d44642f2b29847f2a6491d 100644
--- a/gpu/command_buffer/service/shader_manager.h
+++ b/gpu/command_buffer/service/shader_manager.h
@@ -18,6 +18,8 @@
namespace gpu {
namespace gles2 {
+class ProgressReporter;
+
enum ShaderVariableBaseType {
SHADER_VARIABLE_INT = 0x01,
SHADER_VARIABLE_UINT = 0x02,
@@ -268,7 +270,7 @@ class GPU_EXPORT Shader : public base::RefCounted<Shader> {
// need to be shared by multiple GLES2Decoders.
class GPU_EXPORT ShaderManager {
public:
- ShaderManager();
+ ShaderManager(ProgressReporter* progress_reporter);
~ShaderManager();
// Must call before destruction.
@@ -308,6 +310,10 @@ class GPU_EXPORT ShaderManager {
void RemoveShader(Shader* shader);
+ // Used to notify the watchdog thread of progress during destruction,
+ // preventing time-outs when destruction takes a long time.
+ ProgressReporter* progress_reporter_;
+
DISALLOW_COPY_AND_ASSIGN(ShaderManager);
};

Powered by Google App Engine
This is Rietveld 408576698