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

Issue 1371053002: [Tracing] Add allocation register for heap profiling (Closed)

Created:
5 years, 2 months ago by Ruud van Asseldonk
Modified:
5 years, 2 months ago
CC:
chromium-reviews, tracing+reviews_chromium.org, wfh+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@backtrace
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Tracing] Add allocation register for heap profiling Malloc and PartitionAlloc dumpers will use this allocation register (a hash table) to keep track of all outstanding allocations. The hash table is tailored for this purpose. It handles its own memory management, to avoid allocation reentrancy issues when doing the bookkeeping. This is part of the heap profiler in chrome://tracing. BUG=524631 Committed: https://crrev.com/fd577b4f6c1f24709c274d8970d4f8e6369bb1ff Cr-Commit-Position: refs/heads/master@{#352664}

Patch Set 1 #

Total comments: 32

Patch Set 2 : Address some primiano comments #

Patch Set 3 : Rename fresh_ to next_unused_cell_ #

Patch Set 4 : Merge AllocationLessHashTable and AllocationRegister #

Patch Set 5 : _linux -> _posix #

Total comments: 46

Patch Set 6 : Try to get to compile on Apple platforms #

Patch Set 7 : Address primiano comments + try to fix build on Win/Mac #

Unified diffs Side-by-side diffs Delta from patch set Stats (+684 lines, -0 lines) Patch
M base/trace_event/BUILD.gn View 1 2 3 4 2 chunks +5 lines, -0 lines 0 comments Download
A base/trace_event/memory_profiler_allocation_register.h View 1 2 3 4 5 6 1 chunk +159 lines, -0 lines 0 comments Download
A base/trace_event/memory_profiler_allocation_register.cc View 1 2 3 4 5 6 1 chunk +166 lines, -0 lines 0 comments Download
A base/trace_event/memory_profiler_allocation_register_posix.cc View 1 2 3 4 5 6 1 chunk +59 lines, -0 lines 0 comments Download
A base/trace_event/memory_profiler_allocation_register_unittest.cc View 1 2 3 4 5 6 1 chunk +228 lines, -0 lines 0 comments Download
A base/trace_event/memory_profiler_allocation_register_win.cc View 1 2 3 4 5 6 1 chunk +62 lines, -0 lines 0 comments Download
M base/trace_event/trace_event.gypi View 1 2 3 4 2 chunks +5 lines, -0 lines 0 comments Download

Depends on Patchset:

Messages

Total messages: 19 (6 generated)
Ruud van Asseldonk
5 years, 2 months ago (2015-09-28 09:37:55 UTC) #2
Primiano Tucci (use gerrit)
Some initial comments, will take a more thorough look once after the first cleanup. https://codereview.chromium.org/1371053002/diff/1/base/trace_event/memory_profiler_allocation_register.h ...
5 years, 2 months ago (2015-10-05 14:11:06 UTC) #3
Ruud van Asseldonk
I addressed most comments but kept the hash table templated for now. I really think ...
5 years, 2 months ago (2015-10-06 09:26:45 UTC) #4
Ruud van Asseldonk
After merging |AllocationlessHashTable| and |AllocationRegister| I am convinced that the merged version is cleaner. Nit ...
5 years, 2 months ago (2015-10-06 12:27:47 UTC) #5
Primiano Tucci (use gerrit)
Looks beautiful to me. Thanks for all the efforts and for standing my whims, but ...
5 years, 2 months ago (2015-10-06 13:34:45 UTC) #6
Primiano Tucci (use gerrit)
Looks beautiful to me. Thanks for all the efforts and for standing my whims, but ...
5 years, 2 months ago (2015-10-06 13:34:46 UTC) #7
Primiano Tucci (use gerrit)
On 2015/10/06 13:34:46, Primiano Tucci wrote: > Looks beautiful to me. Thanks for all the ...
5 years, 2 months ago (2015-10-06 13:35:30 UTC) #8
Ruud van Asseldonk
https://codereview.chromium.org/1371053002/diff/80001/base/trace_event/memory_profiler_allocation_register.cc File base/trace_event/memory_profiler_allocation_register.cc (right): https://codereview.chromium.org/1371053002/diff/80001/base/trace_event/memory_profiler_allocation_register.cc#newcode20 base/trace_event/memory_profiler_allocation_register.cc:20: free_list_ = 0; On 2015/10/06 at 13:34:44, Primiano Tucci ...
5 years, 2 months ago (2015-10-06 15:44:35 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1371053002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1371053002/120001
5 years, 2 months ago (2015-10-06 19:28:25 UTC) #14
commit-bot: I haz the power
Committed patchset #7 (id:120001)
5 years, 2 months ago (2015-10-06 19:40:43 UTC) #15
commit-bot: I haz the power
Patchset 7 (id:??) landed as https://crrev.com/fd577b4f6c1f24709c274d8970d4f8e6369bb1ff Cr-Commit-Position: refs/heads/master@{#352664}
5 years, 2 months ago (2015-10-06 19:41:45 UTC) #16
kuan
A revert of this CL (patchset #7 id:120001) has been created in https://codereview.chromium.org/1387483006/ by kuan@chromium.org. ...
5 years, 2 months ago (2015-10-06 21:02:19 UTC) #17
Primiano Tucci (use gerrit)
5 years, 2 months ago (2015-10-07 07:49:09 UTC) #18
Message was sent while issue was closed.
On 2015/10/06 21:02:19, kuan wrote:
> A revert of this CL (patchset #7 id:120001) has been created in
> https://codereview.chromium.org/1387483006/ by mailto:kuan@chromium.org.
> 
> The reason for reverting is: broke builds:
> 
>
https://build.chromium.org/p/chromium.linux/builders/Linux%20Builder%20%28dbg...
> 
>
https://build.chromium.org/p/chromium.linux/builders/Linux%20GN%20%28dbg%29/b....

Bummer. NaCl build again (I wonder why there is no coverage on the CQ, filed
crbug.com/540566)
I think you want to exclude the posix .cc files when:
  is_nacl in GN, 
  >(nacl_untrusted_build)==1

Powered by Google App Engine
This is Rietveld 408576698