The Daily Commit · Section Edition Front Page PHP AI Dev EN DE FR ES

The Php Times

RFC Watch — Ecosystem

New PHP RFC Proposes Pluggable Coroutine Scheduler for the Zend Engine


A new PHP RFC by Edmond Dantes proposes giving the Zend Engine a native coroutine representation and a pluggable scheduler interface implementable via extensions, without adding any new PHP syntax, functions or classes.

PHP INTERNALS ([RFC]/[VOTE]), July 23, 2026 curated by Sönke

Distinct from the earlier True Async RFC, it ships a working php-src pull request and lets schedulers adopt fibers from ReactPHP, Revolt or AMPHP.

PHP developer Edmond Dantes has opened discussion on a new RFC, "Concurrency Support in the PHP Engine" (wiki.php.net/rfc/async_scheduler_abi), proposing to give the Zend Engine a native coroutine representation and a pluggable scheduler component that extensions can implement. The proposal introduces no new PHP-level classes, functions, constants or syntax; with no scheduler registered, PHP's behavior stays exactly as it is today.

The RFC is explicitly not the previously discussed "True Async" RFC, but a minimal engine-level core extracted from that work. It defines an activation contract, engine-raised notifications, a mechanism letting fibers be adopted by a scheduler, and per-coroutine storage. User-facing concurrency APIs such as spawn(), await() and channels would remain the responsibility of extensions, with True Async positioned as just one possible provider built on top of this core.

A working implementation is already available as pull request php/php-src#22561 on GitHub, authored by Dantes. It includes an in-tree reference scheduler extension, ext/test_scheduler, disabled by default, which fills every scheduler slot using ordinary extension code; PHP's existing test suites reportedly run unmodified in schedulerless mode within the same binary. A separate, out-of-tree bridge extension implementing a scheduler in plain PHP serves as proof that the proposed interface is sufficient for real use.

For existing async libraries, the design lets a scheduler adopt fibers already started by ReactPHP, Revolt or AMPHP, on a per-fiber, optional basis. The added per-coroutine storage is meant to eventually make functions like ob_start() coroutine-safe. Dantes stresses that the proposal introduces no goroutines and no true parallelism — execution stays confined to a single OS thread.

Read the original source ↗

Rate this article: 0

Readers’ Forum

No contributions yet — open the debate.

← Ecosystem — Page B1

"All the Code That's Fit to Ship" · The Daily Commit · Screen edition · Imprint · Privacy Policy