Bug #81363 [NEW]: Segfault running PHPStan tests with JIT triggers assertion
| From: | smokey101stair at gmail dot com | Date: | Mon, 16 Aug 2021 00:52:37 +0000 |
| Subject: | Bug #81363 [NEW]: Segfault running PHPStan tests with JIT triggers assertion | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-235832@lists.php.net to get a copy of this message | ||
From: smokey101stair at gmail dot com
Operating system: Ubuntu 20.04/WSL2
PHP version: 8.0.9
Package: JIT
Bug Type: Bug
Bug description:Segfault running PHPStan tests with JIT triggers assertion
Description:
------------
PHP segfaults while running the PHPStan testsuite with the JIT enabled.
PHP 8.0.9 (cli) (built: Aug 14 2021 16:31:22) ( NTS DEBUG )
Copyright (c) The PHP Group
Zend Engine v4.0.9, Copyright (c) Zend Technologies
with Zend OPcache v8.0.9, Copyright (c), by Zend Technologies
opcache.enable_cli=1
opcache.memory_consumption=256
opcache.max_accelerated_files=20000
opcache.jit=1255
opcache.jit_buffer_size=256M
memory_limit=-1
Steps to reproduce:
1) git clone https://github.com/phpstan/phpstan-src.git
2) cd phpstan-src
3) composer install
4) make tests
Actual result:
--------------
#0 __GI_raise (sig=sig@entry=6) at
../sysdeps/unix/sysv/linux/raise.c:50
#1 0x00007fcf9c21f859 in __GI_abort () at abort.c:79
#2 0x00007fcf9c21f729 in __assert_fail_base (fmt=0x7fcf9c3b5588
"%s%s%s:%u: %s%sAssertion `%s' failed.\n%n",
assertion=0x7fcf993cc6fc "info & (1 << type)", file=0x7fcf993cc3d0
"ext/opcache/jit/zend_jit_trace.c", line=340,
function=<optimized out>) at assert.c:92
#3 0x00007fcf9c230f36 in __GI___assert_fail (assertion=0x7fcf993cc6fc
"info & (1 << type)",
file=0x7fcf993cc3d0 "ext/opcache/jit/zend_jit_trace.c", line=340,
function=0x7fcf993cedd0 <__PRETTY_FUNCTION__.29615>
"zend_jit_trace_type_to_info_ex") at assert.c:101
#4 0x00007fcf99376e18 in zend_jit_trace_type_to_info_ex (type=0 '\000',
info=2164258944)
at ext/opcache/jit/zend_jit_trace.c:340
#5 0x00007fcf99377012 in zend_jit_trace_add_op_guard
(tssa=0x7fcf9739e0d0, ssa_var=2, op_type=0 '\000')
at ext/opcache/jit/zend_jit_trace.c:379
#6 0x00007fcf9937c186 in zend_jit_trace_build_tssa
(trace_buffer=0x7ffc7ea4c460, parent_trace=0, exit_num=0,
script=0x0, op_arrays=0x7ffc7ea48240,
num_op_arrays_ptr=0x7ffc7ea47fb0) at
ext/opcache/jit/zend_jit_trace.c:1677
#7 0x00007fcf99385835 in zend_jit_trace (trace_buffer=0x7ffc7ea4c460,
parent_trace=0, exit_num=0)
at ext/opcache/jit/zend_jit_trace.c:3563
#8 0x00007fcf9939f56b in zend_jit_compile_root_trace
(trace_buffer=0x7ffc7ea4c460, opline=0x4349a2d8, offset=5280)
at ext/opcache/jit/zend_jit_trace.c:6510
#9 0x00007fcf993a1575 in zend_jit_trace_hot_root
(execute_data=0x7fcf99417780, opline=0x4349a2d8)
at ext/opcache/jit/zend_jit_trace.c:7003
#10 0x00000000517755c7 in ?? ()
#11 0x0000000000000000 in ?? ()
--
Edit bug report at https://bugs.php.net/bug.php?id=81363&edit=1
--
Fix committed: https://bugs.php.net/fix.php?id=81363&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=81363&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=81363&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=81363&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=81363&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=81363&r=support
Expected behavior: https://bugs.php.net/fix.php?id=81363&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=81363&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=81363&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=81363&r=globals
PHP version support discontinued: https://bugs.php.net/fix.php?id=81363&r=phptooold
Daylight Savings: https://bugs.php.net/fix.php?id=81363&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=81363&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=81363&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=81363&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=81363&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=81363&r=mysqlcfg