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

Unified Diff: content/common/gpu/gpu_command_buffer_stub.cc

Issue 1256613002: Add tracing for GL texture objects (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@browser_process_id
Patch Set: Created 5 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
Index: content/common/gpu/gpu_command_buffer_stub.cc
diff --git a/content/common/gpu/gpu_command_buffer_stub.cc b/content/common/gpu/gpu_command_buffer_stub.cc
index c321416ee8f97a02c46ae5494537d0f573f21fb9..13853a880095df75e50708d678a7833d34eadb2c 100644
--- a/content/common/gpu/gpu_command_buffer_stub.cc
+++ b/content/common/gpu/gpu_command_buffer_stub.cc
@@ -64,10 +64,12 @@ namespace {
// ContextGroup's memory type managers and the GpuMemoryManager class.
class GpuCommandBufferMemoryTracker : public gpu::gles2::MemoryTracker {
public:
- explicit GpuCommandBufferMemoryTracker(GpuChannel* channel) :
- tracking_group_(channel->gpu_channel_manager()->gpu_memory_manager()->
- CreateTrackingGroup(channel->renderer_pid(), this)) {
- }
+ explicit GpuCommandBufferMemoryTracker(GpuChannel* channel)
+ : tracking_group_(
+ channel->gpu_channel_manager()
+ ->gpu_memory_manager()
+ ->CreateTrackingGroup(channel->renderer_pid(), this)),
+ client_tracing_id_(channel->client_tracing_id()) {}
void TrackMemoryAllocatedChange(
size_t old_size,
@@ -81,9 +83,12 @@ class GpuCommandBufferMemoryTracker : public gpu::gles2::MemoryTracker {
return tracking_group_->EnsureGPUMemoryAvailable(size_needed);
};
+ uint64_t ClientTracingId() override { return client_tracing_id_; }
+
private:
~GpuCommandBufferMemoryTracker() override {}
scoped_ptr<GpuMemoryTrackingGroup> tracking_group_;
+ uint64_t client_tracing_id_;
DISALLOW_COPY_AND_ASSIGN(GpuCommandBufferMemoryTracker);
};

Powered by Google App Engine
This is Rietveld 408576698