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

Side by Side Diff: base/debug/trace_event.h

Issue 23926013: gpu: Record GL state to trace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix build failure. Created 7 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder.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 // This header file defines the set of trace_event macros without specifying 5 // This header file defines the set of trace_event macros without specifying
6 // how the events actually get collected and stored. If you need to expose trace 6 // how the events actually get collected and stored. If you need to expose trace
7 // events to some other universe, you can copy-and-paste this file as well as 7 // events to some other universe, you can copy-and-paste this file as well as
8 // trace_event.h, modifying the macros contained there as necessary for the 8 // trace_event.h, modifying the macros contained there as necessary for the
9 // target platform. The end result is that multiple libraries can funnel events 9 // target platform. The end result is that multiple libraries can funnel events
10 // through to a shared trace event collector. 10 // through to a shared trace event collector.
(...skipping 949 matching lines...) Expand 10 before | Expand all | Expand 10 after
960 const int kZeroNumArgs = 0; 960 const int kZeroNumArgs = 0;
961 const unsigned long long kNoEventId = 0; 961 const unsigned long long kNoEventId = 0;
962 962
963 // TraceID encapsulates an ID that can either be an integer or pointer. Pointers 963 // TraceID encapsulates an ID that can either be an integer or pointer. Pointers
964 // are by default mangled with the Process ID so that they are unlikely to 964 // are by default mangled with the Process ID so that they are unlikely to
965 // collide when the same pointer is used on different processes. 965 // collide when the same pointer is used on different processes.
966 class TraceID { 966 class TraceID {
967 public: 967 public:
968 class DontMangle { 968 class DontMangle {
969 public: 969 public:
970 explicit DontMangle(void* id) 970 explicit DontMangle(const void* id)
971 : data_(static_cast<unsigned long long>( 971 : data_(static_cast<unsigned long long>(
972 reinterpret_cast<unsigned long>(id))) {} 972 reinterpret_cast<unsigned long>(id))) {}
973 explicit DontMangle(unsigned long long id) : data_(id) {} 973 explicit DontMangle(unsigned long long id) : data_(id) {}
974 explicit DontMangle(unsigned long id) : data_(id) {} 974 explicit DontMangle(unsigned long id) : data_(id) {}
975 explicit DontMangle(unsigned int id) : data_(id) {} 975 explicit DontMangle(unsigned int id) : data_(id) {}
976 explicit DontMangle(unsigned short id) : data_(id) {} 976 explicit DontMangle(unsigned short id) : data_(id) {}
977 explicit DontMangle(unsigned char id) : data_(id) {} 977 explicit DontMangle(unsigned char id) : data_(id) {}
978 explicit DontMangle(long long id) 978 explicit DontMangle(long long id)
979 : data_(static_cast<unsigned long long>(id)) {} 979 : data_(static_cast<unsigned long long>(id)) {}
980 explicit DontMangle(long id) 980 explicit DontMangle(long id)
(...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after
1541 const char* name_; 1541 const char* name_;
1542 IDType id_; 1542 IDType id_;
1543 1543
1544 DISALLOW_COPY_AND_ASSIGN(TraceScopedTrackableObject); 1544 DISALLOW_COPY_AND_ASSIGN(TraceScopedTrackableObject);
1545 }; 1545 };
1546 1546
1547 } // namespace debug 1547 } // namespace debug
1548 } // namespace base 1548 } // namespace base
1549 1549
1550 #endif /* BASE_DEBUG_TRACE_EVENT_H_ */ 1550 #endif /* BASE_DEBUG_TRACE_EVENT_H_ */
OLDNEW
« no previous file with comments | « no previous file | gpu/command_buffer/service/gles2_cmd_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698