3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* The Euro sign--U+20AC--followed by " hi there", in UTF-8. */ $teststr = "\xe2\x82\xac hi there"; /* Split it into individual characters, passing the /u flag to tell PCRE to interpret the string as UTF-8. */ $testchars = preg_split('//u', $teststr, -1, PREG_SPLIT_NO_EMPTY); /* Get some output that should be equivalent. */ preg_match_all('/./u', $teststr, $matches); $goodtestchars = $matches[0]; /* The arrays should be the same length. */ print "This should be 1: '".(count($testchars) == count($goodtestchars))."'\n"; /* And the octet count of the first entry should be three for both arrays. */ print 'These both should be three: '; print strlen($testchars[0]).', '.strlen($goodtestchars[0]). "\n";

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.70.0070.00718.56
8.3.60.0100.00316.63
8.3.50.0110.00716.66
8.3.40.0070.01418.96
8.3.30.0090.00618.95
8.3.20.0040.00418.94
8.3.10.0030.00620.65
8.3.00.0150.00419.50
8.2.180.0030.01716.63
8.2.170.0070.01422.96
8.2.160.0070.00721.32
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0000.00826.16
8.2.120.0030.00619.73
8.2.110.0040.00817.88
8.2.100.0080.00318.03
8.2.90.0080.00017.88
8.2.80.0080.00019.09
8.2.70.0040.00417.93
8.2.60.0030.01017.94
8.2.50.0040.00418.10
8.2.40.0070.00019.31
8.2.30.0020.00519.25
8.2.20.0050.00217.92
8.2.10.0040.00417.88
8.2.00.0030.00717.85
8.1.280.0070.00725.92
8.1.270.0030.00524.66
8.1.260.0060.00326.35
8.1.250.0040.00428.09
8.1.240.0000.00923.91
8.1.230.0090.00320.96
8.1.220.0080.00017.77
8.1.210.0080.00018.77
8.1.200.0060.00617.47
8.1.190.0040.00417.48
8.1.180.0050.00318.91
8.1.170.0000.00818.78
8.1.160.0000.00719.04
8.1.150.0000.00718.82
8.1.140.0000.00917.50
8.1.130.0030.00317.72
8.1.120.0040.00417.61
8.1.110.0030.00517.61
8.1.100.0070.00017.48
8.1.90.0000.00717.64
8.1.80.0040.00417.57
8.1.70.0070.00017.61
8.1.60.0050.00317.77
8.1.50.0040.00417.56
8.1.40.0000.00817.66
8.1.30.0000.00817.80
8.1.20.0060.00317.87
8.1.10.0040.00417.79
8.1.00.0040.00417.63
8.0.300.0000.00818.77
8.0.290.0040.00417.00
8.0.280.0030.00318.39
8.0.270.0000.00717.28
8.0.260.0030.00316.90
8.0.250.0020.00517.18
8.0.240.0020.00517.20
8.0.230.0000.00717.07
8.0.220.0070.00017.07
8.0.210.0030.00316.98
8.0.200.0030.00617.09
8.0.190.0040.00417.18
8.0.180.0040.00417.03
8.0.170.0030.00617.14
8.0.160.0040.00417.03
8.0.150.0000.00917.07
8.0.140.0040.00417.11
8.0.130.0030.00513.59
8.0.120.0000.00717.07
8.0.110.0040.00417.05
8.0.100.0040.00416.96
8.0.90.0050.00216.96
8.0.80.0040.01117.10
8.0.70.0030.00517.13
8.0.60.0030.00517.07
8.0.50.0040.00417.05
8.0.30.0070.01317.19
8.0.20.0120.00617.48
8.0.10.0040.00417.15
8.0.00.0100.00817.00
7.4.330.0000.00513.21
7.4.320.0000.00616.68
7.4.300.0030.00316.73
7.4.290.0000.00716.71
7.4.280.0040.00416.73
7.4.270.0040.00416.72
7.4.260.0060.00013.50
7.4.250.0060.00316.85
7.4.240.0040.00416.73
7.4.230.0070.00016.88
7.4.220.0070.01116.91
7.4.210.0070.00816.86
7.4.200.0070.00016.98
7.4.190.0000.00716.89
7.4.160.0130.00816.75
7.4.150.0080.00816.61
7.4.140.0110.00716.60
7.4.130.0130.00816.79
7.4.120.0050.01216.88
7.4.110.0040.01916.75
7.4.100.0110.00816.77
7.4.90.0120.00616.90
7.4.80.0160.00719.39
7.4.70.0070.01116.82
7.4.60.0000.01716.67
7.4.50.0070.00016.57
7.4.40.0070.01116.66
7.4.30.0080.00816.91
7.4.00.0070.00715.18
7.3.330.0030.00313.44
7.3.320.0060.00013.45
7.3.310.0030.00316.38
7.3.300.0030.00316.44
7.3.290.0100.01016.51
7.3.280.0110.00416.45
7.3.270.0100.01416.41
7.3.260.0140.00616.76
7.3.250.0200.01516.63
7.3.240.0170.00016.46
7.3.230.0030.01516.70
7.3.210.0090.00916.52
7.3.200.0100.00716.50
7.3.190.0060.01216.76
7.3.180.0030.01316.43
7.3.170.0060.01016.65
7.3.160.0030.01216.60
7.3.120.0040.01115.18
7.3.110.0110.00715.21
7.3.100.0030.00715.07
7.3.90.0140.00015.06
7.3.80.0120.00015.20
7.3.70.0110.00015.08
7.3.60.0100.00315.19
7.3.50.0070.01015.01
7.3.40.0100.00615.11
7.3.30.0000.00915.07
7.3.20.0060.00816.89
7.3.10.0110.00316.98
7.3.00.0000.00816.96
7.2.330.0110.00716.63
7.2.320.0060.01116.81
7.2.310.0130.00716.83
7.2.300.0170.00816.97
7.2.290.0080.00916.96
7.2.250.0060.01214.93
7.2.240.0030.01615.40
7.2.230.0080.00615.18
7.2.220.0080.00415.43
7.2.210.0060.00614.96
7.2.200.0040.01115.20
7.2.190.0070.01015.27
7.2.180.0100.00715.44
7.2.170.0100.00315.39
7.2.00.0000.01419.65
7.1.330.0070.00715.88
7.1.320.0060.00616.05
7.1.310.0040.01116.13
7.1.300.0100.00715.73
7.1.290.0040.01215.96
7.1.280.0040.00415.91
7.1.270.0070.01015.76
7.1.260.0080.00816.02
7.1.100.0100.00717.96
7.1.70.0000.01417.30
7.1.60.0120.00619.40
7.1.50.0040.01817.31
7.1.00.0030.07322.38
7.0.200.0000.00716.82
7.0.140.0000.07721.97
7.0.120.0070.07022.04
7.0.60.0000.07319.99
7.0.50.0000.04317.83
7.0.40.0030.06720.42
7.0.30.0370.05020.35
7.0.20.0330.06720.19
7.0.10.0070.04320.01
7.0.00.0030.04020.36
5.6.280.0170.06020.89
5.6.210.0070.08020.61
5.6.200.0030.07318.17
5.6.190.0070.08320.41
5.6.180.0330.06320.32
5.6.170.0230.06720.33
5.6.160.0100.03720.51
5.6.150.0030.08018.21
5.6.140.0100.08018.11
5.6.130.0070.05318.11
5.6.120.0070.04021.12
5.6.110.0000.04321.04
5.6.100.0130.05720.95
5.6.90.0130.07321.09
5.6.80.0000.07020.40
5.6.70.4500.03320.52
5.5.350.0200.04020.39
5.5.340.0130.05718.03
5.5.330.0070.04320.20
5.5.320.0270.03020.29
5.5.310.0400.07020.27
5.5.300.0030.04017.89
5.5.290.0100.07317.97
5.5.280.0100.05020.71
5.5.270.0100.06720.87
5.5.260.0030.08720.64
5.5.250.0170.06320.66
5.5.240.0300.07320.16
5.4.450.0100.04719.11
5.4.440.0030.05719.52
5.4.430.0070.06319.11
5.4.420.0030.05719.40
5.4.410.0030.04319.39
5.4.400.0100.04719.16
5.4.390.0100.07318.80
5.4.380.0030.04018.79
5.4.370.0170.07019.10
5.4.360.0130.06318.92
5.4.350.0130.07319.09
5.4.340.0100.06719.18
5.4.320.0170.04718.79
5.4.310.0100.04319.16
5.4.300.0070.03718.79
5.4.290.0030.06318.95
5.4.280.0030.08019.18
5.4.270.0130.07319.17
5.4.260.0100.04718.95
5.4.250.0100.04018.99
5.4.240.0030.04318.91
5.4.230.0070.07318.91
5.4.220.0100.04319.07
5.4.210.0100.06319.17
5.4.200.0070.07318.91
5.4.190.0030.06319.10
5.4.180.0070.06719.10
5.4.170.0070.07718.90
5.4.160.0170.03719.13
5.4.150.0070.07719.07
5.4.140.0100.05016.34
5.4.130.0030.04016.29
5.4.120.0000.06316.41
5.4.110.0130.06016.45
5.4.100.0070.07016.46
5.4.90.0030.05316.42
5.4.80.0130.03716.25
5.4.70.0030.06316.30
5.4.60.0030.06016.38
5.4.50.0030.06716.20
5.4.40.0030.06716.38
5.4.30.0130.06316.24
5.4.20.0030.04716.29
5.4.10.0100.06716.21
5.4.00.0030.07715.93
5.3.290.0100.07314.62
5.3.280.0070.08014.43
5.3.270.0070.06714.53
5.3.260.0130.07314.54
5.3.250.0130.04014.54
5.3.240.0070.05714.53
5.3.230.0130.06314.61
5.3.220.0070.05314.53
5.3.210.0030.06014.50
5.3.200.0130.06714.46
5.3.190.0030.07314.50
5.3.180.0100.07314.49
5.3.170.0030.08014.48
5.3.160.0100.07014.49
5.3.150.0100.07014.44
5.3.140.0070.05314.53
5.3.130.0130.06014.47
5.3.120.0030.07314.44
5.3.110.0030.06014.47
5.3.100.0070.08014.13
5.3.90.0070.07014.11
5.3.80.0100.07013.95
5.3.70.0130.05013.98
5.3.60.0030.05013.93
5.3.50.0030.04713.88
5.3.40.0100.06013.88
5.3.30.0070.06013.75
5.3.20.0070.03313.66
5.3.10.0030.07313.59
5.3.00.0070.03713.57
5.2.170.0030.06011.14
5.2.160.0070.06011.08
5.2.150.0030.05311.30
5.2.140.0030.05711.03
5.2.130.0030.05011.04
5.2.120.0030.03311.26
5.2.110.0070.04711.11
5.2.100.0000.05711.04
5.2.90.0000.04711.18
5.2.80.0000.03310.99
5.2.70.0100.03311.03
5.2.60.0070.06011.04
5.2.50.0100.04311.10
5.2.40.0030.05311.00
5.2.30.0070.04310.96
5.2.20.0000.03311.13
5.2.10.0030.03710.91
5.2.00.0000.04710.76
5.1.60.0070.0279.89
5.1.50.0030.03310.05
5.1.40.0000.03710.02
5.1.30.0000.04310.47
5.1.20.0000.03010.40
5.1.10.0030.04010.08
5.1.00.0000.05710.06
5.0.50.0000.0378.61
5.0.40.0000.0338.43
5.0.30.0070.0538.19
5.0.20.0030.0338.20
5.0.10.0000.0308.13
5.0.00.0000.0408.21
4.4.90.0100.0308.11
4.4.80.0070.0138.11
4.4.70.0000.0238.11
4.4.60.0000.0238.11
4.4.50.0070.0308.11
4.4.40.0030.0508.11
4.4.30.0000.0378.11
4.4.20.0030.0138.11
4.4.10.0030.0378.11
4.4.00.0000.0378.11
4.3.110.0030.0378.11
4.3.100.0030.0338.11
4.3.90.0000.0238.11
4.3.80.0000.0508.11
4.3.70.0070.0338.11
4.3.60.0030.0278.11
4.3.50.0030.0338.11
4.3.40.0000.0438.11
4.3.30.0000.0178.11
4.3.20.0000.0208.11
4.3.10.0000.0178.11
4.3.00.0000.0378.11

preferences:
46.17 ms | 401 KiB | 5 Q