3v4l.org

run code in 300+ PHP versions simultaneously
<?php $reverse = FALSE; $separator = '/'; $str = 'test/ezifh'; $f = $reverse ? 'strrpos' : 'strpos'; if (($pos = $f($str, $separator)) !== FALSE) { $str = substr($str,0, $pos); } var_dump($str);

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.0120.00318.27
8.3.50.0030.01018.05
8.3.40.0070.00718.54
8.3.30.0120.00319.06
8.3.20.0070.00020.16
8.3.10.0040.00422.08
8.3.00.0000.00822.45
8.2.180.0120.00616.75
8.2.170.0120.00322.96
8.2.160.0110.00420.80
8.2.150.0050.00324.18
8.2.140.0050.00224.66
8.2.130.0040.01326.16
8.2.120.0040.00419.11
8.2.110.0040.00422.30
8.2.100.0100.00319.45
8.2.90.0050.00219.01
8.2.80.0040.00417.97
8.2.70.0040.00417.50
8.2.60.0050.00317.80
8.2.50.0040.00418.07
8.2.40.0030.00618.03
8.2.30.0040.00417.92
8.2.20.0000.00717.64
8.2.10.0040.00417.74
8.2.00.0030.00617.65
8.1.270.0080.00022.14
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0090.00024.02
8.1.230.0140.00019.02
8.1.220.0040.00417.74
8.1.210.0050.00318.77
8.1.200.0030.00617.23
8.1.190.0040.00417.50
8.1.180.0090.00018.65
8.1.170.0040.00418.57
8.1.160.0000.00721.86
8.1.150.0000.00718.49
8.1.140.0070.00017.29
8.1.130.0030.00317.82
8.1.120.0070.00017.45
8.1.110.0000.00817.34
8.1.100.0040.00417.40
8.1.90.0000.00717.29
8.1.80.0070.00017.38
8.1.70.0000.00717.32
8.1.60.0060.00317.41
8.1.50.0060.00317.33
8.1.40.0030.00517.34
8.1.30.0060.00317.60
8.1.20.0080.00017.48
8.1.10.0000.00817.36
8.1.00.0070.00017.44
8.0.300.0050.00318.77
8.0.290.0080.00017.05
8.0.280.0030.00318.34
8.0.270.0030.00317.06
8.0.260.0030.00316.62
8.0.250.0070.00016.73
8.0.240.0070.00016.79
8.0.230.0070.00016.84
8.0.220.0030.00316.78
8.0.210.0000.00716.80
8.0.200.0050.00216.93
8.0.190.0000.00716.79
8.0.180.0040.00416.84
8.0.170.0000.00816.83
8.0.160.0050.00316.78
8.0.150.0000.00716.73
8.0.140.0070.00016.79
8.0.130.0000.00513.25
8.0.120.0040.00416.76
8.0.110.0000.00816.78
8.0.100.0000.00716.69
8.0.90.0070.00016.67
8.0.80.0120.00616.77
8.0.70.0080.00016.86
8.0.60.0000.00816.71
8.0.50.0070.00016.60
8.0.30.0120.00617.05
8.0.20.0100.01017.40
8.0.10.0040.00416.95
8.0.00.0100.00716.66
7.4.330.0060.00015.09
7.4.320.0030.00316.60
7.4.300.0000.00616.48
7.4.290.0000.00716.46
7.4.280.0030.00316.39
7.4.270.0070.00016.59
7.4.260.0000.00716.57
7.4.250.0000.00816.32
7.4.240.0020.00516.57
7.4.230.0030.00316.34
7.4.220.0100.00716.58
7.4.210.0060.01116.58
7.4.200.0040.00416.35
7.4.190.0030.00316.54
7.4.160.0130.01016.55
7.4.150.0070.01117.40
7.4.140.0110.00617.86
7.4.130.0110.01016.49
7.4.120.0120.01016.58
7.4.110.0130.01016.47
7.4.100.0090.00916.41
7.4.90.0070.01016.44
7.4.80.0090.00919.39
7.4.70.0120.00916.52
7.4.60.0150.00716.56
7.4.50.0030.00616.45
7.4.40.0070.01022.77
7.4.30.0060.01116.47
7.4.00.0110.00714.60
7.3.330.0000.00612.94
7.3.320.0000.00612.93
7.3.310.0070.00016.02
7.3.300.0030.00316.17
7.3.290.0080.00816.24
7.3.280.0090.00816.18
7.3.270.0070.01017.40
7.3.260.0100.00716.25
7.3.250.0110.00716.37
7.3.240.0090.00916.19
7.3.230.0100.00716.39
7.3.210.0090.00816.45
7.3.200.0060.00919.39
7.3.190.0130.00916.30
7.3.180.0110.00616.27
7.3.170.0090.00916.33
7.3.160.0040.01316.29
7.3.120.0100.00714.69
7.2.330.0050.01316.46
7.2.320.0060.01216.52
7.2.310.0030.01416.64
7.2.300.0110.01116.60
7.2.290.0030.01316.61
7.2.80.0070.00716.63
7.2.00.0040.00919.38
7.1.200.0090.00315.73
7.1.100.0110.01118.07
7.1.70.0050.00217.03
7.1.60.0100.01319.82
7.1.50.0000.02216.90
7.1.00.0000.08022.31
7.0.200.0140.00316.63
7.0.140.0130.06321.97
7.0.60.0170.06319.91
7.0.50.0030.04317.79
7.0.40.0030.04319.96
7.0.30.0330.04320.17
7.0.20.0470.05720.09
7.0.10.0070.05720.21
7.0.00.0070.06320.19
5.6.280.0070.07020.86
5.6.210.0070.08720.61
5.6.200.0000.08718.18
5.6.190.0070.09020.43
5.6.180.0470.07020.77
5.6.170.0300.04320.48
5.6.160.0030.04320.59
5.6.150.0070.07718.11
5.6.140.0000.04318.18
5.6.130.0000.07318.06
5.6.120.0070.06021.12
5.6.110.0030.04020.96
5.6.100.0070.08721.10
5.6.90.0030.07021.10
5.6.80.0130.07320.38
5.5.350.0230.07720.33
5.5.340.0030.07717.98
5.5.330.0170.05020.06
5.5.320.0330.06020.29
5.5.310.0370.07720.33
5.5.300.0130.03018.00
5.5.290.0100.08318.07
5.5.280.0100.03720.84
5.5.270.0100.06020.82
5.5.260.0030.04320.79
5.5.250.0100.08020.55
5.5.240.0330.06720.26
5.4.450.1230.04019.57
5.4.440.0030.04019.45
5.4.430.0030.04019.56
5.4.420.1570.03719.40
5.4.410.1930.03719.28
5.4.400.1900.03719.14
5.4.390.1930.03719.25
5.4.380.1930.03319.24
5.4.370.2030.04319.24
5.4.360.1930.04318.78
5.4.350.1870.03719.24
5.4.340.1830.04018.77
5.4.320.1830.04018.77
5.4.310.1900.03719.09
5.4.300.1870.04019.12
5.4.290.1970.04318.91
5.4.280.2030.04018.79
5.4.270.2130.02719.10
5.4.260.1800.03718.93
5.4.250.1800.03718.91
5.4.240.1970.04319.24
5.4.230.1800.03718.88
5.4.220.1900.04319.08
5.4.210.1800.03718.91
5.4.200.1900.04018.91
5.4.190.1070.04019.04
5.4.180.0070.04319.04
5.4.170.0130.07318.92
5.4.160.1500.04719.10
5.4.150.2000.04019.11
5.4.140.1970.04716.44
5.4.130.1800.03316.18
5.4.120.1800.03016.36
5.4.110.2000.04016.41
5.4.100.1970.04316.49
5.4.90.1830.03716.39
5.4.80.1700.04016.39
5.4.70.2000.03316.39
5.4.60.1900.04016.19
5.4.50.0100.07016.38
5.4.40.0100.06716.18
5.4.30.1030.04316.38
5.4.20.2000.04316.01
5.4.10.1930.04316.03
5.4.00.1730.03715.75
5.3.290.2030.04314.61
5.3.280.1770.04014.45
5.3.270.1770.04014.56
5.3.260.2030.03714.59
5.3.250.1970.04314.49
5.3.240.2100.04014.46
5.3.230.1870.04014.53
5.3.220.1970.04014.43
5.3.210.2000.04014.52
5.3.200.2000.04014.47
5.3.190.1930.03714.51
5.3.180.1770.03714.42
5.3.170.1830.04314.66
5.3.160.1770.03714.61
5.3.150.2130.03314.46
5.3.140.2100.03714.39
5.3.130.1870.03714.49
5.3.120.1930.04714.50
5.3.110.0070.07314.64
5.3.100.0000.04713.96
5.3.90.0770.03713.86
5.3.80.1870.04014.03
5.3.70.1900.03013.98
5.3.60.2070.03713.83
5.3.50.1830.03713.99
5.3.40.2000.04013.82
5.3.30.1900.04013.72
5.3.20.1700.04313.60
5.3.10.1800.03313.49
5.3.00.1830.03313.59
5.2.170.1500.03311.05
5.2.160.1200.03010.96
5.2.150.0000.03010.98
5.2.140.0030.05711.00
5.2.130.0170.04311.26
5.2.120.1470.03010.93
5.2.110.1600.03310.99
5.2.100.1500.03311.17
5.2.90.1500.03010.95
5.2.80.1500.03011.03
5.2.70.1700.02710.93
5.2.60.1900.03310.90
5.2.50.1900.03311.18
5.2.40.1470.03010.82
5.2.30.1230.03010.80
5.2.20.1170.02710.86
5.2.10.1200.02310.80
5.2.00.1230.02310.73
5.1.60.0030.0539.89
5.1.50.0070.02010.07
5.1.40.0000.0609.85
5.1.30.0130.02710.38
5.1.20.1400.03010.46
5.1.10.1130.0309.93
5.1.00.1330.03010.16
5.0.50.0630.0238.66
5.0.40.0800.0238.49
5.0.30.0900.0438.20
5.0.20.0600.0208.07
5.0.10.0600.0338.09
5.0.00.0030.0338.08
4.4.90.0030.0177.91
4.4.80.0000.0177.91
4.4.70.0030.0337.91
4.4.60.0000.0277.91
4.4.50.0030.0137.91
4.4.40.0030.0307.91
4.4.30.0000.0207.91
4.4.20.0070.0177.91
4.4.10.0000.0207.91
4.4.00.0600.0237.91
4.3.110.0800.0177.91
4.3.100.0730.0137.91
4.3.90.0970.0237.91
4.3.80.0970.0337.91
4.3.70.1070.0177.91
4.3.60.0800.0237.91
4.3.50.0000.0207.91
4.3.40.0030.0507.91
4.3.30.0000.0307.91
4.3.20.0070.0107.91
4.3.10.0030.0337.91
4.3.00.0000.0407.91

preferences:
63.77 ms | 400 KiB | 5 Q