OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "base/trace_event/trace_event_etw_export_win.h" | 5 #include "base/trace_event/trace_event_etw_export_win.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include "base/command_line.h" | 9 #include "base/command_line.h" |
8 #include "base/logging.h" | 10 #include "base/logging.h" |
9 #include "base/memory/singleton.h" | 11 #include "base/memory/singleton.h" |
10 #include "base/strings/string_tokenizer.h" | 12 #include "base/strings/string_tokenizer.h" |
11 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
12 #include "base/threading/platform_thread.h" | 14 #include "base/threading/platform_thread.h" |
13 #include "base/trace_event/trace_event.h" | 15 #include "base/trace_event/trace_event.h" |
14 #include "base/trace_event/trace_event_impl.h" | 16 #include "base/trace_event/trace_event_impl.h" |
15 | 17 |
16 // The GetProcAddress technique is borrowed from | 18 // The GetProcAddress technique is borrowed from |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 "renderer.scheduler", // 0x100 | 85 "renderer.scheduler", // 0x100 |
84 "toplevel", // 0x200 | 86 "toplevel", // 0x200 |
85 "v8", // 0x400 | 87 "v8", // 0x400 |
86 "disabled-by-default-cc.debug", // 0x800 | 88 "disabled-by-default-cc.debug", // 0x800 |
87 "disabled-by-default-cc.debug.picture", // 0x1000 | 89 "disabled-by-default-cc.debug.picture", // 0x1000 |
88 "disabled-by-default-toplevel.flow", // 0x2000 | 90 "disabled-by-default-toplevel.flow", // 0x2000 |
89 "startup"}; // 0x4000 | 91 "startup"}; // 0x4000 |
90 const char kOtherEventsGroupName[] = "__OTHER_EVENTS"; // 0x2000000000000000 | 92 const char kOtherEventsGroupName[] = "__OTHER_EVENTS"; // 0x2000000000000000 |
91 const char kDisabledOtherEventsGroupName[] = | 93 const char kDisabledOtherEventsGroupName[] = |
92 "__DISABLED_OTHER_EVENTS"; // 0x4000000000000000 | 94 "__DISABLED_OTHER_EVENTS"; // 0x4000000000000000 |
93 const uint64 kOtherEventsKeywordBit = 1ULL << 61; | 95 const uint64_t kOtherEventsKeywordBit = 1ULL << 61; |
94 const uint64 kDisabledOtherEventsKeywordBit = 1ULL << 62; | 96 const uint64_t kDisabledOtherEventsKeywordBit = 1ULL << 62; |
95 const size_t kNumberOfCategories = ARRAYSIZE(kFilteredEventGroupNames) + 2U; | 97 const size_t kNumberOfCategories = ARRAYSIZE(kFilteredEventGroupNames) + 2U; |
96 | 98 |
97 } // namespace | 99 } // namespace |
98 | 100 |
99 // Redirector function for EventRegister. Called by macros in | 101 // Redirector function for EventRegister. Called by macros in |
100 // chrome_events_win.h | 102 // chrome_events_win.h |
101 ULONG EVNTAPI EventRegister(LPCGUID ProviderId, | 103 ULONG EVNTAPI EventRegister(LPCGUID ProviderId, |
102 PENABLECALLBACK EnableCallback, | 104 PENABLECALLBACK EnableCallback, |
103 PVOID CallbackContext, | 105 PVOID CallbackContext, |
104 PREGHANDLE RegHandle) { | 106 PREGHANDLE RegHandle) { |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
427 // static | 429 // static |
428 void TraceEventETWExport::UpdateETWKeyword() { | 430 void TraceEventETWExport::UpdateETWKeyword() { |
429 if (!IsETWExportEnabled()) | 431 if (!IsETWExportEnabled()) |
430 return; | 432 return; |
431 auto* instance = GetInstance(); | 433 auto* instance = GetInstance(); |
432 DCHECK(instance); | 434 DCHECK(instance); |
433 instance->UpdateEnabledCategories(); | 435 instance->UpdateEnabledCategories(); |
434 } | 436 } |
435 } // namespace trace_event | 437 } // namespace trace_event |
436 } // namespace base | 438 } // namespace base |
OLD | NEW |