3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = "foo*arbaz*luj*abaz*lewis*bazbazlewbaz"; if (strpos($string, "foo") === 0 ) { echo substr_count($string, "*"); }

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.5.30.0130.00419.58
8.5.20.0090.00819.48
8.5.10.0100.00916.64
8.5.00.0140.00719.90
8.4.180.0100.01122.00
8.4.170.0100.01223.89
8.4.160.0120.00923.85
8.4.150.0070.00616.79
8.4.140.0130.00817.33
8.4.130.0150.00617.55
8.4.120.0090.01020.53
8.4.110.0110.00820.41
8.4.100.0120.00917.90
8.4.90.0130.00718.63
8.4.80.0110.00918.58
8.4.70.0090.00817.93
8.4.60.0060.00618.64
8.4.50.0040.00418.66
8.4.40.0080.01119.23
8.4.30.0070.00418.62
8.4.20.0040.01518.84
8.4.10.0130.00718.51
8.3.300.0120.00819.24
8.3.290.0120.00820.74
8.3.280.0130.00618.11
8.3.270.0130.00716.66
8.3.260.0120.00716.25
8.3.250.0100.00818.87
8.3.240.0020.00618.55
8.3.230.0080.00016.48
8.3.220.0100.00818.75
8.3.210.0090.01016.54
8.3.200.0070.00216.48
8.3.190.0110.00718.98
8.3.180.0120.00617.20
8.3.170.0140.00418.57
8.3.160.0120.00618.41
8.3.150.0060.01317.00
8.3.140.0040.00416.53
8.3.130.0080.00016.46
8.3.120.0040.00418.75
8.3.110.0120.00620.94
8.3.100.0060.00324.06
8.3.90.0120.00626.77
8.3.80.0030.00616.38
8.3.70.0110.00316.63
8.3.60.0000.01518.27
8.3.50.0070.00718.04
8.3.40.0130.00320.34
8.3.30.0060.00818.33
8.3.20.0040.00424.18
8.3.10.0040.00424.66
8.3.00.0000.00726.16
8.2.300.0090.01118.00
8.2.290.0080.01020.70
8.2.280.0100.00918.14
8.2.270.0140.00417.21
8.2.260.0120.00618.14
8.2.250.0080.00618.38
8.2.240.0000.00816.98
8.2.230.0030.00622.58
8.2.220.0110.00837.54
8.2.210.0140.00426.77
8.2.200.0090.00016.50
8.2.190.0140.00316.58
8.2.180.0120.00625.92
8.2.170.0030.01219.02
8.2.160.0200.00322.96
8.2.150.0080.00025.66
8.2.140.0000.00824.66
8.2.130.0040.00426.16
8.2.120.0030.00626.16
8.2.110.0110.00021.06
8.2.100.0040.00717.91
8.2.90.0050.00317.75
8.2.80.0000.00818.80
8.2.70.0080.00017.50
8.2.60.0040.00417.38
8.2.50.0090.00019.35
8.2.40.0030.00619.66
8.2.30.0000.00717.89
8.2.20.0030.00518.10
8.2.10.0050.00319.24
8.2.00.0000.00719.21
8.1.340.0150.00819.68
8.1.330.0110.01121.75
8.1.320.0090.01017.95
8.1.310.0100.00718.34
8.1.300.0120.00316.19
8.1.290.0060.00318.88
8.1.280.0060.00825.92
8.1.270.0080.00023.99
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0090.00022.19
8.1.230.0060.00621.03
8.1.220.0060.00318.64
8.1.210.0040.00418.77
8.1.200.0040.00417.22
8.1.190.0040.00417.10
8.1.180.0000.00918.10
8.1.170.0080.00017.62
8.1.160.0000.00718.81
8.1.150.0000.00718.81
8.1.140.0050.00220.48
8.1.130.0070.00020.02
8.1.120.0040.00417.31
8.1.110.0040.00417.26
8.1.100.0040.00417.27
8.1.90.0030.00317.39
8.1.80.0040.00417.26
8.1.70.0000.00717.33
8.1.60.0060.00317.51
8.1.50.0030.00517.48
8.1.40.0070.00017.45
8.1.30.0050.00317.50
8.1.20.0040.00417.54
8.1.10.0040.00417.37
8.1.00.0040.00417.41
8.0.300.0030.00618.77
8.0.290.0040.00416.63
8.0.280.0030.00318.40
8.0.270.0070.00018.00
8.0.260.0030.00320.39
8.0.250.0090.00016.96
8.0.240.0050.00316.98
8.0.230.0000.00716.77
8.0.220.0030.00316.85
8.0.210.0000.00816.77
8.0.200.0030.00316.90
8.0.190.0070.00016.89
8.0.180.0000.00716.84
8.0.170.0110.00016.84
8.0.160.0030.00616.86
8.0.150.0040.00416.81
8.0.140.0040.00416.74
8.0.130.0050.00013.14
8.0.120.0040.00416.75
8.0.110.0040.00416.81
8.0.100.0050.00216.77
8.0.90.0000.00816.70
8.0.80.0060.00916.83
8.0.70.0070.01016.88
8.0.60.0130.00316.71
8.0.50.0140.00316.72
8.0.30.0100.01016.87
8.0.20.0140.00316.78
8.0.10.0130.00916.87
8.0.00.0080.00716.90
7.4.330.0000.00515.55
7.4.320.0000.00616.49
7.4.300.0060.00016.57
7.4.290.0000.00716.45
7.4.280.0060.00316.53
7.4.270.0000.00716.49
7.4.260.0050.00013.38
7.4.250.0000.00716.59
7.4.240.0060.00216.51
7.4.230.0070.00016.47
7.4.220.0070.00016.69
7.4.210.0000.01416.61
7.4.200.0070.01316.54
7.4.190.0070.01316.55
7.4.180.0110.00316.56
7.4.160.0070.00716.54
7.4.150.0100.01016.56
7.4.140.0110.00916.41
7.4.130.0060.01316.53
7.4.120.0060.01316.48
7.4.110.0060.01316.53
7.4.100.0090.00516.57
7.4.90.0030.01616.48
7.4.80.0130.00616.55
7.4.70.0060.01416.55
7.4.60.0110.00316.44
7.4.50.0120.00316.39
7.4.40.0060.01416.28
7.4.30.0060.00916.39
7.4.20.0140.00016.48
7.4.10.0070.00716.52
7.4.00.0040.01016.53
7.3.330.0000.00716.10
7.3.320.0000.00612.99
7.3.310.0000.00716.18
7.3.300.0030.00316.21
7.3.290.0080.00616.17
7.3.280.0030.01016.22
7.3.270.0110.00316.18
7.3.260.0060.00616.13
7.3.250.0100.00316.14
7.3.240.0110.00316.14
7.3.230.0030.01016.22
7.3.220.0110.00816.16
7.3.210.0100.00916.08
7.3.200.0160.00316.04
7.3.190.0060.01316.13
7.3.180.0120.00316.13
7.3.170.0060.00616.07
7.3.160.0030.01016.07
7.3.150.0100.00316.16
7.3.140.0070.00716.14
7.3.130.0070.00716.10
7.3.120.0070.00716.18
7.3.110.0100.00316.17
7.3.100.0030.00916.11
7.3.90.0070.00716.28
7.3.80.0070.00616.13
7.3.70.0070.00616.16
7.3.60.0100.00316.24
7.3.50.0030.01016.27
7.3.40.0070.00716.30
7.3.30.0070.00716.34
7.3.20.0070.00716.33
7.3.10.0100.00316.23
7.3.00.0070.00716.39

preferences:
91.13 ms | 1373 KiB | 5 Q