php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #79932 PHP 8.0 beta1 crashes when used as apache module
Submitted: 2020-08-05 10:45 UTC Modified: 2021-01-24 04:22 UTC
From: buschmann at nidsa dot net Assigned: cmb (profile)
Status: No Feedback Package: JIT
PHP Version: 8.0.0beta1 OS: Windows Server 2019 64bit
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2020-08-05 10:45 UTC] buschmann at nidsa dot net
Description:
------------
For testing I recently switched from PHP 8.0 alpha3 to 8.0beta1 in an otherwise unchanged environment under Windows Server 64 bit.

When trying to show a page or prewarm any script, the following error is shown in Apache error log (the whole sequence of server start and crash):

[Wed Aug 05 11:20:57.000616 2020] [ssl:warn] [pid 2332:tid 588] AH01873: Init: Session Cache is not configured [hint: SSLSessionCache]
[Wed Aug 05 11:20:57.000616 2020] [mpm_winnt:notice] [pid 2332:tid 588] AH00455: Apache/2.4.43 (Win64) OpenSSL/1.1.1g PHP/8.0.0beta1 configured -- resuming normal operations
[Wed Aug 05 11:20:57.000616 2020] [mpm_winnt:notice] [pid 2332:tid 588] AH00456: Apache Lounge VS16 Server built: Apr 21 2020 16:23:13
[Wed Aug 05 11:20:57.000616 2020] [core:notice] [pid 2332:tid 588] AH00094: Command line: 'N:\\Apache\\Apache24\\bin\\httpd.exe -d N:/Apache/Apache24'
[Wed Aug 05 11:20:57.016614 2020] [mpm_winnt:notice] [pid 2332:tid 588] AH00418: Parent: Created child process 1312
[Wed Aug 05 11:20:57.344367 2020] [ssl:warn] [pid 1312:tid 512] AH01873: Init: Session Cache is not configured [hint: SSLSessionCache]
[Wed Aug 05 11:20:57.359992 2020] [mpm_winnt:notice] [pid 1312:tid 512] AH00354: Child: Starting 64 worker threads.
[Wed Aug 05 11:20:58.453743 2020] [mpm_winnt:notice] [pid 2332:tid 588] AH00428: Parent: child process 1312 exited with status 3221225477 -- Restarting.


This sequence is repeated multiple times, always exited with status 3221225477.

PHP is unusable, no further testing possible.

When switching back to 8.0 alpha3, everything works again as before.
Environment:
- Windows server 2019 64bit Standard in a VM under HyperV
- Apache 2.43 64bit from apachelounge
- php 8 beta1 64bit thread safe from php.net QA download
- php loaded as a module with php_module

Download address:

https://windows.php.net/downloads/qa/php-8.0.0beta1-Win32-vs16-x64.zip



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2020-08-05 17:07 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2020-08-05 17:07 UTC] cmb@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.
 [2020-08-06 10:03 UTC] buschmann at nidsa dot net
-Status: Feedback +Status: Assigned -PHP Version: 8.0.0alpha3 +PHP Version: 8.0.0beta1
 [2020-08-06 10:03 UTC] buschmann at nidsa dot net
Crash dump as requested (when loading opcache_gui.php or prewarm with our application):


Report for httpd__PID__4300__Date__08_06_2020__Time_11_43_01AM__275__Second_Chance_Exception_C0000005.dmp





Type of Analysis Performed Crash Analysis 
Machine Name SAM_DEV_HB 
Operating System Windows Server - 17763 
Number Of Processors 2 
Process ID 4300 
Process Image N:\Apache\Apache24\bin\httpd.exe 
Command Line httpd -X 
System Up-Time 18 day(s) 18:08:55 
Process Up-Time 00:10:02 
Processor Type X64 
Process Bitness 64-Bit 



Faulting Thread




Entry point   libhttpd!ap_run_generate_log_id+3ab0 
Create time   06.08.2020 11:32:59 
Time spent in user mode   0 Days 0:0:0.421 
Time spent in kernel mode   0 Days 0:0:0.234 






    Arg 1

    Arg 2

    Arg 3

    Arg 4

  Source

php_opcache!zend_jit_trace_exit_is_hot+68 [C:\php-snap-build\php80\vs16\x64\php-8.0.0beta1-ts\ext\opcache\jit\zend_jit_trace.c @ 5386 + 4]     0000000`00000001     0000072`00000006     00001af`fd3d00d8     0007ff9`55d9490b   C:\php-snap-build\php80\vs16\x64\php-8.0.0beta1-ts\ext\opcache\jit\zend_jit_trace.c @ 5386 + 4 
php_opcache!zend_jit_trace_exit+a76 [C:\php-snap-build\php80\vs16\x64\php-8.0.0beta1-ts\ext\opcache\jit\zend_jit_trace.c @ 5753 + 47]     0001000`00000006     0000072`cebfd4a0     0000000`000000c6     00001af`fd86a500   C:\php-snap-build\php80\vs16\x64\php-8.0.0beta1-ts\ext\opcache\jit\zend_jit_trace.c @ 5753 + 47 
0x00001000`02000613     0000072`cebfd4a0     0000000`000000c6     00001af`fd86a500     0000000`00000003    
0x00001000`00000006     0000000`000000c6     00001af`fd86a500     0000000`00000003     00001af`fd88835c    
0x00000072`cebfd4a0     00001af`fd86a500     0000000`00000003     00001af`fd88835c     0000e50`028ac6b0    
0x000000c6     0000000`00000003     00001af`fd88835c     0000e50`028ac6b0     0000072`cebfd5b0    
0x000001af`fd86a500     00001af`fd88835c     0000e50`028ac6b0     0000072`cebfd5b0     00001af`fd3d00d8    
0x00000003     0000e50`028ac6b0     0000072`cebfd5b0     00001af`fd3d00d8     00001af`fd4a0cf0    
0x000001af`fd88835c     0000072`cebfd5b0     00001af`fd3d00d8     00001af`fd4a0cf0     00001af`fd8123c0    
0x00000e50`028ac6b0     00001af`fd3d00d8     00001af`fd4a0cf0     00001af`fd8123c0     00001af`fd3d00d8    
0x00000072`cebfd5b0     00001af`fd4a0cf0     00001af`fd8123c0     00001af`fd3d00d8     0000000`00000000    
0x000001af`fd3d00d8     00001af`fd8123c0     00001af`fd3d00d8     0000000`00000000     00001af`fd812350    
0x000001af`fd4a0cf0     00001af`fd3d00d8     0000000`00000000     00001af`fd812350     00001af`fab338e0    
0x000001af`fd8123c0     0000000`00000000     00001af`fd812350     00001af`fab338e0     00001af`fd3d00d8    
0x000001af`fd3d00d8     00001af`fd812350     00001af`fab338e0     00001af`fd3d00d8     0000000`00000008    






CLR Information






Exception Information


PHP_OPCACHE!ZEND_JIT_TRACE_EXIT_IS_HOT+68In httpd__PID__4300__Date__08_06_2020__Time_11_43_01AM__275__Second_Chance_Exception_C0000005.dmp the assembly instruction at php_opcache!zend_jit_trace_exit_is_hot+68 in N:\Apache\php8\ext\php_opcache.dll from The PHP Group has caused an access violation exception (0xC0000005) when trying to read from memory location 0x00000006 on thread 97




Module Information 

Image Name: N:\Apache\php8\ext\php_opcache.dll   Symbol Type:  PDB 
Base address: 0x00000003`00905a4d   Time Stamp:  Tue Aug 4 22:51:55 2020  
Checksum: 0x00000000`00000000   Comments:  Thanks to Andi Gutmans, Zeev Suraski, Stanislav Malyshev, Dmitry Stogov, Xinchen Hui 
COM DLL: False   Company Name:  The PHP Group 
ISAPIExtension: False   File Description:  Opcache 
ISAPIFilter: False   File Version:  8.0.0beta1 
Managed DLL: False   Internal Name:  OPCACHE extension 
VB DLL: False   Legal Copyright:  Copyright © The PHP Group 
Loaded Image Name:  php_opcache.dll   Legal Trademarks:  PHP 
Mapped Image Name:     Original filename:  php_opcache.dll 
Module name:  php_opcache   Private Build:   
Single Threaded:  False   Product Name:  PHP 
Module Size:  1,46 MBytes   Product Version:  8.0.0beta1 
Symbol File Name:  n:\apache\php8debug\php_opcache.pdb   Special Build:  &
 [2020-08-06 10:16 UTC] cmb@php.net
-Status: Assigned +Status: Open -Package: Reproducible crash +Package: JIT -Assigned To: cmb +Assigned To:
 [2020-08-06 10:16 UTC] cmb@php.net
Thanks!  This is apparently a tracing JIT issue.  Please try with

  opcache.jit=1205
 [2020-08-06 13:06 UTC] buschmann at nidsa dot net
When set

opcache.jit=1205

the opcache_gui and prewarm and a quick test of the application seem OK now.
(Only tested in httpd -X mode for now)

It seems I cannot provide more info to come to the root cause.

Thanks for investigating.
 [2021-01-15 14:39 UTC] cmb@php.net
-Status: Open +Status: Feedback -Assigned To: +Assigned To: cmb
 [2021-01-15 14:39 UTC] cmb@php.net
Is this still an issue with PHP 8.0.1?
 [2021-01-24 04:22 UTC] php-bugs at lists dot php dot net
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Re-Opened". Thank you.
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Fri Sep 17 05:03:37 2021 UTC