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

Side by Side Diff: gpu/command_buffer/service/gpu_tracer.cc

Issue 1207823004: PlatformThreadHandle: remove public id() interface (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: the last two nits 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 unified diff | Download patch
« no previous file with comments | « content/gpu/gpu_watchdog_thread.cc ('k') | media/midi/midi_manager_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/command_buffer/service/gpu_tracer.h" 5 #include "gpu/command_buffer/service/gpu_tracer.h"
6 6
7 #include <deque> 7 #include <deque>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 void TraceOutputter::TraceDevice(GpuTracerSource source, 63 void TraceOutputter::TraceDevice(GpuTracerSource source,
64 const std::string& category, 64 const std::string& category,
65 const std::string& name, 65 const std::string& name,
66 int64 start_time, 66 int64 start_time,
67 int64 end_time) { 67 int64 end_time) {
68 DCHECK(source >= 0 && source < NUM_TRACER_SOURCES); 68 DCHECK(source >= 0 && source < NUM_TRACER_SOURCES);
69 TRACE_EVENT_COPY_BEGIN_WITH_ID_TID_AND_TIMESTAMP2( 69 TRACE_EVENT_COPY_BEGIN_WITH_ID_TID_AND_TIMESTAMP2(
70 TRACE_DISABLED_BY_DEFAULT("gpu.device"), 70 TRACE_DISABLED_BY_DEFAULT("gpu.device"),
71 name.c_str(), 71 name.c_str(),
72 local_trace_device_id_, 72 local_trace_device_id_,
73 named_thread_.thread_id(), 73 named_thread_.GetThreadId(),
74 start_time, 74 start_time,
75 "gl_category", 75 "gl_category",
76 category.c_str(), 76 category.c_str(),
77 "channel", 77 "channel",
78 kGpuTraceSourceNames[source]); 78 kGpuTraceSourceNames[source]);
79 79
80 // Time stamps are inclusive, since the traces are durations we subtract 80 // Time stamps are inclusive, since the traces are durations we subtract
81 // 1 microsecond from the end time to make the trace markers show up cleaner. 81 // 1 microsecond from the end time to make the trace markers show up cleaner.
82 TRACE_EVENT_COPY_END_WITH_ID_TID_AND_TIMESTAMP2( 82 TRACE_EVENT_COPY_END_WITH_ID_TID_AND_TIMESTAMP2(
83 TRACE_DISABLED_BY_DEFAULT("gpu.device"), 83 TRACE_DISABLED_BY_DEFAULT("gpu.device"),
84 name.c_str(), 84 name.c_str(),
85 local_trace_device_id_, 85 local_trace_device_id_,
86 named_thread_.thread_id(), 86 named_thread_.GetThreadId(),
87 end_time - 1, 87 end_time - 1,
88 "gl_category", 88 "gl_category",
89 category.c_str(), 89 category.c_str(),
90 "channel", 90 "channel",
91 kGpuTraceSourceNames[source]); 91 kGpuTraceSourceNames[source]);
92 ++local_trace_device_id_; 92 ++local_trace_device_id_;
93 } 93 }
94 94
95 void TraceOutputter::TraceServiceBegin(GpuTracerSource source, 95 void TraceOutputter::TraceServiceBegin(GpuTracerSource source,
96 const std::string& category, 96 const std::string& category,
(...skipping 330 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 void GPUTracer::IssueProcessTask() { 427 void GPUTracer::IssueProcessTask() {
428 if (finished_traces_.empty() || process_posted_) 428 if (finished_traces_.empty() || process_posted_)
429 return; 429 return;
430 430
431 process_posted_ = true; 431 process_posted_ = true;
432 PostTask(); 432 PostTask();
433 } 433 }
434 434
435 } // namespace gles2 435 } // namespace gles2
436 } // namespace gpu 436 } // namespace gpu
OLDNEW
« no previous file with comments | « content/gpu/gpu_watchdog_thread.cc ('k') | media/midi/midi_manager_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698