-
Notifications
You must be signed in to change notification settings - Fork 676
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
opcache.jit=1205 causes an assertion #9350
Comments
Hey @edsrzf, can you reproduce the issue on https://psalm.dev ? |
Can confirm this problem m1 pro. |
Yep, this is an issue with the ARM64 JIT, can reproduce on my pi4 by scanning psalm itself |
I'm afraid switching to tracing JIT will not fix the issue, only postpone it until the JIT decides to compile that code segment when it gets hot enough. The only workaround I see is running |
Anecdotally, I'm able to type-check a large code base using |
Yes it is: php/php-src#10635 |
The fix is released in 5.7.2. |
After updating from 5.6.0 to 5.7.1, I'm seeing an assertion when type-checking my code. It happens often, but not 100% of the time.
If I change
opcache.jit
from1205
to1254
(which is the default), the assertion goes away.System Information
OS: MacOS 13.2.1
CPU: arm64
PHP: 8.1.15
Stack Trace
Code
The code that triggers this assertion is:
(This can't be reproduced with a snippet because the snippet likely runs on a different platform.)
Further Debugging
This is probably a JIT bug in PHP. If I add some debug logging I see some truly unexplainable behavior:
Original code:
With added debugging:
When the assertion triggers, the output of this code is:
So, it's saying 1 !== 1, which is...puzzling, to say the least. Also, if I change the order of the logging and move
var_dump($combinations)
first, the output becomes:The text was updated successfully, but these errors were encountered: