Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:99049 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 53813 invoked from network); 15 May 2017 15:32:25 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 15 May 2017 15:32:25 -0000 Authentication-Results: pb1.pair.com header.from=derick@php.net; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=derick@php.net; spf=unknown; sender-id=unknown Received-SPF: unknown (pb1.pair.com: domain php.net does not designate 82.113.146.227 as permitted sender) X-PHP-List-Original-Sender: derick@php.net X-Host-Fingerprint: 82.113.146.227 xdebug.org Received: from [82.113.146.227] ([82.113.146.227:54020] helo=xdebug.org) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DA/8C-15531-70AC9195 for ; Mon, 15 May 2017 11:32:23 -0400 Received: from localhost (localhost [IPv6:::1]) by xdebug.org (Postfix) with ESMTPS id 09FAC10C650; Mon, 15 May 2017 16:32:19 +0100 (BST) Date: Mon, 15 May 2017 16:32:19 +0100 (BST) X-X-Sender: derick@singlemalt.home.derickrethans.nl To: Dmitry Stogov cc: PHP internals list , Nikita Popov , Xinchen Hui , Sara Golemon , Zeev Suraski In-Reply-To: Message-ID: References: User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: multipart/mixed; BOUNDARY="8323329-1641291057-1494862340=:2467" Subject: Re: [PHP-DEV] HYBRID VM From: derick@php.net (Derick Rethans) --8323329-1641291057-1494862340=:2467 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: QUOTED-PRINTABLE Hi! On Mon, 15 May 2017, Dmitry Stogov wrote: > Recently, I committed HYBRID VM into master, but didn't enable it by=20 > default yet. >=20 > It provides significant performance improvement on small benchmarks=20 > (1.5 times faster on bench.php) and slight improvement on real-life=20 > apps (1-2% on wordpress). Currently it improves PHP only on x86,=20 > x86_64 and PPC compiled with GCC. It also crashes instantly when Xdebug is loaded. I think we should=20 resolve that before making it default for 7.2 and above. >=20 > Now, after additional testing, I like to make HYBRID VM the default VM fo= r PHP-7.2 and above. >=20 > I would glad to do this without RFC, because it's a self containing chang= e that doesn't affect anything except the VM itself. >=20 > It may only break some "system" PHP extensions (debuggers, profilers), th= at relay on CALL VM implementation. >=20 > phpdbg and xdebug are not affected and work out of the box. Uh? Definitely just segfaults here: Number of tests : 476 388 Tests skipped : 88 ( 18.5%) -------- Tests warned : 0 ( 0.0%) ( 0.0%) Tests failed : 384 ( 80.7%) ( 99.0%) Expected fail : 0 ( 0.0%) ( 0.0%) Tests passed : 4 ( 0.8%) ( 1.0%) derick@singlemalt:~/dev/php/xdebug-xdebug $ cat tests/001.php [GIT: master][PHP: 7.2.0-dev ] derick@singlemalt:~/dev/php/xdebug-xdebug $ gdb --args /usr/local/php/trunk= /bin/php -n -c '/home/derick/dev/php/xdebug-xdebug/tmp-php.ini' -d "outpu= t_handler=3D" -d "open_basedir=3D" -d "disable_functions=3D" -d "output_buf= fering=3DOff" -d "error_reporting=3D32767" -d "display_errors=3D1" -d "disp= lay_startup_errors=3D1" -d "log_errors=3D0" -d "html_errors=3D0" -d "track_= errors=3D0" -d "report_memleaks=3D1" -d "report_zend_debug=3D0" -d "docref_= root=3D" -d "docref_ext=3D.html" -d "error_prepend_string=3D" -d "error_app= end_string=3D" -d "auto_prepend_file=3D" -d "auto_append_file=3D" -d "ignor= e_repeated_errors=3D0" -d "precision=3D14" -d "memory_limit=3D128M" -d "log= _errors_max_len=3D0" -d "opcache.fast_shutdown=3D0" -d "opcache.file_update= _protection=3D0" -d "extension_dir=3D/home/derick/dev/php/xdebug-xdebug/mod= ules/" -d "zend_extension=3D/home/derick/dev/php/xdebug-xdebug/modules/xdeb= ug.so" -d "session.auto_start=3D0" -d "zlib.output_compression=3DOff" -d "x= debug.default_enable=3D0" -d "mbstring.func_overload=3D0" -d "xdebug.profil= er_enable=3D0" -f "/home/derick/dev/php/xdebug-xdebug/tests/001.php"=20 GNU gdb (Debian 7.12-6) 7.12.0.20161007-git Copyright (C) 2016 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: . Find the GDB manual and other documentation resources online at: . For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from /usr/local/php/trunk/bin/php...done. (gdb) run Starting program: /usr/local/php/trunk/bin/php -n -c /home/derick/dev/php/x= debug-xdebug/tmp-php.ini -d output_handler=3D -d open_basedir=3D -d disable= _functions=3D -d output_buffering=3DOff -d error_reporting=3D32767 -d displ= ay_errors=3D1 -d display_startup_errors=3D1 -d log_errors=3D0 -d html_error= s=3D0 -d track_errors=3D0 -d report_memleaks=3D1 -d report_zend_debug=3D0 -= d docref_root=3D -d docref_ext=3D.html -d error_prepend_string=3D -d error_= append_string=3D -d auto_prepend_file=3D -d auto_append_file=3D -d ignore_r= epeated_errors=3D0 -d precision=3D14 -d memory_limit=3D128M -d log_errors_m= ax_len=3D0 -d opcache.fast_shutdown=3D0 -d opcache.file_update_protection= =3D0 -d extension_dir=3D/home/derick/dev/php/xdebug-xdebug/modules/ -d zend= _extension=3D/home/derick/dev/php/xdebug-xdebug/modules/xdebug.so -d sessio= n.auto_start=3D0 -d zlib.output_compression=3DOff -d xdebug.default_enable= =3D0 -d mbstring.func_overload=3D0 -d xdebug.profiler_enable=3D0 -f /home/d= erick/dev/php/xdebug-xdebug/tests/001.php [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1". xdebug extension is available Program received signal SIGSEGV, Segmentation fault. 0x0000555555e4c8f9 in execute_ex (ex=3D0x555555dd02ff ) at /home/derick/dev/php/php-src.git/Zend/zend_vm_execute.h:= 59065 59065=09=09=09=09=09HYBRID_BREAK(); (gdb) bt #0 0x0000555555e4c8f9 in execute_ex (ex=3D0x555555dd02ff ) at /home/derick/dev/php/php-src.git/Zend/zend_vm_execut= e.h:59065 #1 0x0000555555e4c8f6 in execute_ex (ex=3D0x555555dd02ff ) at /home/derick/dev/php/php-src.git/Zend/zend_vm_execut= e.h:59064 #2 0x0000555555e4c8f6 in execute_ex (ex=3D0x7ffff1a1f030) at /home/derick/= dev/php/php-src.git/Zend/zend_vm_execute.h:59064 #3 0x00007ffff17be907 in xdebug_execute_ex (execute_data=3D0x7ffff1a1f030)= at /home/derick/dev/php/xdebug-xdebug/xdebug.c:1795 #4 0x0000555555e51a1d in zend_execute (op_array=3D0x7ffff1a83300, return_v= alue=3D0x0) at /home/derick/dev/php/php-src.git/Zend/zend_vm_execute.h:6294= 9 #5 0x0000555555d6d7f6 in zend_execute_scripts (type=3D8, retval=3D0x0, fil= e_count=3D3) at /home/derick/dev/php/php-src.git/Zend/zend.c:1537 #6 0x0000555555cdbd82 in php_execute_script (primary_file=3D0x7fffffffd7c0= ) at /home/derick/dev/php/php-src.git/main/main.c:2548 #7 0x0000555555e5408e in do_cli (argc=3D68, argv=3D0x5555569c5e70) at /hom= e/derick/dev/php/php-src.git/sapi/cli/php_cli.c:997 #8 0x0000555555e55048 in main (argc=3D68, argv=3D0x5555569c5e70) at /home/= derick/dev/php/php-src.git/sapi/cli/php_cli.c:1390 (gdb)=20 Latest Xdebug from GitHub. cheers, Derick --=20 https://derickrethans.nl | https://xdebug.org | https://dram.io Like Xdebug? Consider a donation: https://xdebug.org/donate.php twitter: @derickr and @xdebug --8323329-1641291057-1494862340=:2467--