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

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

Issue 1188773005: DevTools: fix concurrency problems in DevToolsFrameTraceRecorder (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments addressed Created 5 years, 6 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 | « no previous file | content/browser/devtools/devtools_frame_trace_recorder.h » ('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 870 matching lines...) Expand 10 before | Expand all | Expand 10 after
881 // See also TraceTrackableObject. 881 // See also TraceTrackableObject.
882 #define TRACE_EVENT_OBJECT_CREATED_WITH_ID(category_group, name, id) \ 882 #define TRACE_EVENT_OBJECT_CREATED_WITH_ID(category_group, name, id) \
883 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_CREATE_OBJECT, \ 883 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_CREATE_OBJECT, \
884 category_group, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE) 884 category_group, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE)
885 885
886 #define TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID(category_group, name, id, snapshot) \ 886 #define TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID(category_group, name, id, snapshot) \
887 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_SNAPSHOT_OBJECT, \ 887 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_SNAPSHOT_OBJECT, \
888 category_group, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE,\ 888 category_group, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE,\
889 "snapshot", snapshot) 889 "snapshot", snapshot)
890 890
891 #define TRACE_EVENT_OBJECT_SNAPSHOT_WITH_ID_AND_TIMESTAMP( \
892 category_group, name, id, timestamp, snapshot) \
893 INTERNAL_TRACE_EVENT_ADD_WITH_ID_TID_AND_TIMESTAMP( \
894 TRACE_EVENT_PHASE_SNAPSHOT_OBJECT, category_group, name, \
895 TRACE_ID_DONT_MANGLE(id), \
896 static_cast<int>(base::PlatformThread::CurrentId()), timestamp, \
897 TRACE_EVENT_FLAG_NONE, "snapshot", snapshot)
898
891 #define TRACE_EVENT_OBJECT_DELETED_WITH_ID(category_group, name, id) \ 899 #define TRACE_EVENT_OBJECT_DELETED_WITH_ID(category_group, name, id) \
892 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_DELETE_OBJECT, \ 900 INTERNAL_TRACE_EVENT_ADD_WITH_ID(TRACE_EVENT_PHASE_DELETE_OBJECT, \
893 category_group, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE) 901 category_group, name, TRACE_ID_DONT_MANGLE(id), TRACE_EVENT_FLAG_NONE)
894 902
895 #define INTERNAL_TRACE_EVENT_CATEGORY_GROUP_ENABLED_FOR_RECORDING_MODE() \ 903 #define INTERNAL_TRACE_EVENT_CATEGORY_GROUP_ENABLED_FOR_RECORDING_MODE() \
896 UNLIKELY(*INTERNAL_TRACE_EVENT_UID(category_group_enabled) & \ 904 UNLIKELY(*INTERNAL_TRACE_EVENT_UID(category_group_enabled) & \
897 (base::trace_event::TraceLog::ENABLED_FOR_RECORDING | \ 905 (base::trace_event::TraceLog::ENABLED_FOR_RECORDING | \
898 base::trace_event::TraceLog::ENABLED_FOR_EVENT_CALLBACK | \ 906 base::trace_event::TraceLog::ENABLED_FOR_EVENT_CALLBACK | \
899 base::trace_event::TraceLog::ENABLED_FOR_ETW_EXPORT)) 907 base::trace_event::TraceLog::ENABLED_FOR_ETW_EXPORT))
900 908
(...skipping 807 matching lines...) Expand 10 before | Expand all | Expand 10 after
1708 const char* name_; 1716 const char* name_;
1709 IDType id_; 1717 IDType id_;
1710 1718
1711 DISALLOW_COPY_AND_ASSIGN(TraceScopedTrackableObject); 1719 DISALLOW_COPY_AND_ASSIGN(TraceScopedTrackableObject);
1712 }; 1720 };
1713 1721
1714 } // namespace trace_event 1722 } // namespace trace_event
1715 } // namespace base 1723 } // namespace base
1716 1724
1717 #endif // BASE_TRACE_EVENT_TRACE_EVENT_H_ 1725 #endif // BASE_TRACE_EVENT_TRACE_EVENT_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/devtools/devtools_frame_trace_recorder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698