[ShadowRealm] Part 1 - Skeleton [v8/v8 : main]

102 views
Skip to first unread message

legendecas (Gerrit)

unread,
Oct 11, 2021, 8:34:20 PM10/11/21
to jgrube...@chromium.org, victorgo...@chromium.org, V8 LUCI CQ, Michael Hablich, v8-re...@googlegroups.com

Attention is currently required from: legendecas.

Set Ready For Review

View Change

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 5
    Gerrit-Owner: legendecas <legen...@gmail.com>
    Gerrit-Reviewer: legendecas <legen...@gmail.com>
    Gerrit-CC: Michael Hablich <hab...@chromium.org>
    Gerrit-Attention: legendecas <legen...@gmail.com>
    Gerrit-Comment-Date: Tue, 12 Oct 2021 00:34:14 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: No
    Gerrit-MessageType: comment

    legendecas (Gerrit)

    unread,
    Oct 11, 2021, 8:35:08 PM10/11/21
    to Michael Hablich, jgrube...@chromium.org, victorgo...@chromium.org, Shu-yu Guo, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Shu-yu Guo, Toon Verwaest, legendecas.

    legendecas removed Michael Hablich from this change.

    View Change

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 5
    Gerrit-Owner: legendecas <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-Reviewer: legendecas <legen...@gmail.com>
    Gerrit-Attention: Shu-yu Guo <s...@chromium.org>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Attention: legendecas <legen...@gmail.com>
    Gerrit-MessageType: deleteReviewer

    legendecas (Gerrit)

    unread,
    Oct 11, 2021, 8:36:58 PM10/11/21
    to jgrube...@chromium.org, victorgo...@chromium.org, Shu-yu Guo, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Shu-yu Guo, Toon Verwaest.

    View Change

    1 comment:

    • Patchset:

      • Patch Set #5:

        Hi, Toon, Shu. This is the bootstrap of ShadowRealm proposal. May I have your review on this? Thanks!

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 5
    Gerrit-Owner: legendecas <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-Reviewer: legendecas <legen...@gmail.com>
    Gerrit-Attention: Shu-yu Guo <s...@chromium.org>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Tue, 12 Oct 2021 00:36:53 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Gerrit-MessageType: comment

    Shu-yu Guo (Gerrit)

    unread,
    Nov 1, 2021, 8:27:25 PM11/1/21
    to legendecas, jgrube...@chromium.org, victorgo...@chromium.org, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: legendecas, Toon Verwaest.

    View Change

    11 comments:

    • Patchset:

      • Patch Set #5:

        Sorry for the very late review, legendecas.

        The main thing here is that a design doc is warranted for the API interface for how hosts should hook into creation of the ShadowRealm globals, as well as how those globals delegate answers up to their creator realm.

        Could you please write up a Google doc, and then we can get the relevant V8 and blink engineers to review?

    • File src/builtins/accessors.h:

    • File src/builtins/builtins-shadow-realms.cc:

      • Patch Set #5, Line 12: BUILTIN(ShadowRealmConstructor) {

        Could you copy/paste the spec steps into these builtins please?

      • Patch Set #5, Line 33: DeserializeEmbedderFieldsCallback(), nullptr);

        This part isn't right, though not all details are known yet pending HTML integration:

        • The host needs a way to hook in the extensions and the object template. This probably requires API changes.
        • The shadow realm needs to know its parent realm to get at the settings object for web API. Where are you storing this info?
        • I'm not sure if a JSGlobalProxy is necessary here, since we don't need the identity-preserving semantics of being able to swap out its guts. However, we probably do want to be able to leverage the existing security checks for access globals.

        I think the next step here is to write up a design doc for what kind of global object ShadowRealm globals should be, what API extensions are needed, and how blink should hook into it, so we can get reviews across different teams.

    • File src/diagnostics/objects-debug.cc:

      • Patch Set #5, Line 1129:

        void JSShadowRealm::JSShadowRealmVerify(Isolate* isolate) {
        TorqueGeneratedClassVerifiers::JSShadowRealmVerify(*this, isolate);
        }

        void JSWrappedFunction::JSWrappedFunctionVerify(Isolate* isolate) {
        TorqueGeneratedClassVerifiers::JSWrappedFunctionVerify(*this, isolate);
        }

        These seem like they could be USE_TORQUE_VERIFIER

    • File src/init/bootstrapper.cc:

    • File src/init/heap-symbols.h:

    • File src/objects/contexts.h:

    • File src/objects/js-function.cc:

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 5
    Gerrit-Owner: legendecas <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-Reviewer: legendecas <legen...@gmail.com>
    Gerrit-Attention: legendecas <legen...@gmail.com>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Tue, 02 Nov 2021 00:27:19 +0000

    legendecas (Gerrit)

    unread,
    Nov 16, 2021, 1:15:57 PM11/16/21
    to jgrube...@chromium.org, victorgo...@chromium.org, Caitlin Potter, Shu-yu Guo, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Shu-yu Guo.

    Patch set 7:Commit-Queue +1

    View Change

    11 comments:

    • Patchset:

      • Patch Set #7:

        This is an update to reflect the shape in the design doc.

    • File src/builtins/accessors.h:

      • Neither length nor name are specified in the spec draft AFAICT. I've filed https://github. […]

        The spec is not finalized yet. So I'd remove these for now.

    • File src/builtins/builtins-shadow-realms.cc:

      • Patch Set #5, Line 12: BUILTIN(ShadowRealmConstructor) {

        Could you copy/paste the spec steps into these builtins please?

      • Done

      • Patch Set #5, Line 1129:

        void JSShadowRealm::JSShadowRealmVerify(Isolate* isolate) {
        TorqueGeneratedClassVerifiers::JSShadowRealmVerify(*this, isolate);
        }

        void JSWrappedFunction::JSWrappedFunctionVerify(Isolate* isolate) {
        TorqueGeneratedClassVerifiers::JSWrappedFunctionVerify(*this, isolate);
        }

        These seem like they could be USE_TORQUE_VERIFIER

      • Done

    • File src/init/bootstrapper.cc:

      • Done

      • Done

      • Done

    • File src/init/heap-symbols.h:

      • Removed.

    • File src/objects/contexts.h:

      • Removed

    • File src/objects/js-function.cc:

      • This doesn't seem right. Intuitively I would expect the name to be target. […]

        The spec is not finalized yet. So I'd remove these for now.

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 7
    Gerrit-Owner: legendecas <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-Reviewer: legendecas <legen...@gmail.com>
    Gerrit-CC: Caitlin Potter <ca...@igalia.com>
    Gerrit-Attention: Shu-yu Guo <s...@chromium.org>
    Gerrit-Comment-Date: Tue, 16 Nov 2021 18:15:49 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    Comment-In-Reply-To: Shu-yu Guo <s...@chromium.org>
    Gerrit-MessageType: comment

    Chengzhong Wu (Gerrit)

    unread,
    Dec 12, 2021, 9:23:36 PM12/12/21
    to jgrube...@chromium.org, victorgo...@chromium.org, Caitlin Potter, Shu-yu Guo, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Shu-yu Guo, Toon Verwaest.

    View Change

    1 comment:

    • Patchset:

      • Patch Set #10:

        Hi, folks. Thanks for reviewing the design doc! I've resolved the conflicts and updated the CL to reflect the host hooks design doc (https://docs.google.com/document/d/1k9OZxtbKmzENOMzahmm2C0uBNRc_pVLXMSoKsrkJJBw/edit). For the testing completeness of this CL, I've removed the WrappedFunction definition in this CL since it is not reachable in anyways from the current implementation and is not feasible to get tested. I'll submit a follow-up CL for ShadowRealm.prototype.evaluate and the WrappedFunction once this large CL gets landed. Please take a look, thanks a lot :)

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 10
    Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-CC: Caitlin Potter <ca...@igalia.com>
    Gerrit-Attention: Shu-yu Guo <s...@chromium.org>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Mon, 13 Dec 2021 02:23:27 +0000

    Shu-yu Guo (Gerrit)

    unread,
    Jan 7, 2022, 7:38:41 PM1/7/22
    to Chengzhong Wu, jgrube...@chromium.org, victorgo...@chromium.org, Caitlin Potter, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Chengzhong Wu, Toon Verwaest.

    View Change

    8 comments:

    • Patchset:

      • Patch Set #11:

        Mostly looks good, thank you for the CL!

        Looks like there're merge conflicts again, and perhaps double-check with the newest test262 roll if the status list is update to date.

    • File src/builtins/builtins-shadow-realms.cc:

      • Patch Set #11, Line 49: isolate->factory()->NewFastOrSlowJSObjectFromMap

        Could you use JSObject::New here instead of manually getting the derived map?

      • Patch Set #11, Line 62:

          if (!args.new_target()->IsUndefined(isolate)) {  // [[Construct]]
        THROW_NEW_ERROR_RETURN_FAILURE(
        isolate, NewTypeError(MessageTemplate::kConstructorNotFunction,
        isolate->factory()->ShadowRealm_string()));
        }

        You don't need to manually check for 'new', it's already done before we enter here.

      • Patch Set #11, Line 74:

          if (!args.new_target()->IsUndefined(isolate)) {  // [[Construct]]
        THROW_NEW_ERROR_RETURN_FAILURE(
        isolate, NewTypeError(MessageTemplate::kConstructorNotFunction,
        isolate->factory()->ShadowRealm_string()));
        }

        You don't need to manually check for 'new', it's already done before we enter here.

    • File src/execution/isolate.cc:

      • Patch Set #11, Line 4689: return Handle<NativeContext>::cast(shadow_realm_context);

        Hm, is there a good reason to support a default implementation? We could just throw kUnsupported if the callback is not set.

        d8 should set its own, if you put the default implementation here for testing in d8.

    • File test/cctest/test-api.cc:

      • Patch Set #11, Line 26617: v8::V8::SetFlagsFromString("--harmony-shadow-realm");

        cctests can get away with doing i::FLAG_harmony_shadow_realm = true directly.

      • Patch Set #11, Line 26634: CHECK(result->IsObject());

        Please also check that the internal object IsJSShadowRealm()

    • File test/test262/test262.status:

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 11
    Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-CC: Caitlin Potter <ca...@igalia.com>
    Gerrit-Attention: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Sat, 08 Jan 2022 00:38:27 +0000

    Chengzhong Wu (Gerrit)

    unread,
    Jan 11, 2022, 12:20:24 PM1/11/22
    to jgrube...@chromium.org, victorgo...@chromium.org, Caitlin Potter, Shu-yu Guo, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Shu-yu Guo, Toon Verwaest.

    Patch set 14:-Commit-Queue

    View Change

    8 comments:

    • Patchset:

    • File src/builtins/builtins-shadow-realms.cc:

    • File src/builtins/builtins-shadow-realms.cc:

      • Patch Set #11, Line 49: isolate->factory()->NewFastOrSlowJSObjectFromMap

        Could you use JSObject::New here instead of manually getting the derived map?

      • Done

      • Patch Set #11, Line 62:

          if (!args.new_target()->IsUndefined(isolate)) {  // [[Construct]]
        THROW_NEW_ERROR_RETURN_FAILURE(
        isolate, NewTypeError(MessageTemplate::kConstructorNotFunction,
        isolate->factory()->ShadowRealm_string()));
        }

        You don't need to manually check for 'new', it's already done before we enter here.

      • Done

      • Patch Set #11, Line 74:

          if (!args.new_target()->IsUndefined(isolate)) {  // [[Construct]]
        THROW_NEW_ERROR_RETURN_FAILURE(
        isolate, NewTypeError(MessageTemplate::kConstructorNotFunction,
        isolate->factory()->ShadowRealm_string()));
        }

        You don't need to manually check for 'new', it's already done before we enter here.

      • Done

    • File src/execution/isolate.cc:

      • Hm, is there a good reason to support a default implementation? We could just throw kUnsupported if […]

        Done

    • File test/cctest/test-api.cc:

      • Patch Set #11, Line 26617: v8::V8::SetFlagsFromString("--harmony-shadow-realm");

        cctests can get away with doing i::FLAG_harmony_shadow_realm = true directly.

      • Done

      • Done

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 14
    Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-CC: Caitlin Potter <ca...@igalia.com>
    Gerrit-Attention: Shu-yu Guo <s...@chromium.org>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Tue, 11 Jan 2022 17:20:13 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    Comment-In-Reply-To: Shu-yu Guo <s...@chromium.org>
    Comment-In-Reply-To: Chengzhong Wu <legen...@gmail.com>
    Gerrit-MessageType: comment

    Shu-yu Guo (Gerrit)

    unread,
    Jan 11, 2022, 8:01:56 PM1/11/22
    to Chengzhong Wu, jgrube...@chromium.org, victorgo...@chromium.org, Caitlin Potter, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Chengzhong Wu, Toon Verwaest.

    Patch set 14:Code-Review +1

    View Change

    1 comment:

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 14
    Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-CC: Caitlin Potter <ca...@igalia.com>
    Gerrit-Attention: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Wed, 12 Jan 2022 01:01:45 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    Gerrit-MessageType: comment

    Shu-yu Guo (Gerrit)

    unread,
    Jan 11, 2022, 8:02:23 PM1/11/22
    to Chengzhong Wu, jgrube...@chromium.org, victorgo...@chromium.org, Caitlin Potter, Toon Verwaest, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Chengzhong Wu, Toon Verwaest.

    View Change

    1 comment:

    • Patchset:

      • Patch Set #14:

        I'm not an owner on all the subdirectories. Toon, mind doing an OWNER stamp?

    To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
    Gerrit-Change-Number: 3195532
    Gerrit-PatchSet: 14
    Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
    Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
    Gerrit-CC: Caitlin Potter <ca...@igalia.com>
    Gerrit-Attention: Chengzhong Wu <legen...@gmail.com>
    Gerrit-Attention: Toon Verwaest <verw...@chromium.org>
    Gerrit-Comment-Date: Wed, 12 Jan 2022 01:02:13 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Gerrit-MessageType: comment

    Toon Verwaest (Gerrit)

    unread,
    Jan 18, 2022, 4:34:03 AM1/18/22
    to Chengzhong Wu, jgrube...@chromium.org, victorgo...@chromium.org, Shu-yu Guo, Caitlin Potter, V8 LUCI CQ, v8-re...@googlegroups.com

    Attention is currently required from: Chengzhong Wu.

    Patch set 14:Code-Review +1

    View Change

      To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

      Gerrit-Project: v8/v8
      Gerrit-Branch: main
      Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
      Gerrit-Change-Number: 3195532
      Gerrit-PatchSet: 14
      Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
      Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
      Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
      Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
      Gerrit-CC: Caitlin Potter <ca...@igalia.com>
      Gerrit-Attention: Chengzhong Wu <legen...@gmail.com>
      Gerrit-Comment-Date: Tue, 18 Jan 2022 09:33:49 +0000
      Gerrit-HasComments: No
      Gerrit-Has-Labels: Yes
      Gerrit-MessageType: comment

      Chengzhong Wu (Gerrit)

      unread,
      Jan 25, 2022, 11:38:14 AM1/25/22
      to jgrube...@chromium.org, victorgo...@chromium.org, Toon Verwaest, Shu-yu Guo, Caitlin Potter, V8 LUCI CQ, v8-re...@googlegroups.com

      Attention is currently required from: Chengzhong Wu.

      Patch set 15:Commit-Queue +2

      View Change

        To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

        Gerrit-Project: v8/v8
        Gerrit-Branch: main
        Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
        Gerrit-Change-Number: 3195532
        Gerrit-PatchSet: 15
        Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
        Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
        Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
        Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
        Gerrit-CC: Caitlin Potter <ca...@igalia.com>
        Gerrit-Attention: Chengzhong Wu <legen...@gmail.com>
        Gerrit-Comment-Date: Tue, 25 Jan 2022 16:38:07 +0000

        V8 LUCI CQ (Gerrit)

        unread,
        Jan 25, 2022, 1:11:07 PM1/25/22
        to Chengzhong Wu, jgrube...@chromium.org, victorgo...@chromium.org, Toon Verwaest, Shu-yu Guo, Caitlin Potter, v8-re...@googlegroups.com

        V8 LUCI CQ submitted this change.

        View Change



        14 is the latest approved patch-set.
        The change was submitted with unreviewed changes in the following files:

        ```
        The name of the file: tools/v8heapconst.py
        Insertions: 121, Deletions: 120.

        The diff is too large to show. Please review the diff.
        ```

        Approvals: Toon Verwaest: Looks good to me Shu-yu Guo: Looks good to me Chengzhong Wu: Commit
        [ShadowRealm] Part 1 - Skeleton

        1. Expose all the functions to empty builtins.
        2. Wire up the basic structure of ShadowRealm and internal slots.

        Bug: v8:11989
        Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
        Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3195532
        Reviewed-by: Shu-yu Guo <s...@chromium.org>
        Reviewed-by: Toon Verwaest <verw...@chromium.org>
        Commit-Queue: Chengzhong Wu <legen...@gmail.com>
        Cr-Commit-Position: refs/heads/main@{#78757}
        ---
        M BUILD.bazel
        M BUILD.gn
        M include/v8-callbacks.h
        M include/v8-isolate.h
        M src/api/api.cc
        M src/builtins/base.tq
        M src/builtins/builtins-definitions.h
        A src/builtins/builtins-shadow-realms.cc
        M src/compiler/types.cc
        M src/d8/d8.cc
        M src/d8/d8.h
        M src/diagnostics/objects-debug.cc
        M src/diagnostics/objects-printer.cc
        M src/execution/isolate.cc
        M src/execution/isolate.h
        M src/flags/flag-definitions.h
        M src/init/bootstrapper.cc
        M src/init/heap-symbols.h
        M src/objects/all-objects-inl.h
        M src/objects/js-function.cc
        M src/objects/js-objects.cc
        A src/objects/js-shadow-realms-inl.h
        A src/objects/js-shadow-realms.h
        A src/objects/js-shadow-realms.tq
        M src/objects/map.cc
        M src/objects/object-list-macros.h
        M src/objects/objects-body-descriptors-inl.h
        M src/objects/objects.h
        M test/cctest/test-api.cc
        M test/test262/test262.status
        M test/test262/testcfg.py
        M tools/v8heapconst.py
        32 files changed, 468 insertions(+), 111 deletions(-)


        To view, visit change 3195532. To unsubscribe, or for help writing mail filters, visit settings.

        Gerrit-Project: v8/v8
        Gerrit-Branch: main
        Gerrit-Change-Id: If7545fe18a74b2bd4b70a1a25776e41f03aaff89
        Gerrit-Change-Number: 3195532
        Gerrit-PatchSet: 16
        Gerrit-Owner: Chengzhong Wu <legen...@gmail.com>
        Gerrit-Reviewer: Chengzhong Wu <legen...@gmail.com>
        Gerrit-Reviewer: Shu-yu Guo <s...@chromium.org>
        Gerrit-Reviewer: Toon Verwaest <verw...@chromium.org>
        Gerrit-CC: Caitlin Potter <ca...@igalia.com>
        Gerrit-MessageType: merged
        Reply all
        Reply to author
        Forward
        0 new messages