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

Issue 2387733002: Move memory management code into separate class for future reuse. (Closed)

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

Description

Move memory management code into separate class for future reuse. BUG=620813 Committed: https://crrev.com/dadd3155cd102736da470fc28fc5aae89c7f0ac3 Cr-Commit-Position: refs/heads/master@{#425206}

Patch Set 1 #

Total comments: 12

Patch Set 2 : added comment and tests #

Total comments: 6

Patch Set 3 : use method for determining 'free' type #

Total comments: 3

Patch Set 4 : make 'free' type a ctor parameter #

Total comments: 2

Patch Set 5 : object_free -> object_free_type #

Unified diffs Side-by-side diffs Delta from patch set Stats (+217 lines, -112 lines) Patch
M base/debug/activity_tracker.h View 1 2 3 4 5 chunks +52 lines, -44 lines 0 comments Download
M base/debug/activity_tracker.cc View 1 2 3 4 4 chunks +106 lines, -66 lines 0 comments Download
M base/debug/activity_tracker_unittest.cc View 1 chunk +1 line, -1 line 0 comments Download
M base/metrics/persistent_memory_allocator.h View 1 2 chunks +16 lines, -0 lines 0 comments Download
M base/metrics/persistent_memory_allocator.cc View 2 chunks +21 lines, -1 line 0 comments Download
M base/metrics/persistent_memory_allocator_unittest.cc View 1 2 chunks +21 lines, -0 lines 0 comments Download

Messages

Total messages: 61 (43 generated)
bcwhite
4 years, 2 months ago (2016-10-03 14:47:29 UTC) #6
manzagop (departed)
I like it! A few comments. https://codereview.chromium.org/2387733002/diff/1/base/debug/activity_tracker.cc File base/debug/activity_tracker.cc (right): https://codereview.chromium.org/2387733002/diff/1/base/debug/activity_tracker.cc#newcode584 base/debug/activity_tracker.cc:584: base::AutoLock autolock(thread_tracker_allocator_lock_); Does ...
4 years, 2 months ago (2016-10-04 21:02:44 UTC) #12
manzagop (departed)
Another thought: perhaps the cl description could mention this moves from lock free to lock ...
4 years, 2 months ago (2016-10-04 21:03:29 UTC) #13
bcwhite
The previous implementation (ThreadSafeStack) wasn't lock-free (sadly). https://codereview.chromium.org/2387733002/diff/1/base/debug/activity_tracker.cc File base/debug/activity_tracker.cc (right): https://codereview.chromium.org/2387733002/diff/1/base/debug/activity_tracker.cc#newcode584 base/debug/activity_tracker.cc:584: base::AutoLock autolock(thread_tracker_allocator_lock_); ...
4 years, 2 months ago (2016-10-05 16:34:11 UTC) #16
manzagop (departed)
lgtm
4 years, 2 months ago (2016-10-05 19:56:30 UTC) #19
bcwhite
+Alexei, for changes to Iterator in PersistentMemoryAllocator.
4 years, 2 months ago (2016-10-06 14:28:08 UTC) #20
bcwhite
+asvitkine for real this time.
4 years, 2 months ago (2016-10-13 14:29:08 UTC) #26
Alexei Svitkine (slow)
https://codereview.chromium.org/2387733002/diff/40001/base/debug/activity_tracker.cc File base/debug/activity_tracker.cc (right): https://codereview.chromium.org/2387733002/diff/40001/base/debug/activity_tracker.cc#newcode109 base/debug/activity_tracker.cc:109: if (found && type == ~object_type_) { I don't ...
4 years, 2 months ago (2016-10-13 15:25:21 UTC) #28
bcwhite
https://codereview.chromium.org/2387733002/diff/40001/base/debug/activity_tracker.cc File base/debug/activity_tracker.cc (right): https://codereview.chromium.org/2387733002/diff/40001/base/debug/activity_tracker.cc#newcode109 base/debug/activity_tracker.cc:109: if (found && type == ~object_type_) { On 2016/10/13 ...
4 years, 2 months ago (2016-10-13 17:03:22 UTC) #34
Alexei Svitkine (slow)
https://codereview.chromium.org/2387733002/diff/100001/base/debug/activity_analyzer.cc File base/debug/activity_analyzer.cc (right): https://codereview.chromium.org/2387733002/diff/100001/base/debug/activity_analyzer.cc#newcode93 base/debug/activity_analyzer.cc:93: case ~GlobalActivityTracker::kTypeIdActivityTracker: Nit: Can this also use the helper ...
4 years, 2 months ago (2016-10-13 19:23:20 UTC) #37
bcwhite
https://codereview.chromium.org/2387733002/diff/100001/base/debug/activity_analyzer.cc File base/debug/activity_analyzer.cc (right): https://codereview.chromium.org/2387733002/diff/100001/base/debug/activity_analyzer.cc#newcode93 base/debug/activity_analyzer.cc:93: case ~GlobalActivityTracker::kTypeIdActivityTracker: On 2016/10/13 19:23:20, Alexei Svitkine (slow) wrote: ...
4 years, 2 months ago (2016-10-13 19:35:13 UTC) #38
Alexei Svitkine (slow)
Sure, that sounds good. On Thu, Oct 13, 2016 at 3:35 PM, <bcwhite@chromium.org> wrote: > ...
4 years, 2 months ago (2016-10-13 19:39:43 UTC) #39
bcwhite
Redone with a "free" type ctor-parameter.
4 years, 2 months ago (2016-10-13 20:01:40 UTC) #45
Alexei Svitkine (slow)
lgtm https://codereview.chromium.org/2387733002/diff/140001/base/debug/activity_tracker.cc File base/debug/activity_tracker.cc (right): https://codereview.chromium.org/2387733002/diff/140001/base/debug/activity_tracker.cc#newcode72 base/debug/activity_tracker.cc:72: uint32_t object_free, Nit: object_free_type so that "type" is ...
4 years, 2 months ago (2016-10-13 20:41:15 UTC) #46
bcwhite
https://codereview.chromium.org/2387733002/diff/140001/base/debug/activity_tracker.cc File base/debug/activity_tracker.cc (right): https://codereview.chromium.org/2387733002/diff/140001/base/debug/activity_tracker.cc#newcode72 base/debug/activity_tracker.cc:72: uint32_t object_free, On 2016/10/13 20:41:15, Alexei Svitkine (slow) wrote: ...
4 years, 2 months ago (2016-10-13 21:52:09 UTC) #52
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/2387733002/180001
4 years, 2 months ago (2016-10-13 22:54:57 UTC) #58
commit-bot: I haz the power
Committed patchset #5 (id:180001)
4 years, 2 months ago (2016-10-13 23:49:39 UTC) #59
commit-bot: I haz the power
4 years, 2 months ago (2016-10-13 23:51:43 UTC) #61
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/dadd3155cd102736da470fc28fc5aae89c7f0ac3
Cr-Commit-Position: refs/heads/master@{#425206}

Powered by Google App Engine
This is Rietveld 408576698