RESOLVED FIXED Bug 203121
[bmalloc] Bug fix for wait time when it's in mini mode.
https://bugs.webkit.org/show_bug.cgi?id=203121
Summary [bmalloc] Bug fix for wait time when it's in mini mode.
Basuke Suzuki
Reported 2019-10-17 14:44:39 PDT
m_waitTime is never changed on mini mode since https://trac.webkit.org/changeset/243144/webkit
Attachments
PATCH (1.47 KB, patch)
2019-10-17 14:57 PDT, Basuke Suzuki
no flags
Patch (2.40 KB, patch)
2019-11-06 19:24 PST, Yusuke Suzuki
no flags
Patch (2.44 KB, patch)
2019-11-06 19:25 PST, Yusuke Suzuki
saam: review+
Basuke Suzuki
Comment 1 2019-10-17 14:57:26 PDT
Basuke Suzuki
Comment 2 2019-10-17 14:57:51 PDT
Simple bug fix.
Basuke Suzuki
Comment 3 2019-10-17 15:01:37 PDT
Oh, there's no watchOS EWS...
Yusuke Suzuki
Comment 4 2019-10-17 16:05:45 PDT
Comment on attachment 381232 [details] PATCH r=me. Yes, this is apparently not intended behavior.
Basuke Suzuki
Comment 5 2019-10-17 16:20:42 PDT
Thanks!
WebKit Commit Bot
Comment 6 2019-10-17 17:02:17 PDT
Comment on attachment 381232 [details] PATCH Clearing flags on attachment: 381232 Committed r251268: <https://trac.webkit.org/changeset/251268>
WebKit Commit Bot
Comment 7 2019-10-17 17:02:18 PDT
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 8 2019-10-17 17:03:36 PDT
Yusuke Suzuki
Comment 9 2019-11-06 14:32:58 PST
Internally, we found that this behavior is making RAMification 1% regressed. And this is because, 1. Due to this accidental behavior, we are always using 10ms for the time interval. 2. And this works well for mini-mode. For now, I'll roll-out this change and keep mini-mode scavenging period 10ms. And another thing I would like to see is that the memory number w/ system malloc. Our bmalloc is focusing on performance, while system malloc does good thing for memory footprint in sacrifice of throughput. The purpose of Mini mode is making memory footprint small w/ small throughput loss, and this policy matches well to the system malloc. It would be possible that we could get some good memory footprint further by switching to system malloc by specifying Malloc=1 environment option. So, for now, I'll roll out this patch, (or, just removing adjusting part for mini-mode too).
Yusuke Suzuki
Comment 10 2019-11-06 15:58:10 PST
Saam Barati
Comment 11 2019-11-06 17:48:07 PST
(In reply to Yusuke Suzuki from comment #10) > Committed r252157: <https://trac.webkit.org/changeset/252157> why roll out this code? At least we should make the code sensible instead of updating a local variable which is never used
Yusuke Suzuki
Comment 12 2019-11-06 18:42:33 PST
(In reply to Saam Barati from comment #11) > (In reply to Yusuke Suzuki from comment #10) > > Committed r252157: <https://trac.webkit.org/changeset/252157> > > why roll out this code? At least we should make the code sensible instead of > updating a local variable which is never used Because of RAMification regression, we decide that the old broken behavior (always using 10ms) is the safest option for now. We will add a patch that is removing adjusting part for mini-mode in a separate patch.
Yusuke Suzuki
Comment 13 2019-11-06 18:43:06 PST
(In reply to Saam Barati from comment #11) > (In reply to Yusuke Suzuki from comment #10) > > Committed r252157: <https://trac.webkit.org/changeset/252157> > > why roll out this code? At least we should make the code sensible instead of > updating a local variable which is never used See the ChangeLog of roll-out. > We should clean up to make this bug's behavior default. And we should look for a bit larger interval here
Yusuke Suzuki
Comment 14 2019-11-06 19:24:12 PST
Reopening to attach new patch.
Yusuke Suzuki
Comment 15 2019-11-06 19:24:13 PST
Yusuke Suzuki
Comment 16 2019-11-06 19:25:30 PST
Saam Barati
Comment 17 2019-11-07 11:11:16 PST
Comment on attachment 383013 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=383013&action=review r=me > Source/bmalloc/bmalloc/Scavenger.cpp:-504 > - if (m_isInMiniMode) { > - timeSpentScavenging *= 50; > - newWaitTime = std::chrono::duration_cast<std::chrono::milliseconds>(timeSpentScavenging); > - newWaitTime = std::min(std::max(newWaitTime, std::chrono::milliseconds(25)), std::chrono::milliseconds(500)); > - } else { Can we file a FIXME?
Yusuke Suzuki
Comment 18 2019-11-07 17:29:14 PST
Note You need to log in before you can comment on or make changes to this bug.