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

Side by Side Diff: Source/core/inspector/TimelineTraceEventProcessor.h

Issue 46663010: DevTools: Show GPU utilization bar on timeline (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Tune PID to hue magic const Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 void onRasterTaskBegin(const TraceEvent&); 212 void onRasterTaskBegin(const TraceEvent&);
213 void onRasterTaskEnd(const TraceEvent&); 213 void onRasterTaskEnd(const TraceEvent&);
214 void onPaint(const TraceEvent&); 214 void onPaint(const TraceEvent&);
215 void onImageDecodeTaskBegin(const TraceEvent&); 215 void onImageDecodeTaskBegin(const TraceEvent&);
216 void onImageDecodeTaskEnd(const TraceEvent&); 216 void onImageDecodeTaskEnd(const TraceEvent&);
217 void onImageDecodeBegin(const TraceEvent&); 217 void onImageDecodeBegin(const TraceEvent&);
218 void onImageDecodeEnd(const TraceEvent&); 218 void onImageDecodeEnd(const TraceEvent&);
219 void onLayerDeleted(const TraceEvent&); 219 void onLayerDeleted(const TraceEvent&);
220 void onDrawLazyPixelRef(const TraceEvent&); 220 void onDrawLazyPixelRef(const TraceEvent&);
221 void onLazyPixelRefDeleted(const TraceEvent&); 221 void onLazyPixelRefDeleted(const TraceEvent&);
222 void onGPUTaskBegin(const TraceEvent&);
223 void onGPUTaskEnd(const TraceEvent&);
222 224
223 WeakPtr<InspectorTimelineAgent> m_timelineAgent; 225 WeakPtr<InspectorTimelineAgent> m_timelineAgent;
224 TimelineTimeConverter m_timeConverter; 226 TimelineTimeConverter m_timeConverter;
225 InspectorClient* m_inspectorClient; 227 InspectorClient* m_inspectorClient;
226 unsigned long long m_pageId; 228 unsigned long long m_pageId;
227 int m_layerTreeId; 229 int m_layerTreeId;
228 230
229 typedef HashMap<std::pair<String, int>, TraceEventHandler> HandlersMap; 231 typedef HashMap<std::pair<String, int>, TraceEventHandler> HandlersMap;
230 HandlersMap m_handlersByType; 232 HandlersMap m_handlersByType;
231 Mutex m_backgroundEventsMutex; 233 Mutex m_backgroundEventsMutex;
232 Vector<TraceEvent> m_backgroundEvents; 234 Vector<TraceEvent> m_backgroundEvents;
233 double m_lastEventProcessingTime; 235 double m_lastEventProcessingTime;
234 bool m_processEventsTaskInFlight; 236 bool m_processEventsTaskInFlight;
235 237
236 typedef HashMap<ThreadIdentifier, TimelineThreadState> ThreadStateMap; 238 typedef HashMap<ThreadIdentifier, TimelineThreadState> ThreadStateMap;
237 ThreadStateMap m_threadStates; 239 ThreadStateMap m_threadStates;
238 240
239 HashMap<unsigned long long, long long> m_layerToNodeMap; 241 HashMap<unsigned long long, long long> m_layerToNodeMap;
240 unsigned long long m_layerId; 242 unsigned long long m_layerId;
241 double m_paintSetupStart; 243 double m_paintSetupStart;
242 double m_paintSetupEnd; 244 double m_paintSetupEnd;
245 RefPtr<JSONObject> m_gpuTask;
243 246
244 struct ImageInfo { 247 struct ImageInfo {
245 int backendNodeId; 248 int backendNodeId;
246 String url; 249 String url;
247 250
248 ImageInfo() { } 251 ImageInfo() { }
249 ImageInfo(int backendNodeId, String url) : backendNodeId(backendNodeId), url(url) { } 252 ImageInfo(int backendNodeId, String url) : backendNodeId(backendNodeId), url(url) { }
250 }; 253 };
251 typedef HashMap<unsigned long long, ImageInfo> PixelRefToImageInfoMap; 254 typedef HashMap<unsigned long long, ImageInfo> PixelRefToImageInfoMap;
252 PixelRefToImageInfoMap m_pixelRefToImageInfo; 255 PixelRefToImageInfoMap m_pixelRefToImageInfo;
253 }; 256 };
254 257
255 } // namespace WebCore 258 } // namespace WebCore
256 259
257 #endif // !defined(TimelineTraceEventProcessor_h) 260 #endif // !defined(TimelineTraceEventProcessor_h)
OLDNEW
« no previous file with comments | « Source/core/inspector/TimelineRecordFactory.cpp ('k') | Source/core/inspector/TimelineTraceEventProcessor.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698