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

Issue 1666083002: Oilpan: Discard unused system pages when sweeping NormalPageHeaps (Closed)

Created:
4 years, 10 months ago by haraken
Modified:
4 years, 10 months ago
Reviewers:
sof, Yuta Kitamura
CC:
chromium-reviews, oilpan-reviews, Mads Ager (chromium), blink-reviews, kinuko+watch, kouhei+heap_chromium.org, blink-reviews-wtf_chromium.org, Mikhail
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Oilpan: Discard unused system pages when sweeping NormalPageHeaps This CL makes Oilpan's GC discard empty system pages (i.e., call madvise(MADV_FREE)) in free lists. This CL fixes regressions in memory.memory_health_plan. BUG= Committed: https://crrev.com/6fed8736a88eecf12017be4066db47b7427de8e5 Cr-Commit-Position: refs/heads/master@{#374616}

Patch Set 1 #

Patch Set 2 : #

Total comments: 2

Patch Set 3 : #

Patch Set 4 : #

Total comments: 1

Patch Set 5 : #

Total comments: 1

Patch Set 6 : #

Total comments: 1

Patch Set 7 : #

Patch Set 8 : #

Total comments: 1

Patch Set 9 : #

Patch Set 10 : #

Patch Set 11 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+58 lines, -26 lines) Patch
M third_party/WebKit/Source/platform/heap/BUILD.gn View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/DEPS View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/Heap.h View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/Heap.cpp View 1 2 3 4 5 6 7 8 3 chunks +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/HeapPage.cpp View 1 2 3 4 5 6 7 8 3 chunks +30 lines, -9 lines 0 comments Download
M third_party/WebKit/Source/platform/testing/DEPS View 1 2 3 4 5 6 7 8 9 10 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/testing/RunAllTests.cpp View 1 2 3 4 5 6 7 8 9 10 2 chunks +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/wtf/PageAllocator.h View 1 chunk +10 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/wtf/PartitionAlloc.cpp View 6 chunks +7 lines, -17 lines 0 comments Download

Messages

Total messages: 43 (13 generated)
haraken
Not for review. yutak@: Would you check if this CL fixes the regression on memory_health_plan?
4 years, 10 months ago (2016-02-04 06:32:29 UTC) #2
haraken
PTAL Sigbjorn: yutak@ confirmed that this CL mostly fixes the regressions in memory.memory_health_plan on low-RAM ...
4 years, 10 months ago (2016-02-04 09:45:55 UTC) #5
haraken
On 2016/02/04 09:45:55, haraken wrote: > PTAL > > Sigbjorn: yutak@ confirmed that this CL ...
4 years, 10 months ago (2016-02-04 09:46:21 UTC) #6
sof
A sign of fragmentation - any particular (sub) heap that has a longer freelist? If ...
4 years, 10 months ago (2016-02-04 10:20:04 UTC) #7
Yuta Kitamura
https://codereview.chromium.org/1666083002/diff/20001/third_party/WebKit/Source/platform/heap/HeapPage.cpp File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): https://codereview.chromium.org/1666083002/diff/20001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode1111 third_party/WebKit/Source/platform/heap/HeapPage.cpp:1111: if (beginAddress < endAddress) On 2016/02/04 10:20:04, sof wrote: ...
4 years, 10 months ago (2016-02-04 10:50:11 UTC) #8
haraken
On 2016/02/04 10:50:11, Yuta Kitamura wrote: > https://codereview.chromium.org/1666083002/diff/20001/third_party/WebKit/Source/platform/heap/HeapPage.cpp > File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): > > https://codereview.chromium.org/1666083002/diff/20001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode1111 ...
4 years, 10 months ago (2016-02-04 11:12:49 UTC) #9
Yuta Kitamura
On 2016/02/04 11:12:49, haraken wrote: > On 2016/02/04 10:50:11, Yuta Kitamura wrote: > > > ...
4 years, 10 months ago (2016-02-05 04:15:40 UTC) #10
haraken
On 2016/02/05 04:15:40, Yuta Kitamura wrote: > On 2016/02/04 11:12:49, haraken wrote: > > On ...
4 years, 10 months ago (2016-02-05 04:30:31 UTC) #11
haraken
Still debugging. https://codereview.chromium.org/1666083002/diff/60001/third_party/WebKit/Source/platform/heap/HeapPage.cpp File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): https://codereview.chromium.org/1666083002/diff/60001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode107 third_party/WebKit/Source/platform/heap/HeapPage.cpp:107: if (gcInfo->hasFinalizer()) { I crash here with ...
4 years, 10 months ago (2016-02-08 08:34:57 UTC) #12
haraken
https://codereview.chromium.org/1666083002/diff/80001/third_party/WebKit/Source/platform/heap/HeapPage.cpp File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): https://codereview.chromium.org/1666083002/diff/80001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode1161 third_party/WebKit/Source/platform/heap/HeapPage.cpp:1161: discardPages(startOfGap + sizeof(FreeListEntry), headerAddress); OK, I found the cause. ...
4 years, 10 months ago (2016-02-08 08:45:09 UTC) #13
haraken
On 2016/02/08 08:45:09, haraken wrote: > https://codereview.chromium.org/1666083002/diff/80001/third_party/WebKit/Source/platform/heap/HeapPage.cpp > File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): > > https://codereview.chromium.org/1666083002/diff/80001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode1161 > ...
4 years, 10 months ago (2016-02-08 09:14:05 UTC) #14
Yuta Kitamura
LGTM https://codereview.chromium.org/1666083002/diff/100001/third_party/WebKit/Source/platform/heap/HeapPage.cpp File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): https://codereview.chromium.org/1666083002/diff/100001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode33 third_party/WebKit/Source/platform/heap/HeapPage.cpp:33: #include "base/sys_info.h" Don't you need to update DEPS ...
4 years, 10 months ago (2016-02-08 09:30:39 UTC) #15
haraken
> https://codereview.chromium.org/1666083002/diff/100001/third_party/WebKit/Source/platform/heap/HeapPage.cpp > File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): > > https://codereview.chromium.org/1666083002/diff/100001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode33 > third_party/WebKit/Source/platform/heap/HeapPage.cpp:33: #include > "base/sys_info.h" > ...
4 years, 10 months ago (2016-02-08 09:38:37 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1666083002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1666083002/120001
4 years, 10 months ago (2016-02-08 09:38:39 UTC) #19
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_gn_rel on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_gn_rel/builds/63242)
4 years, 10 months ago (2016-02-08 09:42:39 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1666083002/140001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1666083002/140001
4 years, 10 months ago (2016-02-08 09:45:44 UTC) #24
commit-bot: I haz the power
Try jobs failed on following builders: android_chromium_gn_compile_dbg on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_chromium_gn_compile_dbg/builds/18714) android_chromium_gn_compile_rel on tryserver.chromium.android (JOB_FAILED, ...
4 years, 10 months ago (2016-02-08 09:49:13 UTC) #26
sof
https://codereview.chromium.org/1666083002/diff/140001/third_party/WebKit/Source/platform/heap/HeapPage.cpp File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): https://codereview.chromium.org/1666083002/diff/140001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode1120 third_party/WebKit/Source/platform/heap/HeapPage.cpp:1120: bool isLowEndDevice = base::SysInfo::IsLowEndDevice(); Do we have to sample ...
4 years, 10 months ago (2016-02-08 11:03:25 UTC) #27
haraken
On 2016/02/08 11:03:25, sof wrote: > https://codereview.chromium.org/1666083002/diff/140001/third_party/WebKit/Source/platform/heap/HeapPage.cpp > File third_party/WebKit/Source/platform/heap/HeapPage.cpp (right): > > https://codereview.chromium.org/1666083002/diff/140001/third_party/WebKit/Source/platform/heap/HeapPage.cpp#newcode1120 > ...
4 years, 10 months ago (2016-02-08 11:23:52 UTC) #28
sof
(fyi, this one isn't quite ready wrt IsLowEndDevice() usage)
4 years, 10 months ago (2016-02-09 14:07:30 UTC) #29
haraken
On 2016/02/09 14:07:30, sof wrote: > (fyi, this one isn't quite ready wrt IsLowEndDevice() usage) ...
4 years, 10 months ago (2016-02-10 05:56:02 UTC) #30
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1666083002/200001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1666083002/200001
4 years, 10 months ago (2016-02-10 05:56:31 UTC) #33
sof
are one or more of the bots config'ed as low-end?
4 years, 10 months ago (2016-02-10 07:14:54 UTC) #34
haraken
On 2016/02/10 07:14:54, sof wrote: > are one or more of the bots config'ed as ...
4 years, 10 months ago (2016-02-10 07:20:21 UTC) #35
commit-bot: I haz the power
Committed patchset #11 (id:200001)
4 years, 10 months ago (2016-02-10 07:30:08 UTC) #37
commit-bot: I haz the power
Patchset 11 (id:??) landed as https://crrev.com/6fed8736a88eecf12017be4066db47b7427de8e5 Cr-Commit-Position: refs/heads/master@{#374616}
4 years, 10 months ago (2016-02-10 07:31:02 UTC) #39
sof
On 2016/02/10 07:20:21, haraken wrote: > On 2016/02/10 07:14:54, sof wrote: > > are one ...
4 years, 10 months ago (2016-02-10 07:32:46 UTC) #40
haraken
On 2016/02/10 07:32:46, sof wrote: > On 2016/02/10 07:20:21, haraken wrote: > > On 2016/02/10 ...
4 years, 10 months ago (2016-02-10 07:45:03 UTC) #41
sof
On 2016/02/10 07:45:03, haraken wrote: > On 2016/02/10 07:32:46, sof wrote: > > On 2016/02/10 ...
4 years, 10 months ago (2016-02-10 08:23:17 UTC) #42
haraken
4 years, 10 months ago (2016-02-10 08:29:49 UTC) #43
Message was sent while issue was closed.
On 2016/02/10 08:23:17, sof wrote:
> On 2016/02/10 07:45:03, haraken wrote:
> > On 2016/02/10 07:32:46, sof wrote:
> > > On 2016/02/10 07:20:21, haraken wrote:
> > > > On 2016/02/10 07:14:54, sof wrote:
> > > > > are one or more of the bots config'ed as low-end?
> > > > 
> > > > I don't think so.
> > > > 
> > > > Also I guess ASSERTs are enabled on all bots that run tests. Which means
> > that
> > > > page discarding is not enabled even if the bot is configed as low-end.
> > > 
> > > oh, right. c/should it be using !defined(NDEBUG) instead of
!ENABLE(ASSERT)?
> > (i
> > > hope i got the negations right there.. i.e., enable it in release builds.)
> > 
> > Hmm, not really. When ASSERTs are enabled, we zap the free lists to assert
> > use-after-free. So we cannot discard pages of the free lists. If we want to
> > discard the pages, we need to disable the asserts about use-after-free.
> 
> Correctness wise it ought to work, but ok. That this code path is untested we
> just have to accept for now. "Solving" fragmentation is the longer term issue
to
> address, I think.

Yeah, agreed.

Powered by Google App Engine
This is Rietveld 408576698