3v4l.org

run code in 300+ PHP versions simultaneously
<?php $foo = '112312312312323'; $start_time = microtime(true); for ($i = 0; $i < 10000; $i++) { $foo = $foo.'1'; preg_match('/^[a-zA-Z0-9]+$/', $foo); // Result: 0.094325065612793 } $end_time = microtime(true); echo 'preg_match Result: ' . ($end_time - $start_time).PHP_EOL; $foo = '112312312312323'; $start_time = microtime(true); for ($i = 0; $i < 10000; $i++) { $foo = $foo.'1'; ctype_alnum($foo); // Result: 1.8465659618378 } $end_time = microtime(true); echo 'ctype Result: ' . ($end_time - $start_time).PHP_EOL;
Output for git.master
preg_match Result: 0.029053926467896 ctype Result: 0.014615774154663
Output for git.master_jit
preg_match Result: 0.028779029846191 ctype Result: 0.014615774154663
Output for rfc.property-hooks
preg_match Result: 0.054904937744141 ctype Result: 0.12333703041077

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
28.02 ms | 413 KiB | 5 Q