3v4l.org

run code in 300+ PHP versions simultaneously
<?php function sphinxesc($x){ $depth = 0; for ($i = 0; $i < strlen($x); ++$i){ $depth += $x[$i] == '(' ? 1 : 0; $depth -= $x[$i] == ')' ? 1 : 0; } if($depth != 0) $x = str_replace(array('(',')'),' ',$x); $x = str_replace(array('/','~','@'), ' ',$x); $x = preg_replace('/[\!\-\^]+(?!\w)/', ' ',$x); } echo sphinxesc('hi! this is shit!');

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
8.3.60.0220.00016.63
8.3.50.0060.01221.23
8.3.40.0060.01519.09
8.3.30.0120.00318.69
8.3.20.0000.00820.25
8.3.10.0030.00521.96
8.3.00.0040.00423.52
8.2.180.0120.00916.50
8.2.170.0090.00622.96
8.2.160.0130.00720.23
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0050.00319.95
8.2.120.0040.00426.35
8.2.110.0060.00319.27
8.2.100.0070.00418.16
8.2.90.0040.00419.21
8.2.80.0040.00417.97
8.2.70.0030.00518.00
8.2.60.0000.00817.93
8.2.50.0070.00318.10
8.2.40.0030.00620.47
8.2.30.0050.00319.56
8.2.20.0000.00817.99
8.2.10.0000.00818.18
8.2.00.0000.00718.21
8.1.280.0080.01325.92
8.1.270.0050.00324.02
8.1.260.0050.00328.09
8.1.250.0050.00328.09
8.1.240.0050.00522.62
8.1.230.0080.00417.70
8.1.220.0000.00817.91
8.1.210.0030.00518.77
8.1.200.0000.00817.60
8.1.190.0040.00417.61
8.1.180.0000.00818.10
8.1.170.0040.00418.80
8.1.160.0040.00422.06
8.1.150.0040.00418.86
8.1.140.0040.00419.71
8.1.130.0000.00717.68
8.1.120.0070.00017.61
8.1.110.0040.00417.63
8.1.100.0060.00317.54
8.1.90.0040.00417.52
8.1.80.0020.00517.64
8.1.70.0040.00417.64
8.1.60.0040.00417.65
8.1.50.0030.00517.72
8.1.40.0050.00317.72
8.1.30.0030.00617.82
8.1.20.0000.00817.72
8.1.10.0000.00817.66
8.1.00.0030.00517.69
8.0.300.0060.00318.77
8.0.290.0030.00516.75
8.0.280.0070.00018.51
8.0.270.0030.00317.22
8.0.260.0030.00317.26
8.0.250.0000.00717.12
8.0.240.0060.00317.13
8.0.230.0080.00016.96
8.0.220.0030.00317.05
8.0.210.0030.00616.95
8.0.200.0030.00617.11
8.0.190.0080.00017.10
8.0.180.0020.00517.07
8.0.170.0090.00017.05
8.0.160.0040.00417.02
8.0.150.0030.00316.96
8.0.140.0040.00416.95
8.0.130.0030.00313.39
8.0.120.0080.00016.93
8.0.110.0070.00017.11
8.0.100.0070.00017.03
8.0.90.0000.00816.91
8.0.80.0040.01116.95
8.0.70.0030.00516.86
8.0.60.0000.00717.19
8.0.50.0040.00416.98
8.0.30.0110.00817.46
8.0.20.0150.00717.46
8.0.10.0000.00817.16
8.0.00.0110.00817.02
7.4.330.0050.00016.84
7.4.320.0030.00316.88
7.4.300.0030.00316.74
7.4.290.0080.00016.64
7.4.280.0030.00616.69
7.4.270.0000.00716.82
7.4.260.0030.00616.72
7.4.250.0020.00516.67
7.4.240.0060.00116.63
7.4.230.0030.00316.91
7.4.220.0150.00916.79
7.4.210.0000.01516.85
7.4.200.0030.00516.91
7.4.160.0200.00316.96
7.4.150.0110.00717.40
7.4.140.0050.01217.86
7.4.130.0120.00616.63
7.4.120.0100.00916.80
7.4.110.0070.01216.64
7.4.100.0100.01016.65
7.4.90.0090.01016.63
7.4.80.0030.01419.39
7.4.70.0100.00716.69
7.4.60.0130.00316.76
7.4.50.0040.01116.68
7.4.40.0080.00816.71
7.4.30.0070.01016.66
7.4.00.0130.00315.05
7.3.330.0040.00413.54
7.3.320.0050.00013.54
7.3.310.0070.00016.40
7.3.300.0070.00016.42
7.3.290.0070.00816.51
7.3.280.0090.01016.51
7.3.270.0090.00917.40
7.3.260.0120.00916.53
7.3.240.0090.00816.59
7.3.230.0150.00416.69
7.3.210.0100.00716.73
7.3.200.0160.00019.39
7.3.190.0100.01016.74
7.3.180.0120.00616.46
7.3.170.0070.01416.73
7.3.160.0070.01016.61
7.2.330.0100.01316.79
7.2.320.0070.01416.66
7.2.310.0100.00716.80
7.2.300.0140.00916.79
7.2.290.0130.01916.90
7.2.00.0000.01419.31
7.1.100.0070.00718.46
7.1.70.0050.00517.43
7.1.60.0100.01419.28
7.1.50.0190.01217.24
7.1.00.0130.06322.27
7.0.200.0210.01115.02
7.0.60.0030.08321.73
7.0.50.0030.08317.81
7.0.40.0070.08020.26
7.0.30.0200.04720.11
7.0.20.0300.08020.24
7.0.10.0230.06320.21
7.0.00.0130.08320.08
5.6.280.0030.04721.13
5.6.210.0030.05720.77
5.6.200.0100.07718.16
5.6.190.0030.04020.66
5.6.180.0300.05020.39
5.6.170.0330.06720.47
5.6.160.0000.05320.50
5.6.150.0100.04318.17
5.6.140.0070.04718.29
5.6.130.0070.09318.14
5.6.120.0100.07020.99
5.6.110.0030.07321.02
5.6.100.0100.07721.14
5.6.90.0130.07720.98
5.6.80.0070.03720.38
5.5.350.0270.07020.30
5.5.340.0030.07317.94
5.5.330.0070.04020.31
5.5.320.0630.06320.56
5.5.310.0300.07320.35
5.5.300.0130.07718.07
5.5.290.0070.08318.07
5.5.280.0130.06320.77
5.5.270.0130.03320.68
5.5.260.0030.04020.87
5.5.250.0070.09020.58
5.5.240.0200.06020.16

preferences:
64.06 ms | 401 KiB | 5 Q