Closed andypost closed 3 years ago
It's using latest releases PHP 8.0.0 and XHProf 2.2.3
@andypost Can you provide some options for compiling php8? I cannot reproduce the segfault
@andypost Can you provide some options for compiling php8?
All options could be found in https://git.alpinelinux.org/aports/tree/testing/php8/APKBUILD#n215 (PHP) I use no extra options for https://git.alpinelinux.org/aports/tree/testing/php8-pecl-xhprof/APKBUILD#n21
I used the same source and there was no segfault
PHP 8.0.0 (cli) (built: Nov 26 2020 15:10:48) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.0-dev, Copyright (c) Zend Technologies
[PHP Modules]
Core
ctype
date
filter
hash
json
libxml
pcre
readline
Reflection
SPL
standard
xhprof
zlib
php8 -dopcache.jit_buffer_size=10M -S 0.0.0.0:44543
[Tue Dec 1 11:30:13 2020] PHP 8.0.0 Development Server (http://0.0.0.0:44543) started
[Tue Dec 1 11:30:25 2020] 127.0.0.1:50482 Accepted
[Tue Dec 1 11:30:25 2020] 127.0.0.1:50482 [200]: GET /test.php
[Tue Dec 1 11:30:25 2020] 127.0.0.1:50482 Closing
Thank you, looks it depends on what script is executed, I can reproduce it with Drupal but will try other apps
@andypost Sorry, I misunderstood what you meant, I should know what's going on
@andypost I didn't find the corresponding docker image, can you provide it to me?
@longxinH I will dig it this weekend and prepare docker image to easy reproduce
No need, this is a PHP bug that will be fixed in 8.0.1 https://bugs.php.net/bug.php?id=80426
Edit: Right now having an extension with zend_execute_ex
hook and enabling the JIT will always crash.
@andypost Hello, has the latest version 8.0.2 solved this problem?
Use to try with 8.0.3 and now I see different message
$ docker run --rm -it alpine:edge ash
/ # apk add php8 php8-opcache php8-pecl-xhprof
...
/ # php8 -dopcache.jit_buffer_size=10M -S 0.0.0.0:44543
[Sat Mar 27 02:49:25 2021] PHP Warning: JIT is incompatible with third party extensions that override zend_execute_ex(). JIT disabled. in Unknown on line 0
[Sat Mar 27 02:49:25 2021] PHP 8.0.3 Development Server (http://0.0.0.0:44543) started
^C
btw tideways_xhprof works for some reason (probably because using observer API)
Yes i added observer API support here https://github.com/tideways/php-xhprof-extension/pull/96
@andypost Try if it works ?
Will do in 2 hours
@longxinH Thank you a lot! it works on all arches https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/19953 - PHP 7.4 and 8.0 at least, and code changes looks like great clean-up - are you going to release 2.3.0 beta or stable?
@andypost 2.3.0 I want to release Beta, because there is a lack of a lot of test data
Sure, I used to try add test for opcache but stuck with config
@longxinH I think release is good, as then people come back with bug reports. Unlikely people build from git@HEAD to test things, but installing beta from pecl -> definitely some!
@glensc Yes, release 2.3.0 Beta in pecl
@andypost @glensc release https://pecl.php.net/package/xhprof/2.3.0
Just used to try use Drupal 9-dev using JIT and the extension
PS: using latest build packages from Alpinelinux (will check official docker images when they out)