1--TEST--
2Stack limit 014 - Fuzzer
3--SKIPIF--
4<?php
5if (!function_exists('zend_test_zend_call_stack_get')) die("skip zend_test_zend_call_stack_get() is not available");
6if (getenv("SKIP_SLOW_TESTS")) die('skip slow test');
7$tracing = extension_loaded("Zend OPcache")
8    && ($conf = opcache_get_configuration()["directives"])
9    && array_key_exists("opcache.jit", $conf)
10    &&  $conf["opcache.jit"] === "tracing";
11if (PHP_OS_FAMILY === "Windows" && PHP_INT_SIZE == 8 && $tracing) {
12    $url = "https://github.com/php/php-src/pull/14919#issuecomment-2259003979";
13    die("xfail Test fails on Windows x64 (VS17) and tracing JIT; see $url");
14}
15?>
16--EXTENSIONS--
17zend_test
18--INI--
19; The test may use a large amount of memory on systems with a large stack limit
20memory_limit=1G
21--FILE--
22<?php
23
24try {
25    require __DIR__.'/stack_limit_014.inc';
26} catch (Error $e) {
27    echo $e->getMessage(), "\n";
28}
29
30?>
31--EXPECTF--
32%S%rMaximum call stack size of [0-9]+ bytes \(zend\.max_allowed_stack_size - zend\.reserved_stack_size\) reached|Allowed memory size of [0-9]+ bytes exhausted%r%s
33