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

Issue 2323483005: [tracing] Add filtering mode in TraceLog (Closed)

Created:
4 years, 3 months ago by ssid
Modified:
4 years, 2 months ago
CC:
chromium-reviews, tracing+reviews_chromium.org, wfh+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[tracing] Add filtering mode in TraceLog This CL does: 1. Add new FILTERING_MODE in TraceLog. TraceLog can be enabled and disabled with FILTERING_MODE independently from RECORDING MODE. The TraceLog::mode_ is a bitmap. 2. In FILTERING_MODE trace buffer is not created and trace events are passed to filters but not recorded. 3. The filters can be added only by FILTERING_MODE and trace config. Once enabled, the filters cannot be changed until the filters are disabled. 4. HeapProfilerFilter is enabled using FILTERING_MODE when "--enable-heap-profiling" flag is passed, so that pseudo stack is recorded for all allocations, irrespective of tracing. BUG=625170 Committed: https://crrev.com/20d2eeed2c735fbf018b9a9dffa810d51a25940d Cr-Commit-Position: refs/heads/master@{#425156}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Fixes. #

Total comments: 1

Patch Set 3 : Fixes. #

Total comments: 20

Patch Set 4 : SetEnabled takes a bitmap. #

Total comments: 37

Patch Set 5 : Primiano's comments. #

Total comments: 16

Patch Set 6 : Nit. #

Total comments: 4

Patch Set 7 : Add a comment, and renames. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+314 lines, -93 lines) Patch
M base/trace_event/heap_profiler_allocation_context_tracker.cc View 1 2 3 1 chunk +3 lines, -1 line 0 comments Download
M base/trace_event/heap_profiler_allocation_context_tracker_unittest.cc View 1 2 3 4 2 chunks +15 lines, -3 lines 0 comments Download
M base/trace_event/memory_dump_manager.cc View 1 2 3 4 5 6 1 chunk +24 lines, -1 line 0 comments Download
M base/trace_event/trace_config.h View 1 2 3 4 5 3 chunks +6 lines, -1 line 0 comments Download
M base/trace_event/trace_config.cc View 1 2 3 4 5 6 chunks +19 lines, -24 lines 0 comments Download
M base/trace_event/trace_event_unittest.cc View 1 2 3 4 6 chunks +123 lines, -5 lines 0 comments Download
M base/trace_event/trace_log.h View 1 2 3 4 5 6 5 chunks +33 lines, -13 lines 0 comments Download
M base/trace_event/trace_log.cc View 1 2 3 4 5 6 10 chunks +91 lines, -45 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 72 (50 generated)
ssid
Look at this after https://codereview.chromium.org/2316403002/. I would like to do this change. But, I understand ...
4 years, 3 months ago (2016-09-08 22:28:45 UTC) #2
ssid
made changes as discussed, ptal, thanks.
4 years, 3 months ago (2016-09-21 04:00:23 UTC) #5
oystein (OOO til 10th of July)
This is looking much better to me! A couple of small comments, but I'd like ...
4 years, 3 months ago (2016-09-22 19:21:07 UTC) #20
ssid
https://codereview.chromium.org/2323483005/diff/80001/base/trace_event/trace_log.h File base/trace_event/trace_log.h (right): https://codereview.chromium.org/2323483005/diff/80001/base/trace_event/trace_log.h#newcode99 base/trace_event/trace_log.h:99: bool IsEnabled() { return mode_ & RECORDING_MODE; } On ...
4 years, 3 months ago (2016-09-22 19:37:44 UTC) #22
oystein (OOO til 10th of July)
Great! lgtm pending primiano sanity-checking. https://codereview.chromium.org/2323483005/diff/80001/base/trace_event/trace_log.h File base/trace_event/trace_log.h (right): https://codereview.chromium.org/2323483005/diff/80001/base/trace_event/trace_log.h#newcode99 base/trace_event/trace_log.h:99: bool IsEnabled() { return ...
4 years, 3 months ago (2016-09-22 20:16:43 UTC) #23
Primiano Tucci (use gerrit)
ok conceptually the two independent modes make sense. I have a bunch of questions and ...
4 years, 2 months ago (2016-09-23 18:34:32 UTC) #24
ssid
Mainly 2 comments: Filters cannot be added when filtering is enabled. One improvement i could ...
4 years, 2 months ago (2016-09-26 18:39:54 UTC) #25
ssid
ptal, thanks
4 years, 2 months ago (2016-10-11 17:51:52 UTC) #28
Primiano Tucci (use gerrit)
Ok I have only some smaller comments but this LG. Will do a second pass ...
4 years, 2 months ago (2016-10-12 17:50:18 UTC) #33
ssid
Thanks, fixed / replied to comments. https://codereview.chromium.org/2323483005/diff/200001/base/trace_event/heap_profiler_allocation_context_tracker_unittest.cc File base/trace_event/heap_profiler_allocation_context_tracker_unittest.cc (right): https://codereview.chromium.org/2323483005/diff/200001/base/trace_event/heap_profiler_allocation_context_tracker_unittest.cc#newcode40 base/trace_event/heap_profiler_allocation_context_tracker_unittest.cc:40: " \"included_categories\": [\"disabled-by-default-memory-infra\"]" ...
4 years, 2 months ago (2016-10-12 19:04:44 UTC) #34
oystein (OOO til 10th of July)
Thanks for this! A few nits only basically. https://codereview.chromium.org/2323483005/diff/200001/base/trace_event/memory_dump_manager.cc File base/trace_event/memory_dump_manager.cc (right): https://codereview.chromium.org/2323483005/diff/200001/base/trace_event/memory_dump_manager.cc#newcode216 base/trace_event/memory_dump_manager.cc:216: MemoryDumpManager::kTraceCategory); ...
4 years, 2 months ago (2016-10-13 00:34:30 UTC) #37
ssid
Thanks, fixed. https://codereview.chromium.org/2323483005/diff/240001/base/trace_event/memory_dump_manager.cc File base/trace_event/memory_dump_manager.cc (right): https://codereview.chromium.org/2323483005/diff/240001/base/trace_event/memory_dump_manager.cc#newcode220 base/trace_event/memory_dump_manager.cc:220: TraceLog::GetInstance()->SetEnabled(filtering_trace_config, On 2016/10/13 00:34:29, oystein wrote: > ...
4 years, 2 months ago (2016-10-13 17:30:54 UTC) #46
Primiano Tucci (use gerrit)
Allright, LTGM Thanks a lot for the hard work here. https://codereview.chromium.org/2323483005/diff/240001/base/trace_event/memory_dump_manager.cc File base/trace_event/memory_dump_manager.cc (right): https://codereview.chromium.org/2323483005/diff/240001/base/trace_event/memory_dump_manager.cc#newcode226 ...
4 years, 2 months ago (2016-10-13 19:11:24 UTC) #49
ssid
On 2016/10/13 19:11:24, Primiano Tucci wrote: > Allright, LTGM haha typo :D
4 years, 2 months ago (2016-10-13 19:16:29 UTC) #50
oystein (OOO til 10th of July)
lgtm! https://codereview.chromium.org/2323483005/diff/240001/base/trace_event/memory_dump_manager.cc File base/trace_event/memory_dump_manager.cc (right): https://codereview.chromium.org/2323483005/diff/240001/base/trace_event/memory_dump_manager.cc#newcode226 base/trace_event/memory_dump_manager.cc:226: bool tracing_already_enabled = TraceLog::GetInstance()->IsEnabled(); On 2016/10/13 17:30:54, ssid ...
4 years, 2 months ago (2016-10-13 19:20:18 UTC) #51
ssid
Done. thanks https://codereview.chromium.org/2323483005/diff/340001/base/trace_event/trace_log.cc File base/trace_event/trace_log.cc (right): https://codereview.chromium.org/2323483005/diff/340001/base/trace_event/trace_log.cc#newcode870 base/trace_event/trace_log.cc:870: void TraceLog::SetDisabledWhileLocked(uint8_t modes) { On 2016/10/13 19:11:24, ...
4 years, 2 months ago (2016-10-13 19:39:36 UTC) #53
Primiano Tucci (use gerrit)
lol, I meant LGTM
4 years, 2 months ago (2016-10-13 19:40:16 UTC) #56
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2323483005/380001
4 years, 2 months ago (2016-10-13 20:57:40 UTC) #66
commit-bot: I haz the power
Committed patchset #7 (id:380001)
4 years, 2 months ago (2016-10-13 21:09:36 UTC) #68
commit-bot: I haz the power
Patchset 7 (id:??) landed as https://crrev.com/20d2eeed2c735fbf018b9a9dffa810d51a25940d Cr-Commit-Position: refs/heads/master@{#425156}
4 years, 2 months ago (2016-10-13 21:11:48 UTC) #70
Ilya Kulshin
A revert of this CL (patchset #7 id:380001) has been created in https://codereview.chromium.org/2415183004/ by kulshin@chromium.org. ...
4 years, 2 months ago (2016-10-13 23:23:19 UTC) #71
ssid
4 years, 2 months ago (2016-10-14 23:31:13 UTC) #72
Message was sent while issue was closed.
Sheriffs:
If there are more build breaks due to this CL, please contact primiano@ or
oysteine@ as I will be on vacation next 2 weeks.
Reverting this CL would mean reverting multiple CLs that landed after this one
as listed in crbug.com/625170.

Powered by Google App Engine
This is Rietveld 408576698