1
0
mirror of https://github.com/php/php-src.git synced 2026-04-04 22:52:40 +02:00
Files
archived-php-src/ext/opcache/tests/jit/loop_001.phpt

23 lines
322 B
PHP

--TEST--
JIT LOOP: 001
--INI--
opcache.enable=1
opcache.enable_cli=1
opcache.file_update_protection=0
opcache.jit_buffer_size=32M
;opcache.jit_debug=257
--EXTENSIONS--
opcache
--FILE--
<?php
function foo($n) {
$res = 0;
for ($i = 1; $i < $n; $i++)
$res = $res + $i;
return $res;
}
print foo(5);
?>
--EXPECT--
10