Bug #78619 [Com]: PHP7.4RC2 ZTS zend_signal_handler_defer crashes on apache shutdown

From: Date: Tue, 01 Oct 2019 10:36:36 +0000
Subject: Bug #78619 [Com]: PHP7.4RC2 ZTS zend_signal_handler_defer crashes on apache shutdown
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-222975@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=78619&edit=1 ID: 78619 Comment by: danack@php.net Reported by: pawel dot filipczak at dynatrace dot com Summary: PHP7.4RC2 ZTS zend_signal_handler_defer crashes on apache shutdown Status: Open Type: Bug Package: Apache2 related Operating System: Linux x64 PHP Version: 7.4.0RC2 Block user comment: N Private report: N New Comment: Possibly relevant info - it appears that the way that PHP shuts down may have changed in PHP 7.4, and as far as I understand it, it appears that thread local storage is being destroyed before all the created threads are terminated. This was seen in Imagick for people using OpenMP - https://github.com/Imagick/imagick/issues/295#issuecomment-515212588 . For that, a hack appears to prevent the problem, which will be replaced by a proper solution when omp_pause_resource_all() is available on more systems. That might be relevant, or not. Previous Comments: ------------------------------------------------------------------------ [2019-10-01 10:22:27] pawel dot filipczak at dynatrace dot com Description: ------------ On Apache/2.4.7 (Unix) PHP/7.4.0RC2 Thread Safe reproduction: apache start open phpinfo test script send SIGINT to apache master process To reproduce, download and call run.sh: https://dynatrace-my.sharepoint.com/:u:/p/pawel_filipczak/EQUzo-CajKxCn1l-WPwrXacBkyMSI183qbWOfX4gqkTtDg?e=omIyyn Test script: --------------- <?php phpinfo(); Expected result: ---------------- exit code 0 Actual result: -------------- (gdb) bt #0 0x00007f4b8024c72b in zend_signal_handler_defer (signo=1, siginfo=0x7f4b1dffa7f0, context=0x7f4b1dffa6c0) at /php-src-php-7.4.0RC2/Zend/zend_signal.c:95 #1 <signal handler called> #2 0x00007f4b8cbd6bb7 in epoll_wait (epfd=8, events=0x1130230, maxevents=50, timeout=100) at ../sysdeps/unix/sysv/linux/epoll_wait.c:30 #3 0x00007f4b8d72c7e1 in impl_pollset_poll (pollset=0x1130188, timeout=<optimized out>, num=0x7f4b1dffaeb8, descriptors=0x7f4b1dffae98) at poll/unix/epoll.c:256 #4 0x00000000004687a3 in listener_thread (thd=0x1131060, dummy=<optimized out>) at event.c:1460 #5 0x00007f4b8d0b16db in start_thread (arg=0x7f4b1dffb700) at pthread_create.c:463 #6 0x00007f4b8cbd688f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95 ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=78619&edit=1

« previous php.bugs (#222975) next »