diff --git a/NEWS b/NEWS index 2d92594daf3..669c8e85b9f 100644 --- a/NEWS +++ b/NEWS @@ -27,6 +27,8 @@ PHP NEWS . Fixed bug GH-15367 (dl() of module with aliased class crashes in shutdown). (Arnaud) . Fixed OSS-Fuzz #403308724. (nielsdos) + . Fixed bug GH-13193 again (Significant performance degradation in 'foreach'). + (nielsdos) - DBA: . Fixed assertion violation when opening the same file with dba_open diff --git a/Zend/zend_gc.c b/Zend/zend_gc.c index a966a106def..f73fef50e16 100644 --- a/Zend/zend_gc.c +++ b/Zend/zend_gc.c @@ -1917,7 +1917,7 @@ ZEND_API int zend_gc_collect_cycles(void) bool did_rerun_gc = 0; zend_hrtime_t start_time = zend_hrtime(); - if (GC_G(num_roots) && GC_G(gc_active)) { + if (GC_G(num_roots) && !GC_G(gc_active)) { zend_gc_remove_root_tmpvars(); }