[array-buffer] Track AB views to avoid protector invalidation [v8/v8 : main]

0 views
Skip to first unread message

Olivier Flückiger (Gerrit)

unread,
Dec 22, 2025, 12:26:17 PM12/22/25
to Camillo Bruni, chrom...@appspot.gserviceaccount.com, V8 LUCI CQ, AyeAye, Hannes Payer, leszek...@chromium.org, cbruni...@chromium.org, v8-flag...@chromium.org, victorgo...@chromium.org, verwaes...@chromium.org, dmercadi...@chromium.org, jgrube...@chromium.org, mlippau...@chromium.org, v8-re...@googlegroups.com
Attention needed from Camillo Bruni

Olivier Flückiger voted and added 1 comment

Votes added by Olivier Flückiger

Commit-Queue+1

1 comment

Patchset-level comments
File-level comment, Patchset 31 (Latest):
Olivier Flückiger . resolved

ptal

Open in Gerrit

Related details

Attention is currently required from:
  • Camillo Bruni
Submit Requirements:
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: v8/v8
Gerrit-Branch: main
Gerrit-Change-Id: I240ca8523865115a839995489745d8b036830fcb
Gerrit-Change-Number: 7255835
Gerrit-PatchSet: 31
Gerrit-Owner: Olivier Flückiger <ol...@chromium.org>
Gerrit-Reviewer: Camillo Bruni <cbr...@chromium.org>
Gerrit-Reviewer: Olivier Flückiger <ol...@chromium.org>
Gerrit-CC: Hannes Payer <hpa...@chromium.org>
Gerrit-Attention: Camillo Bruni <cbr...@chromium.org>
Gerrit-Comment-Date: Mon, 22 Dec 2025 17:26:12 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
unsatisfied_requirement
open
diffy

Camillo Bruni (Gerrit)

unread,
Dec 23, 2025, 4:18:28 AM12/23/25
to Olivier Flückiger, chrom...@appspot.gserviceaccount.com, V8 LUCI CQ, AyeAye, Hannes Payer, leszek...@chromium.org, cbruni...@chromium.org, v8-flag...@chromium.org, victorgo...@chromium.org, verwaes...@chromium.org, dmercadi...@chromium.org, jgrube...@chromium.org, mlippau...@chromium.org, v8-re...@googlegroups.com
Attention needed from Olivier Flückiger

Camillo Bruni added 4 comments

File include/v8-array-buffer.h
Line 355, Patchset 31 (Latest): void SetDetachKey(v8::Local<v8::String> key);
Camillo Bruni . unresolved

technically we should a proper API deprecation for this 😞

File src/diagnostics/objects-debug.cc
Line 2420, Patchset 31 (Latest): }
Camillo Bruni . unresolved

do you plan to allow more values? maybe worth making this stricter here?

File src/objects/js-array-buffer-inl.h
Line 186, Patchset 31 (Latest): DCHECK(value.IsSmi() || value.IsWeak());
Camillo Bruni . unresolved

could this be a stricter check (kNoView, kManyViews)?

File src/runtime/runtime.cc
Line 218, Patchset 31 (Latest): case Runtime::kArrayBufferDetach:
Camillo Bruni . unresolved

nit: I guess we could remove it here?

Open in Gerrit

Related details

Attention is currently required from:
  • Olivier Flückiger
Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I240ca8523865115a839995489745d8b036830fcb
    Gerrit-Change-Number: 7255835
    Gerrit-PatchSet: 31
    Gerrit-Owner: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Reviewer: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Reviewer: Olivier Flückiger <ol...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Comment-Date: Tue, 23 Dec 2025 09:18:22 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy

    Olivier Flückiger (Gerrit)

    unread,
    Dec 23, 2025, 11:04:15 AM12/23/25
    to Camillo Bruni, chrom...@appspot.gserviceaccount.com, V8 LUCI CQ, AyeAye, Hannes Payer, leszek...@chromium.org, cbruni...@chromium.org, v8-flag...@chromium.org, victorgo...@chromium.org, verwaes...@chromium.org, dmercadi...@chromium.org, jgrube...@chromium.org, mlippau...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Camillo Bruni

    Olivier Flückiger added 1 comment

    File include/v8-array-buffer.h
    Line 355, Patchset 31 (Latest): void SetDetachKey(v8::Local<v8::String> key);
    Camillo Bruni . unresolved

    technically we should a proper API deprecation for this 😞

    Olivier Flückiger

    I know but, I couldn't find any users which would pass anything but Strings. Some wrappers even use String as the type. And the spec says that it is a string...

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Camillo Bruni
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I240ca8523865115a839995489745d8b036830fcb
    Gerrit-Change-Number: 7255835
    Gerrit-PatchSet: 31
    Gerrit-Owner: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Reviewer: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Reviewer: Olivier Flückiger <ol...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Comment-Date: Tue, 23 Dec 2025 16:04:11 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Camillo Bruni <cbr...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Camillo Bruni (Gerrit)

    unread,
    Dec 30, 2025, 11:18:53 AM (10 days ago) 12/30/25
    to Olivier Flückiger, chrom...@appspot.gserviceaccount.com, V8 LUCI CQ, AyeAye, Hannes Payer, leszek...@chromium.org, cbruni...@chromium.org, v8-flag...@chromium.org, victorgo...@chromium.org, verwaes...@chromium.org, dmercadi...@chromium.org, jgrube...@chromium.org, mlippau...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Olivier Flückiger

    Camillo Bruni added 1 comment

    File include/v8-array-buffer.h
    Line 355, Patchset 31 (Latest): void SetDetachKey(v8::Local<v8::String> key);
    Camillo Bruni . resolved

    technically we should a proper API deprecation for this 😞

    Olivier Flückiger

    I know but, I couldn't find any users which would pass anything but Strings. Some wrappers even use String as the type. And the spec says that it is a string...

    Camillo Bruni

    fingers-crossed.

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Olivier Flückiger
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I240ca8523865115a839995489745d8b036830fcb
    Gerrit-Change-Number: 7255835
    Gerrit-PatchSet: 31
    Gerrit-Owner: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Reviewer: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Reviewer: Olivier Flückiger <ol...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Comment-Date: Tue, 30 Dec 2025 16:18:47 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Olivier Flückiger <ol...@chromium.org>
    Comment-In-Reply-To: Camillo Bruni <cbr...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Olivier Flückiger (Gerrit)

    unread,
    Jan 8, 2026, 9:10:55 AM (21 hours ago) Jan 8
    to Marja Hölttä, Camillo Bruni, chrom...@appspot.gserviceaccount.com, V8 LUCI CQ, AyeAye, Hannes Payer, leszek...@chromium.org, cbruni...@chromium.org, v8-flag...@chromium.org, victorgo...@chromium.org, verwaes...@chromium.org, dmercadi...@chromium.org, jgrube...@chromium.org, mlippau...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Camillo Bruni and Marja Hölttä

    Olivier Flückiger added 5 comments

    Olivier Flückiger . resolved

    ptal

    File src/diagnostics/objects-debug.cc
    Line 2420, Patchset 31: }
    Camillo Bruni . resolved

    do you plan to allow more values? maybe worth making this stricter here?

    Olivier Flückiger

    Done

    File src/flags/flag-definitions.h
    Line 3943, Patchset 35 (Latest):DEFINE_BOOL(track_array_buffer_views, true,
    Olivier Flückiger . unresolved

    TODO: set to false before landing

    File src/objects/js-array-buffer-inl.h
    Line 186, Patchset 31: DCHECK(value.IsSmi() || value.IsWeak());
    Camillo Bruni . resolved

    could this be a stricter check (kNoView, kManyViews)?

    Olivier Flückiger

    Done

    File src/runtime/runtime.cc
    Line 218, Patchset 31: case Runtime::kArrayBufferDetach:
    Camillo Bruni . unresolved

    nit: I guess we could remove it here?

    Olivier Flückiger

    why? I think we want to have it in differential and normal fuzzing...

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Camillo Bruni
    • Marja Hölttä
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I240ca8523865115a839995489745d8b036830fcb
    Gerrit-Change-Number: 7255835
    Gerrit-PatchSet: 35
    Gerrit-Owner: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Reviewer: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Reviewer: Marja Hölttä <ma...@chromium.org>
    Gerrit-Attention: Marja Hölttä <ma...@chromium.org>
    Gerrit-Attention: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Comment-Date: Thu, 08 Jan 2026 14:10:50 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Camillo Bruni <cbr...@chromium.org>
    unsatisfied_requirement
    open
    diffy

    Marja Hölttä (Gerrit)

    unread,
    4:37 AM (2 hours ago) 4:37 AM
    to Olivier Flückiger, Camillo Bruni, chrom...@appspot.gserviceaccount.com, V8 LUCI CQ, AyeAye, Hannes Payer, leszek...@chromium.org, cbruni...@chromium.org, v8-flag...@chromium.org, victorgo...@chromium.org, verwaes...@chromium.org, dmercadi...@chromium.org, jgrube...@chromium.org, mlippau...@chromium.org, v8-re...@googlegroups.com
    Attention needed from Camillo Bruni and Olivier Flückiger

    Marja Hölttä added 5 comments

    Patchset-level comments
    File-level comment, Patchset 36 (Latest):
    Marja Hölttä . resolved

    i'll have closer look at the logic parts after the new sentinel implementation

    File include/v8-array-buffer.h
    Line 355, Patchset 36 (Latest): V8_DEPRECATED("Only Strings are supported as arguments")
    Marja Hölttä . unresolved

    As discussed offline, no need to do this restriction, if we select the sentinels (many views, no views) in a different way.

    File src/builtins/builtins-arraybuffer.cc
    Line 573, Patchset 36 (Latest): // only fire the TypedArrayResizing protector.
    Marja Hölttä . unresolved

    sounds like this sentence ends a bit abruptly :) "if we cannot" or such is missing

    File test/mjsunit/compiler/typedarray-resizablearraybuffer.js
    Line 249, Patchset 36 (Parent): assertOptimized(Length);
    Marja Hölttä . unresolved

    Why this change? We still kill the protector above...

    File test/mjsunit/maglev/typed-array-length-detached-1.js
    Line 21, Patchset 36 (Parent):assertFalse(isMaglevved(foo));
    Marja Hölttä . unresolved

    Why this change?

    Open in Gerrit

    Related details

    Attention is currently required from:
    • Camillo Bruni
    • Olivier Flückiger
    Submit Requirements:
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedNo-Unresolved-Comments
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: v8/v8
    Gerrit-Branch: main
    Gerrit-Change-Id: I240ca8523865115a839995489745d8b036830fcb
    Gerrit-Change-Number: 7255835
    Gerrit-PatchSet: 36
    Gerrit-Owner: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Reviewer: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Reviewer: Marja Hölttä <ma...@chromium.org>
    Gerrit-Reviewer: Olivier Flückiger <ol...@chromium.org>
    Gerrit-CC: Hannes Payer <hpa...@chromium.org>
    Gerrit-Attention: Olivier Flückiger <ol...@chromium.org>
    Gerrit-Attention: Camillo Bruni <cbr...@chromium.org>
    Gerrit-Comment-Date: Fri, 09 Jan 2026 09:37:12 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    unsatisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages