[php-src] PR #24275: Fix opcache.interned_strings_buffer being 0 in threads started later (ZTS)

From: Date: Mon, 12 Oct 2026 13:38:12 +0000
Subject: [php-src] PR #24275: Fix opcache.interned_strings_buffer being 0 in threads started later (ZTS)
Groups: php.git-pulls 
Request: Send a blank email to git-pulls+get-39359@lists.php.net to get a copy of this message
Pull Request: https://github.com/php/php-src/pull/24275 Author: pavimus Prepared with an AI assistant (Claude), which also ran the reproduction and the tests on my machine; I reviewed the result. The text below is AI-generated (quoted, as asked in CONTRIBUTING.md). > Under ZTS, threads started after OPcache's startup end up with > opcache.interned_strings_buffer = 0 and log a warning each; a > regression from GH-23309 (PHP 8.4.26). > > Since GH-23309 (PHP 8.4.26) OnUpdateInternedStringsBuffer() > rejects any change once OPcache is > set up. Under ZTS every thread started after OPcache's startup re-applies the INI entries > with > ZEND_INI_STAGE_STARTUP into its own zeroed > zend_accel_globals; the handler rejects that, logs a > warning for every new thread ("opcache.interned_strings_buffer cannot be changed when > OPcache is > already set up.", seen once per thread in Apache error logs and FrankenPHP) and leaves the > directive at 0 in that thread (opcache_get_configuration() > reports 0). > > Accept the value at ZEND_INI_STAGE_STARTUP (the one SHM was set > up with); changes at later > stages, like FPM pools (ZEND_INI_STAGE_ACTIVATE), are still > rejected as intended by GH-23309. > Verified from a FrankenPHP worker thread: 0 -> 8, no warnings. > > No test: the problem needs a thread started after startup (FrankenPHP, Apache threaded MPM). 🤖 Generated with [Claude Code](https://claude.com/claude-code)

« previous php.git-pulls (#39359) next »