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

Unified Diff: gpu/ipc/in_process_command_buffer.cc

Issue 2814583002: Service/ClientDiscardableManager (Closed)
Patch Set: feeedback Created 3 years, 7 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/ipc/in_process_command_buffer.cc
diff --git a/gpu/ipc/in_process_command_buffer.cc b/gpu/ipc/in_process_command_buffer.cc
index cba5695f324e095d952efe8fca8ff2d011c89b13..a7791817da830275c803a2a9414cc05f2cd7a3f0 100644
--- a/gpu/ipc/in_process_command_buffer.cc
+++ b/gpu/ipc/in_process_command_buffer.cc
@@ -38,6 +38,7 @@
#include "gpu/command_buffer/service/memory_program_cache.h"
#include "gpu/command_buffer/service/memory_tracking.h"
#include "gpu/command_buffer/service/query_manager.h"
+#include "gpu/command_buffer/service/service_discardable_manager.h"
#include "gpu/command_buffer/service/service_utils.h"
#include "gpu/command_buffer/service/sync_point_manager.h"
#include "gpu/command_buffer/service/transfer_buffer_manager.h"
@@ -308,6 +309,7 @@ bool InProcessCommandBuffer::InitializeOnGpuThread(
scoped_refptr<gles2::FeatureInfo> feature_info =
new gles2::FeatureInfo(service_->gpu_driver_bug_workarounds());
+ discardable_manager_.reset(new ServiceDiscardableManager());
context_group_ =
params.context_group
? params.context_group->decoder_->GetContextGroup()
@@ -315,7 +317,8 @@ bool InProcessCommandBuffer::InitializeOnGpuThread(
service_->gpu_preferences(), service_->mailbox_manager(), NULL,
service_->shader_translator_cache(),
service_->framebuffer_completeness_cache(), feature_info,
- bind_generates_resource, nullptr, nullptr, GpuFeatureInfo());
+ bind_generates_resource, nullptr, nullptr, GpuFeatureInfo(),
+ discardable_manager_.get());
piman 2017/05/10 22:13:59 So, it could be that the context_group outlives th
ericrk 2017/05/12 16:22:12 Ah, yes, forgot about this (I think this is why I
decoder_.reset(gles2::GLES2Decoder::Create(context_group_.get()));

Powered by Google App Engine
This is Rietveld 408576698