Bug #80014 [Csd->Fbk]: PHP 8.0 beta2 crashes with default JIT flags due to hardware incompatibility
Edit report at https://bugs.php.net/bug.php?id=80014&edit=1
ID: 80014
Updated by: dmitry@php.net
Reported by: buschmann at nidsa dot net
Summary: PHP 8.0 beta2 crashes with default JIT flags due to
hardware incompatibility
-Status: Closed
+Status: Feedback
Type: Bug
Package: JIT
Operating System: Windows 10 Pro 64bit
PHP Version: 8.0.0beta2
Assigned To: dmitry
Block user comment: N
Private report: N
New Comment:
Please check if commit https://github.com/php/php-src/commit/00076ef2b90e2c6ff832d56648d47bddb4d44115
fixes the problem. (It should be included into RC1).
Previous Comments:
------------------------------------------------------------------------
[2020-09-10 06:34:55] dmitry@php.net
Automatic comment on behalf of dmitry@zend.com
Revision: http://git.php.net/?p=php-src.git;a=commit;h=00076ef2b90e2c6ff832d56648d47bddb4d44115
Log: Attempt to fix bug #80014 (PHP 8.0 beta2 crashes with default JIT flags due to hardware
incompatibility)
------------------------------------------------------------------------
[2020-09-07 12:29:57] nikic@php.net
My first suspicion here was that we call zend_jit_setup before zend_cpu_startup, but at least on
linux that's not the case.
One thing I noticed though is that if opcache.jit is changes at runtime and we call zend_jit_config,
nothing will unset the AVX flag at that point anymore.
------------------------------------------------------------------------
[2020-09-07 10:01:05] buschmann at nidsa dot net
As noted in the original message I use the QA download from php web site.
I have no environment to compile/debug php myself.
------------------------------------------------------------------------
[2020-09-07 09:38:28] dmitry@php.net
AVX code generation should be automatically disabled when unsupported:
https://github.com/php/php-src/blob/master/ext/opcache/jit/zend_jit_x86.dasc#L2710
I think, something is wrong with CPUID on Windows.
What compiler do you use to build PHP?
Can you set breakpoint on "zend_jit_setup" and check the content of "cpuinfo"
variable in debugger?
@nikic it's good to have an ability of manual switch at least for testing.
------------------------------------------------------------------------
[2020-09-04 13:45:10] nikic@php.net
I agree that we should be picking avx instructions based on cpuid. @dmitry: What is the reason for
having this as a user-configurable option at all?
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=80014
--
Edit this bug report at https://bugs.php.net/bug.php?id=80014&edit=1
Thread (8 messages)