3v4l.org

run code in 300+ PHP versions simultaneously
<?php $utf8string = 'こんにちは、漢字ユーティーエッフ8hello123等々'; $var = 'hello123'; $pos = strpos($utf8string, $var); if ($pos!==false) { echo substr($utf8string, 0, $pos); }

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.0100.00316.50
8.3.50.0250.00516.47
8.3.40.0120.00318.42
8.3.30.0120.00618.57
8.3.20.0080.00018.74
8.3.10.0030.00620.53
8.3.00.0100.00017.38
8.2.180.0190.00316.63
8.2.170.0040.01122.96
8.2.160.0030.01320.52
8.2.150.0080.00024.18
8.2.140.0100.00324.66
8.2.130.0070.00026.16
8.2.120.0040.00419.23
8.2.110.0060.00319.21
8.2.100.0040.00717.91
8.2.90.0060.00321.10
8.2.80.0050.00319.28
8.2.70.0000.00917.50
8.2.60.0060.00317.93
8.2.50.0050.00319.23
8.2.40.0000.00818.11
8.2.30.0070.00017.93
8.2.20.0030.00517.56
8.2.10.0000.00717.61
8.2.00.0030.00617.71
8.1.280.0120.00325.92
8.1.270.0080.00024.66
8.1.260.0080.00026.35
8.1.250.0030.00528.09
8.1.240.0090.00022.48
8.1.230.0110.00020.88
8.1.220.0030.00617.74
8.1.210.0040.00418.91
8.1.200.0050.00517.23
8.1.190.0050.00217.53
8.1.180.0030.00618.10
8.1.170.0000.00718.89
8.1.160.0000.00818.87
8.1.150.0000.00918.57
8.1.140.0060.00317.36
8.1.130.0030.00317.80
8.1.120.0000.00817.40
8.1.110.0030.00417.42
8.1.100.0040.00417.39
8.1.90.0050.00217.22
8.1.80.0000.00817.44
8.1.70.0030.00317.39
8.1.60.0000.00717.50
8.1.50.0030.00517.44
8.1.40.0040.00417.47
8.1.30.0000.00717.57
8.1.20.0040.00417.53
8.1.10.0040.00417.43
8.1.00.0080.00017.48
8.0.300.0000.00819.82
8.0.290.0000.00716.63
8.0.280.0030.00318.43
8.0.270.0040.00417.25
8.0.260.0060.00016.77
8.0.250.0040.00416.81
8.0.240.0000.00716.95
8.0.230.0000.00716.91
8.0.220.0070.00016.82
8.0.210.0030.00316.80
8.0.200.0000.00616.77
8.0.190.0030.00516.85
8.0.180.0030.00616.74
8.0.170.0000.00916.83
8.0.160.0000.00716.71
8.0.150.0000.00916.80
8.0.140.0000.01116.82
8.0.130.0050.00213.25
8.0.120.0050.00316.66
8.0.110.0050.00216.71
8.0.100.0070.00016.66
8.0.90.0040.00416.68
8.0.80.0040.01116.77
8.0.70.0000.00816.65
8.0.60.0000.00716.84
8.0.50.0030.00616.80
8.0.30.0150.00317.22
8.0.20.0090.01117.10
8.0.10.0060.00316.81
8.0.00.0110.01216.65
7.4.330.0000.00513.01
7.4.320.0110.00016.54
7.4.300.0000.00616.54
7.4.290.0050.00216.39
7.4.280.0040.00416.50
7.4.270.0030.00316.55
7.4.260.0000.00513.32
7.4.250.0000.00816.48
7.4.240.0000.00716.50
7.4.230.0000.00716.24
7.4.220.0120.00916.65
7.4.210.0070.00916.45
7.4.200.0030.00316.64
7.4.190.0000.00716.45
7.4.160.0070.01016.57
7.4.150.0130.00416.52
7.4.140.0200.00816.56
7.4.130.0050.01216.38
7.4.120.0040.01216.46
7.4.110.0110.00616.34
7.4.100.0060.01216.41
7.4.90.0090.00916.57
7.4.80.0060.01019.39
7.4.70.0060.01016.45
7.4.60.0050.01316.59
7.4.50.0060.00316.40
7.4.40.0030.01316.35
7.4.30.0140.00816.36
7.4.00.0030.01315.05
7.3.330.0060.00012.88
7.3.320.0030.00312.93
7.3.310.0000.00716.04
7.3.300.0000.00616.21
7.3.290.0070.00716.18
7.3.280.0090.00816.18
7.3.270.0100.00716.24
7.3.260.0160.00516.36
7.3.250.0150.00516.33
7.3.240.0080.00916.56
7.3.230.0090.00616.41
7.3.210.0060.00916.49
7.3.200.0130.00316.52
7.3.190.0070.01616.21
7.3.180.0060.00916.17
7.3.170.0140.00716.38
7.3.160.0080.00816.19
7.3.120.0080.00414.78
7.3.10.0120.00016.36
7.3.00.0060.01016.49
7.2.330.0080.00816.43
7.2.320.0170.00016.44
7.2.310.0070.01516.66
7.2.300.0090.01216.59
7.2.290.0110.00516.37
7.2.130.0030.01016.91
7.2.120.0060.00616.63
7.2.110.0070.00416.95
7.2.100.0090.00316.93
7.2.90.0000.01116.68
7.2.80.0030.00716.89
7.2.70.0000.00816.98
7.2.60.0030.00916.62
7.2.50.0050.00516.98
7.2.40.0060.00916.98
7.2.30.0070.00716.88
7.2.20.0000.01216.83
7.2.10.0090.00616.71
7.2.00.0040.00816.96
7.1.250.0000.00715.94
7.1.200.0040.01115.57
7.1.70.0030.00516.97
7.1.60.0070.01719.40
7.1.50.0060.01316.90
7.1.00.0030.07322.45
7.0.200.0060.00316.67
7.0.140.0030.07321.99
7.0.120.0030.05022.03
7.0.60.0030.07721.82
7.0.50.0100.04317.91
7.0.40.0030.04320.03
7.0.30.0400.06720.09
7.0.20.0270.07320.20
7.0.10.0030.04320.16
7.0.00.0100.04320.09
5.6.280.0100.06721.06
5.6.210.0100.06320.69
5.6.200.0170.06018.18
5.6.190.0070.06720.32
5.6.180.0370.05020.61
5.6.170.0330.07020.52
5.6.160.0030.05320.71
5.6.150.0100.06018.22
5.6.140.0000.09018.11
5.6.130.0030.08318.12
5.6.120.0030.04320.98
5.6.110.0070.06021.11
5.6.100.0070.07721.04
5.6.90.0100.07721.01
5.6.80.0100.06020.35
5.5.350.0030.05720.41
5.5.340.0170.07017.92
5.5.330.0070.04020.20
5.5.320.0230.07720.29
5.5.310.0270.05320.29
5.5.300.0100.08017.98
5.5.290.0070.07718.02
5.5.280.0030.04020.81
5.5.270.0070.08720.72
5.5.260.0030.08320.64
5.5.250.0100.05720.68
5.5.240.0270.06720.25
5.4.450.0100.07019.51
5.4.440.0070.07319.40
5.4.430.0030.08319.40
5.4.420.0070.06719.23
5.4.410.0070.08319.16
5.4.400.0030.05018.79
5.4.390.0230.05019.08
5.4.380.0100.04319.18
5.4.370.0070.07319.04
5.4.360.0070.07019.16
5.4.350.0030.07719.17
5.4.340.0130.06718.79
5.4.320.0100.05018.79
5.4.310.0030.04019.08
5.4.300.0100.04019.17
5.4.290.0070.04718.79
5.4.280.0030.08019.18
5.4.270.0030.04719.14
5.4.260.0000.05018.80
5.4.250.0030.04019.17
5.4.240.0170.04319.17
5.4.230.0070.04319.14
5.4.220.0070.03719.16
5.4.210.0030.07318.78
5.4.200.0000.04719.16
5.4.190.0000.04018.99
5.4.180.0100.07019.07
5.4.170.0000.05018.77
5.4.160.0030.03719.15
5.4.150.0000.04018.75
5.4.140.0070.04016.20
5.4.130.0000.04316.25
5.4.120.0000.03716.19
5.4.110.0000.03716.26
5.4.100.0030.03716.24
5.4.90.0030.03316.32
5.4.80.0000.03716.39
5.4.70.0030.03716.27
5.4.60.0030.03316.31
5.4.50.0030.03316.27
5.4.40.0030.03716.36
5.4.30.0030.03316.35
5.4.20.0000.03716.12
5.4.10.0030.04016.21
5.4.00.0070.03015.71
5.3.290.0030.05014.45
5.3.280.0000.05014.49
5.3.270.0070.06714.62
5.3.260.0070.04014.52
5.3.250.0030.03714.55
5.3.240.0030.03714.41
5.3.230.0030.03714.57
5.3.220.0070.03314.54
5.3.210.0070.03714.65
5.3.200.0030.04014.49
5.3.190.0030.03714.52
5.3.180.0030.03314.65
5.3.170.0030.03714.34
5.3.160.0100.03014.57
5.3.150.0030.03714.44
5.3.140.0000.03714.34
5.3.130.0000.04014.47
5.3.120.0030.03714.33
5.3.110.0070.03314.47
5.3.100.0000.04314.05
5.3.90.0030.03313.95
5.3.80.0030.04014.10
5.3.70.0000.03713.94
5.3.60.0030.03714.09
5.3.50.0030.03713.88
5.3.40.0100.03313.92
5.3.30.0000.04013.72
5.3.20.0000.03713.51
5.3.10.0000.03713.59
5.3.00.0030.03313.58
5.2.170.0030.02711.07
5.2.160.0070.02311.08
5.2.150.0000.03011.13
5.2.140.0000.03711.30
5.2.130.0030.03011.18
5.2.120.0070.02311.07
5.2.110.0000.03011.04
5.2.100.0070.02311.03
5.2.90.0000.03310.99
5.2.80.0000.03310.97
5.2.70.0000.04010.98
5.2.60.0000.03011.03
5.2.50.0030.03011.09
5.2.40.0030.02710.92
5.2.30.0000.03310.91
5.2.20.0070.02710.84
5.2.10.0070.05710.71
5.2.00.0000.06310.70
5.1.60.0030.03310.00
5.1.50.0030.05310.00
5.1.40.0070.0339.98
5.1.30.0030.03710.21
5.1.20.0070.05310.37
5.1.10.0100.05010.21
5.1.00.0070.05010.11
5.0.50.0030.0438.45
5.0.40.0000.0208.57
5.0.30.0030.0638.29
5.0.20.0030.0408.25
5.0.10.0000.0238.31
5.0.00.0030.0638.13
4.4.90.0000.0177.95
4.4.80.0000.0177.95
4.4.70.0030.0237.95
4.4.60.0000.0207.95
4.4.50.0000.0177.95
4.4.40.0030.0477.95
4.4.30.0000.0407.95
4.4.20.0030.0377.95
4.4.10.0030.0337.95
4.4.00.0000.0607.95
4.3.110.0000.0377.95
4.3.100.0030.0337.95
4.3.90.0000.0377.95
4.3.80.0030.0507.95
4.3.70.0030.0237.95
4.3.60.0000.0337.95
4.3.50.0000.0237.95
4.3.40.0000.0277.95
4.3.30.0030.0337.95
4.3.20.0000.0377.95
4.3.10.0030.0337.95
4.3.00.0000.0237.95

preferences:
46.72 ms | 401 KiB | 5 Q