Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 771e7c42bc494b463800e4a87a032b99af72800d
      
https://github.com/WebKit/WebKit/commit/771e7c42bc494b463800e4a87a032b99af72800d
  Author: Yusuke Suzuki <[email protected]>
  Date:   2026-07-21 (Tue, 21 Jul 2026)

  Changed paths:
    A JSTests/stress/async-iterator-tla-cached-result.js
    A JSTests/stress/async-iterator-tla-fast-consumer.js
    A JSTests/stress/resources/async-iterator-tla-basic.js
    A JSTests/stress/resources/async-iterator-tla-cached-aliasing.js
    A JSTests/stress/resources/async-iterator-tla-cached-fast.js
    A JSTests/stress/resources/async-iterator-tla-cached-mid-lifetime.js
    A JSTests/stress/resources/async-iterator-tla-error.js
    A JSTests/stress/resources/async-iterator-tla-ruler-fast.js
    A JSTests/stress/resources/async-iterator-tla-ruler-generic.js
    M Source/JavaScriptCore/bytecompiler/BytecodeGenerator.cpp
    M Source/JavaScriptCore/runtime/JSAsyncGeneratorInlines.h
    M Source/JavaScriptCore/runtime/JSMicrotask.cpp
    M Source/JavaScriptCore/runtime/JSMicrotask.h
    M Source/JavaScriptCore/runtime/JSModuleRecord.cpp
    M Source/JavaScriptCore/runtime/JSModuleRecord.h

  Log Message:
  -----------
  [JSC] Use cooperative driving in TLA modules
https://bugs.webkit.org/show_bug.cgi?id=319867
rdar://182767755

Reviewed by Yijia Huang.

This patch extends support of cooperative driving to cover TLA modules.
The core change is accepting JSModuleRecord as a driver. And the change
is really minimum. The benefit is now bytecode generation becomes
simpler since we can always use the cooperative driving code.

Tests: JSTests/stress/async-iterator-tla-cached-result.js
       JSTests/stress/async-iterator-tla-fast-consumer.js

* JSTests/stress/async-iterator-tla-cached-result.js: Added.
(shouldBe):
(track):
(track.import.string_appeared_here.then):
(then):
* JSTests/stress/async-iterator-tla-fast-consumer.js: Added.
(assert):
(assertArrayEq):
(track):
(import.string_appeared_here.then):
(import.string_appeared_here.then.import.string_appeared_here.then):
* JSTests/stress/resources/async-iterator-tla-basic.js: Added.
(async g):
(async g2):
(async inner):
(async outer):
* JSTests/stress/resources/async-iterator-tla-cached-aliasing.js: Added.
(get if):
* JSTests/stress/resources/async-iterator-tla-cached-fast.js: Added.
(async g):
* JSTests/stress/resources/async-iterator-tla-cached-mid-lifetime.js: Added.
(async g):
(get delete):
* JSTests/stress/resources/async-iterator-tla-error.js: Added.
(async g):
* JSTests/stress/resources/async-iterator-tla-ruler-fast.js: Added.
(async g):
* JSTests/stress/resources/async-iterator-tla-ruler-generic.js: Added.
(const.asyncGenProto.Object.getPrototypeOf.Object.getPrototypeOf):
(asyncGenProto.next):
(async const):
(async g):
* Source/JavaScriptCore/bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::emitEnumeration):
* Source/JavaScriptCore/runtime/JSAsyncGeneratorInlines.h:
(JSC::JSAsyncGenerator::enqueue):
* Source/JavaScriptCore/runtime/JSMicrotask.cpp:
(JSC::asyncModuleExecutionDone):
(JSC::asyncModuleResolveEvaluation):
(JSC::asyncModuleExecutionResume):
(JSC::asyncGeneratorDriverResume):
(JSC::runInternalMicrotask):
* Source/JavaScriptCore/runtime/JSMicrotask.h:
* Source/JavaScriptCore/runtime/JSModuleRecord.cpp:
(JSC::JSModuleRecord::isTopLevelExecutionFinished const):
(JSC::JSModuleRecord::evaluate):
(JSC::JSModuleRecord::execute):
* Source/JavaScriptCore/runtime/JSModuleRecord.h:

Canonical link: https://commits.webkit.org/317629@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to