Skip to content

Commit 4b35586

Browse files
committed
add test to verify clang 19+ -> tailcall vm
1 parent 7e287d5 commit 4b35586

1 file changed

Lines changed: 24 additions & 0 deletions

File tree

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
--TEST--
2+
Tailcall VM is selected when compiled with Clang >= 19 on Windows
3+
--SKIPIF--
4+
<?php
5+
if (PHP_OS_FAMILY !== 'Windows') die('skip Windows only');
6+
7+
ob_start();
8+
phpinfo(INFO_GENERAL);
9+
$info = ob_get_clean();
10+
11+
if (!preg_match('/Compiler => clang version (\d+)/', $info, $m)) {
12+
die('skip not compiled with clang');
13+
}
14+
15+
if ((int)$m[1] < 19) {
16+
die('skip requires clang >= 19');
17+
}
18+
?>
19+
--FILE--
20+
<?php
21+
var_dump(ZEND_VM_KIND);
22+
?>
23+
--EXPECT--
24+
string(21) "ZEND_VM_KIND_TAILCALL"

0 commit comments

Comments
 (0)