Chromium Code Reviews| Index: base/trace_event/heap_profiler_allocation_context_tracker.h |
| diff --git a/base/trace_event/heap_profiler_allocation_context_tracker.h b/base/trace_event/heap_profiler_allocation_context_tracker.h |
| index d6133323bfb3d8f88f4331f6c718582c5611b3ee..5ce5831c49d68223ec171272aba7d120559c364d 100644 |
| --- a/base/trace_event/heap_profiler_allocation_context_tracker.h |
| +++ b/base/trace_event/heap_profiler_allocation_context_tracker.h |
| @@ -52,6 +52,12 @@ class BASE_EXPORT AllocationContextTracker { |
| // if capture is enabled. |
| static void SetCurrentThreadName(const char* name); |
| + void start_ignore_scope() { ignore_scope_count_++; } |
|
Primiano Tucci (use gerrit)
2016/04/20 16:34:57
add a comment plz. One for both is ok.
ssid
2016/04/21 01:07:46
Sorry uploaded older patch here.
|
| + void end_ignore_scope() { |
|
Primiano Tucci (use gerrit)
2016/04/20 16:34:57
s/start/begin/
s/start/end/
ssid
2016/04/21 01:07:46
I think you meant begin and end here.
|
| + DCHECK(ignore_scope_count_); |
| + ignore_scope_count_--; |
| + } |
| + |
| // Pushes a frame onto the thread-local pseudo stack. |
| void PushPseudoStackFrame(StackFrame frame); |
| @@ -83,6 +89,8 @@ class BASE_EXPORT AllocationContextTracker { |
| // pseudo stack to cluster allocations. |
| std::vector<const char*> task_contexts_; |
| + uint32_t ignore_scope_count_; |
|
Primiano Tucci (use gerrit)
2016/04/20 16:34:57
s/count/depth/
Dmitry Skiba
2016/04/20 16:59:15
Also, size_t is better here.
ssid
2016/04/21 01:07:46
Done.
ssid
2016/04/21 01:07:46
Done.
|
| + |
| DISALLOW_COPY_AND_ASSIGN(AllocationContextTracker); |
| }; |