[php-src] PHP-8.6: Merge branch 'PHP-8.5' into PHP-8.6

From: Date: Tue, 03 Nov 2026 21:04:03 +0000
Subject: [php-src] PHP-8.6: Merge branch 'PHP-8.5' into PHP-8.6
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-143295@lists.php.net to get a copy of this message
Author: ndossche (ndossche) Date: 2026-11-03T22:03:38+01:00 Commit: https://github.com/php/php-src/commit/3fd74fcba6b6a90766c700039c3b69982037a5cd Raw diff: https://github.com/php/php-src/commit/3fd74fcba6b6a90766c700039c3b69982037a5cd.diff Merge branch 'PHP-8.5' into PHP-8.6 * PHP-8.5: Fixed GH-22216: don't warn in OnUpdateMemoryConsumption on ZTS thread init Changed paths: M NEWS M ext/opcache/zend_accelerator_module.c Diff: diff --git a/NEWS b/NEWS index e161eb54555c..03af9f491a52 100644 --- a/NEWS +++ b/NEWS @@ -2,6 +2,10 @@ PHP NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? ????, PHP 8.6.1 +- Opcache: + . Fixed bug GH-22216 (spurious opcache.memory_consumption warning on each new + ZTS thread; the directive is also reported as 0 in worker threads). + (Daisuke Komazaki) 05 Nov 2026, PHP 8.6.0RC5 diff --git a/ext/opcache/zend_accelerator_module.c b/ext/opcache/zend_accelerator_module.c index aa8826e69f16..2c290d8d5f8a 100644 --- a/ext/opcache/zend_accelerator_module.c +++ b/ext/opcache/zend_accelerator_module.c @@ -76,7 +76,9 @@ static bool validate_api_restriction(void) static ZEND_INI_MH(OnUpdateMemoryConsumption) { - if (accel_startup_ok) { + /* On ZTS, each new thread runs the on_modify handlers at STAGE_STARTUP to + * populate its own globals; that is thread init, not a post-startup change. */ + if (accel_startup_ok && stage != ZEND_INI_STAGE_STARTUP) { if (strcmp(sapi_module.name, "fpm-fcgi") == 0) { zend_accel_error(ACCEL_LOG_WARNING, "opcache.memory_consumption cannot be changed when OPcache is already set up. Are you using php_admin_value[opcache.memory_consumption] in an individual pool's configuration?\n"); } else {

« previous php.cvs (#143295) next »