[php-src] Issue #12382: JIT Index invalid or out of range error
| From: | danog | Date: | Sun, 08 Oct 2023 01:10:40 +0000 |
| Subject: | [php-src] Issue #12382: JIT Index invalid or out of range error | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-245515@lists.php.net to get a copy of this message | ||
Issue: https://github.com/php/php-src/issues/12382
Author: danog
### Description
The following code: https://paste.daniil.it/BaconQrCode.tar.xz,
which is https://github.com/Bacon/BaconQrCode/
with an additional unit test that reproduces the issue.
Ref https://github.com/Bacon/BaconQrCode/issues/92
Resulted in this output:
```
php -d opcache.enable_cli=1 -d opcache.jit=tracing -d opcache.jit_buffer_size=1G -d
opcache.jit_max_root_traces=1000000 -d opcache.jit_max_side_traces=1000000 -d
opcache.jit_max_exit_counters=1000000 -d opcache.jit_hot_loop=1 -d opcache.jit_hot_func=1 -d
opcache.jit_hot_return=1 -d opcache.jit_hot_side_exit=1 -d memory_limit=-1 vendor/bin/phpunit
PHPUnit 9.6.13 by Sebastian Bergmann and contributors.
............................................................... 63 / 159 ( 39%)
..........................................................E.... 126 / 159 ( 79%)
...............................SS 159 / 159 (100%)
Time: 00:01.736, Memory: 6.00 MB
There was 1 error:
1) BaconQrCodeTest\Encoder\EncoderTest::testSimpleUtf8WithoutEci
RuntimeException: Index invalid or out of range
/root/BaconQrCode/src/Encoder/MaskUtil.php:134
/root/BaconQrCode/src/Encoder/Encoder.php:199
/root/BaconQrCode/src/Encoder/Encoder.php:246
/root/BaconQrCode/src/Encoder/Encoder.php:137
/root/BaconQrCode/test/Encoder/EncoderTest.php:166
ERRORS!
Tests: 159, Assertions: 79764, Errors: 1, Skipped: 2.
```
But I expected this output instead: no failed tests.
### PHP Version
https://github.com/php/php-src/pull/12381
### Operating System
_No response_