WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
222533
Reduce promise reaction memory usage when there are multiple reactions
https://bugs.webkit.org/show_bug.cgi?id=222533
Summary
Reduce promise reaction memory usage when there are multiple reactions
Keith Miller
Reported
2021-02-28 17:30:27 PST
Reduce promise reaction memory usage when there are multiple reactions
Attachments
Patch
(14.88 KB, patch)
2021-02-28 17:33 PST
,
Keith Miller
no flags
Details
Formatted Diff
Diff
Patch
(14.83 KB, patch)
2021-03-01 09:50 PST
,
Keith Miller
no flags
Details
Formatted Diff
Diff
Patch for landing
(14.86 KB, patch)
2021-03-01 16:56 PST
,
Keith Miller
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Keith Miller
Comment 1
2021-02-28 17:33:10 PST
Created
attachment 421783
[details]
Patch
Keith Miller
Comment 2
2021-03-01 09:50:28 PST
Created
attachment 421839
[details]
Patch
Yusuke Suzuki
Comment 3
2021-03-01 16:15:00 PST
Comment on
attachment 421839
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=421839&action=review
r=me with comment.
> Source/JavaScriptCore/ChangeLog:14 > + Previously, we would store each reaction in a linked list. This > + meant each reaction required 8 bytes to point to the next > + reaction. Instead, this patch makes it so the first reaction is > + store inline an object and any additional reactions are store into > + index storage for that object. This doesn't save memory for the > + first reaction since we now need to have a count of all the out of > + line reactions but extra reactions use 8 bytes less each.
Does it show RAMification improvement?
> Source/JavaScriptCore/builtins/PromiseOperations.js:153 > + var isResolved = state == @promiseStateFulfilled;
Use `===` instead of `==`.
Keith Miller
Comment 4
2021-03-01 16:49:42 PST
Comment on
attachment 421839
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=421839&action=review
>> Source/JavaScriptCore/ChangeLog:14 >> + line reactions but extra reactions use 8 bytes less each. > > Does it show RAMification improvement?
No, sadly :(
>> Source/JavaScriptCore/builtins/PromiseOperations.js:153 >> + var isResolved = state == @promiseStateFulfilled; > > Use `===` instead of `==`.
Oof, done!
Keith Miller
Comment 5
2021-03-01 16:56:23 PST
Created
attachment 421887
[details]
Patch for landing
EWS
Comment 6
2021-03-01 18:14:56 PST
Committed
r273718
: <
https://commits.webkit.org/r273718
> All reviewed patches have been landed. Closing bug and clearing flags on
attachment 421887
[details]
.
Radar WebKit Bug Importer
Comment 7
2021-03-01 18:15:16 PST
<
rdar://problem/74903266
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug