WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
215666
[JSC] Add Object.getOwnPropertyNames caching as it is done for Object.keys, and accelerate Object.getOwnPropertyDescriptor
https://bugs.webkit.org/show_bug.cgi?id=215666
Summary
[JSC] Add Object.getOwnPropertyNames caching as it is done for Object.keys, a...
Yusuke Suzuki
Reported
2020-08-19 15:14:22 PDT
[JSC] Add Object.getOwnPropertyNames caching as it is done for Object.keys, and accelerate Object.getOwnPropertyDescriptor
Attachments
Patch
(73.79 KB, patch)
2020-08-19 15:18 PDT
,
Yusuke Suzuki
no flags
Details
Formatted Diff
Diff
Patch
(73.89 KB, patch)
2020-08-19 16:01 PDT
,
Yusuke Suzuki
no flags
Details
Formatted Diff
Diff
Patch
(73.89 KB, patch)
2020-08-19 16:03 PDT
,
Yusuke Suzuki
saam
: review+
Details
Formatted Diff
Diff
Patch for landing
(75.37 KB, patch)
2020-08-19 18:56 PDT
,
Yusuke Suzuki
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Yusuke Suzuki
Comment 1
2020-08-19 15:18:32 PDT
Created
attachment 406878
[details]
Patch
Yusuke Suzuki
Comment 2
2020-08-19 16:01:29 PDT
Created
attachment 406881
[details]
Patch
Yusuke Suzuki
Comment 3
2020-08-19 16:03:53 PDT
Created
attachment 406882
[details]
Patch
Saam Barati
Comment 4
2020-08-19 18:00:08 PDT
Comment on
attachment 406882
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=406882&action=review
Nice. r=me
> Source/JavaScriptCore/dfg/DFGConstantFoldingPhase.cpp:944 > + CachedPropertyNames key = node->op() == ObjectGetOwnPropertyNames ? CachedPropertyNames::OwnNames : CachedPropertyNames::OwnKeys;
nit: Just put this inline in the function call below?
> Source/JavaScriptCore/runtime/StructureRareData.cpp:79 > + auto validateAndAppend = [&](WriteBarrier<JSImmutableButterfly>& slot) {
nit: why not just have this in the loop below?
> Source/JavaScriptCore/runtime/StructureRareData.h:40 > +enum class CachedPropertyNames : uint8_t {
nit: I'd name this "CachedPropertyNamesKind" or similar
Yusuke Suzuki
Comment 5
2020-08-19 18:32:49 PDT
Comment on
attachment 406882
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=406882&action=review
Thanks!
>> Source/JavaScriptCore/dfg/DFGConstantFoldingPhase.cpp:944 >> + CachedPropertyNames key = node->op() == ObjectGetOwnPropertyNames ? CachedPropertyNames::OwnNames : CachedPropertyNames::OwnKeys; > > nit: Just put this inline in the function call below?
Sounds nice, fixed.
>> Source/JavaScriptCore/runtime/StructureRareData.cpp:79 >> + auto validateAndAppend = [&](WriteBarrier<JSImmutableButterfly>& slot) { > > nit: why not just have this in the loop below?
Ah, right. Originally, they are not loop, But I made it loop by refactoring. We should put it inside loop without lambda. Fixed.
>> Source/JavaScriptCore/runtime/StructureRareData.h:40 >> +enum class CachedPropertyNames : uint8_t { > > nit: I'd name this "CachedPropertyNamesKind" or similar
Fixed.
Yusuke Suzuki
Comment 6
2020-08-19 18:56:23 PDT
Created
attachment 406899
[details]
Patch for landing
Yusuke Suzuki
Comment 7
2020-08-19 22:07:34 PDT
Committed
r265934
: <
https://trac.webkit.org/changeset/265934
>
Radar WebKit Bug Importer
Comment 8
2020-08-19 22:08:14 PDT
<
rdar://problem/67452338
>
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