Bug 204039 - [JSC] Put more things in IsoSubspace
Summary: [JSC] Put more things in IsoSubspace
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Yusuke Suzuki
URL:
Keywords: InRadar
Depends on: 204124
Blocks:
  Show dependency treegraph
 
Reported: 2019-11-08 18:57 PST by Yusuke Suzuki
Modified: 2019-11-13 11:36 PST (History)
7 users (show)

See Also:


Attachments
Patch (15.00 KB, patch)
2019-11-08 18:58 PST, Yusuke Suzuki
keith_miller: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yusuke Suzuki 2019-11-08 18:57:18 PST
[JSC] Put more things in IsoSubspace
Comment 1 Yusuke Suzuki 2019-11-08 18:58:47 PST
Created attachment 383193 [details]
Patch
Comment 2 Radar WebKit Bug Importer 2019-11-08 19:00:59 PST
<rdar://problem/57042686>
Comment 3 Keith Miller 2019-11-12 18:13:58 PST
Comment on attachment 383193 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=383193&action=review

r=me.

> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h:116
> +    template<typename, SubspaceAccess>
> +    static IsoSubspace* subspaceFor(VM&) { return nullptr; }

What does this do?
Comment 4 Saam Barati 2019-11-12 18:14:14 PST
Comment on attachment 383193 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=383193&action=review

> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h:116
> +    static IsoSubspace* subspaceFor(VM&) { return nullptr; }

ASSERT_NOT_REACHED?
Comment 5 Yusuke Suzuki 2019-11-12 18:18:13 PST
Comment on attachment 383193 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=383193&action=review

Thanks!

>>> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h:116
>>> +    static IsoSubspace* subspaceFor(VM&) { return nullptr; }
>> 
>> What does this do?
> 
> ASSERT_NOT_REACHED?

This enforces us to define subspaceFor in derived classes of this UnlinkedCodeBlock. ASSERT_NOT_REACHED sounds nice, fixed!
Comment 6 Keith Miller 2019-11-12 18:22:50 PST
(In reply to Yusuke Suzuki from comment #5)
> Comment on attachment 383193 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=383193&action=review
> 
> Thanks!
> 
> >>> Source/JavaScriptCore/bytecode/UnlinkedCodeBlock.h:116
> >>> +    static IsoSubspace* subspaceFor(VM&) { return nullptr; }
> >> 
> >> What does this do?
> > 
> > ASSERT_NOT_REACHED?
> 
> This enforces us to define subspaceFor in derived classes of this
> UnlinkedCodeBlock. ASSERT_NOT_REACHED sounds nice, fixed!

Ah, I see. Too bad `= 0` doesn't work for non-virtual methods... ASSERT_NOT_REACHED sounds good.
Comment 7 Yusuke Suzuki 2019-11-12 18:25:51 PST
Committed r252390: <https://trac.webkit.org/changeset/252390>
Comment 8 Mark Lam 2019-11-13 09:48:49 PST
Comment on attachment 383193 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=383193&action=review

> Source/JavaScriptCore/runtime/VM.h:387
> +    IsoSubspace stringSpace;
> +    IsoSubspace ropeStringSpace;

Can you sort this alphabetically?
Comment 9 Yusuke Suzuki 2019-11-13 11:36:00 PST
Comment on attachment 383193 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=383193&action=review

>> Source/JavaScriptCore/runtime/VM.h:387
>> +    IsoSubspace ropeStringSpace;
> 
> Can you sort this alphabetically?

Sure, I'll do it in https://bugs.webkit.org/show_bug.cgi?id=204144.