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

Unified Diff: base/trace_event/trace_log.cc

Issue 1183633003: cross gn Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: slightly smaller diff Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/trace_event/trace_event_etw_export_win.cc ('k') | build/config/BUILDCONFIG.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event/trace_log.cc
diff --git a/base/trace_event/trace_log.cc b/base/trace_event/trace_log.cc
index db1db2575634fd83ab493e91cce173231fcce972..2ee4f18b912ff4475d774ac34fc86c5f24b38a26 100644
--- a/base/trace_event/trace_log.cc
+++ b/base/trace_event/trace_log.cc
@@ -473,10 +473,10 @@ void TraceLog::UpdateCategoryGroupEnabledFlag(size_t category_index) {
}
#if defined(OS_WIN)
- if (base::trace_event::TraceEventETWExport::IsCategoryGroupEnabled(
- category_group)) {
- enabled_flag |= ENABLED_FOR_ETW_EXPORT;
- }
+ //if (base::trace_event::TraceEventETWExport::IsCategoryGroupEnabled(
+ //category_group)) {
+ //enabled_flag |= ENABLED_FOR_ETW_EXPORT;
+ //}
#endif
// TODO(primiano): this is a temporary workaround for catapult:#2341,
@@ -1269,10 +1269,10 @@ TraceEventHandle TraceLog::AddTraceEventWithThreadIdAndTimestamp(
#if defined(OS_WIN)
// This is done sooner rather than later, to avoid creating the event and
// acquiring the lock, which is not needed for ETW as it's already threadsafe.
- if (*category_group_enabled & ENABLED_FOR_ETW_EXPORT)
- TraceEventETWExport::AddEvent(phase, category_group_enabled, name, id,
- num_args, arg_names, arg_types, arg_values,
- convertable_values);
+ //if (*category_group_enabled & ENABLED_FOR_ETW_EXPORT)
+ //TraceEventETWExport::AddEvent(phase, category_group_enabled, name, id,
+ //num_args, arg_names, arg_types, arg_values,
+ //convertable_values);
#endif // OS_WIN
std::string console_message;
@@ -1461,8 +1461,8 @@ void TraceLog::UpdateTraceEventDuration(
#if defined(OS_WIN)
// Generate an ETW event that marks the end of a complete event.
- if (category_group_enabled_local & ENABLED_FOR_ETW_EXPORT)
- TraceEventETWExport::AddCompleteEndEvent(name);
+ //if (category_group_enabled_local & ENABLED_FOR_ETW_EXPORT)
+ //TraceEventETWExport::AddCompleteEndEvent(name);
#endif // OS_WIN
std::string console_message;
@@ -1718,20 +1718,20 @@ TraceBuffer* TraceLog::CreateTraceBuffer() {
#if defined(OS_WIN)
void TraceLog::UpdateETWCategoryGroupEnabledFlags() {
- AutoLock lock(lock_);
- size_t category_index = base::subtle::NoBarrier_Load(&g_category_index);
- // Go through each category and set/clear the ETW bit depending on whether the
- // category is enabled.
- for (size_t i = 0; i < category_index; i++) {
- const char* category_group = g_category_groups[i];
- DCHECK(category_group);
- if (base::trace_event::TraceEventETWExport::IsCategoryGroupEnabled(
- category_group)) {
- g_category_group_enabled[i] |= ENABLED_FOR_ETW_EXPORT;
- } else {
- g_category_group_enabled[i] &= ~ENABLED_FOR_ETW_EXPORT;
- }
- }
+ //AutoLock lock(lock_);
+ //size_t category_index = base::subtle::NoBarrier_Load(&g_category_index);
+ //// Go through each category and set/clear the ETW bit depending on whether the
+ //// category is enabled.
+ //for (size_t i = 0; i < category_index; i++) {
+ // const char* category_group = g_category_groups[i];
+ // DCHECK(category_group);
+ // if (base::trace_event::TraceEventETWExport::IsCategoryGroupEnabled(
+ // category_group)) {
+ // g_category_group_enabled[i] |= ENABLED_FOR_ETW_EXPORT;
+ // } else {
+ // g_category_group_enabled[i] &= ~ENABLED_FOR_ETW_EXPORT;
+ // }
+ //}
}
#endif // defined(OS_WIN)
« no previous file with comments | « base/trace_event/trace_event_etw_export_win.cc ('k') | build/config/BUILDCONFIG.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698