diff --git a/ext/opcache/tests/jit/gh15903.phpt b/ext/opcache/tests/jit/gh15903.phpt new file mode 100644 index 00000000000..6acbc27142f --- /dev/null +++ b/ext/opcache/tests/jit/gh15903.phpt @@ -0,0 +1,20 @@ +--TEST-- +GH-15903 (Core dumped in ext/opcache/jit/ir/ir_ra.c) +--EXTENSIONS-- +opcache +--INI-- +opcache.jit=1002 +opcache.jit_buffer_size=64M +--FILE-- +=2 (increasing the number of elements in the array *2 will not do) +foreach (array_fill(0, 389, 'x') as &$params) { //Will not trigger <389 +$x[] = new foo; +} +} +?> +--EXPECTF-- +Fatal error: Uncaught Error: Class "foo" not found in %sgh15903.php:4 +Stack trace: +#0 {main} + thrown in %sh15903.php on line 4