3v4l.org

run code in 300+ PHP versions simultaneously
<?php $encoding = 'UTF-8'; $orig = PHP_VERSION_ID < 50600 ? iconv_get_encoding('internal_encoding') : ini_get('default_charset'); if (PHP_VERSION_ID < 50600) { if ($encoding) { $result = iconv_set_encoding('internal_encoding', $encoding); } else { $result = false; } } else { ini_set('default_charset', $encoding); $result = ini_get('default_charset'); } if (!$result) { echo 'Given encoding not supported on this OS!'; } else { echo 'All good'; }

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.0000.01516.75
8.3.50.0110.01116.46
8.3.40.0070.01518.73
8.3.30.0040.01118.70
8.3.20.0040.00420.34
8.3.10.0030.00623.65
8.3.00.0040.00420.22
8.2.180.0110.00718.38
8.2.170.0100.00722.96
8.2.160.0120.00820.53
8.2.150.0110.00324.18
8.2.140.0080.00024.66
8.2.130.0080.00019.27
8.2.120.0070.00026.35
8.2.110.0000.01122.25
8.2.100.0060.00618.03
8.2.90.0050.00318.03
8.2.80.0030.00617.97
8.2.70.0070.00317.75
8.2.60.0000.00817.93
8.2.50.0030.00518.10
8.2.40.0040.00420.32
8.2.30.0040.00421.14
8.2.20.0000.00817.94
8.2.10.0000.00818.04
8.2.00.0040.00418.08
8.1.280.0070.00725.92
8.1.270.0130.00622.07
8.1.260.0070.00726.35
8.1.250.0000.00828.09
8.1.240.0030.00622.02
8.1.230.0080.00320.95
8.1.220.0050.00317.78
8.1.210.0040.00418.91
8.1.200.0060.00317.35
8.1.190.0060.00317.23
8.1.180.0040.00418.10
8.1.170.0030.00518.41
8.1.160.0030.00318.94
8.1.150.0050.00320.68
8.1.140.0000.00719.63
8.1.130.0000.00718.93
8.1.120.0030.00517.50
8.1.110.0000.00717.42
8.1.100.0030.00617.48
8.1.90.0080.00017.49
8.1.80.0000.00817.49
8.1.70.0070.00017.48
8.1.60.0040.00417.59
8.1.50.0050.00517.52
8.1.40.0040.00417.54
8.1.30.0040.00417.55
8.1.20.0000.00717.57
8.1.10.0000.00817.57
8.1.00.0040.00417.34
8.0.300.0040.00420.04
8.0.290.0050.00216.88
8.0.280.0000.00718.33
8.0.270.0030.00617.26
8.0.260.0000.00616.80
8.0.250.0000.00716.99
8.0.240.0070.00216.94
8.0.230.0030.00316.90
8.0.220.0000.00716.84
8.0.210.0000.00716.87
8.0.200.0000.00616.98
8.0.190.0040.00417.07
8.0.180.0000.00717.01
8.0.170.0070.00317.04
8.0.160.0000.00816.95
8.0.150.0000.00716.88
8.0.140.0050.00316.79
8.0.130.0000.00513.43
8.0.120.0030.00616.87
8.0.110.0000.00717.00
8.0.100.0040.00416.96
8.0.90.0000.00716.96
8.0.80.0080.00816.91
8.0.70.0030.00517.01
8.0.60.0000.00717.00
8.0.50.0000.00816.93
8.0.30.0080.01117.13
8.0.20.0110.00717.40
8.0.10.0040.00417.12
8.0.00.0090.00916.57
7.4.330.0000.00515.55
7.4.320.0060.00016.54
7.4.300.0000.00716.59
7.4.290.0030.00316.46
7.4.280.0040.00416.55
7.4.270.0000.00716.63
7.4.260.0030.00616.59
7.4.250.0080.00016.46
7.4.240.0040.00416.50
7.4.230.0030.00316.58
7.4.220.0110.00716.54
7.4.210.0060.00916.52
7.4.200.0070.00016.50
7.4.160.0090.00716.46
7.4.150.0100.00717.40
7.4.140.0070.01217.86
7.4.130.0090.00916.30
7.4.120.0090.01016.44
7.4.110.0160.00016.48
7.4.100.0040.01216.50
7.4.90.0060.01016.42
7.4.80.0030.01419.39
7.4.70.0120.00316.57
7.4.60.0070.01116.59
7.4.50.0000.01016.38
7.4.40.0120.00616.45
7.4.30.0060.01016.41
7.4.00.0060.00315.08
7.3.330.0050.00013.00
7.3.320.0000.00513.03
7.3.310.0030.00316.24
7.3.300.0030.00316.25
7.3.290.0060.01116.31
7.3.280.0090.00816.25
7.3.270.0110.00617.40
7.3.260.0120.00916.35
7.3.250.0090.01216.21
7.3.240.0150.00616.38
7.3.230.0090.00916.49
7.3.210.0110.00616.38
7.3.200.0140.00816.39
7.3.190.0090.00616.43
7.3.180.0150.00616.46
7.3.170.0130.00316.26
7.3.160.0070.01016.19
7.2.330.0060.01016.51
7.2.320.0030.02016.37
7.2.310.0090.00916.72
7.2.300.0100.00716.31
7.2.290.0060.01316.57
7.2.60.0090.00616.70
7.2.00.0030.00719.23
7.1.200.0020.01215.62
7.1.100.0070.00718.21
7.1.70.0100.01017.21
7.1.60.0220.01834.74
7.1.50.0310.01334.52
7.1.40.0240.01734.43
7.1.30.0250.01834.29
7.1.20.0260.01434.50
7.1.10.0060.01116.48
7.1.00.0030.01516.67
7.0.200.0030.01416.69
7.0.190.0040.01616.55
7.0.180.0110.00816.19
7.0.170.0070.00816.07
7.0.160.0030.01316.21
7.0.150.0100.00715.93
7.0.140.0090.00916.12
7.0.130.0070.00716.45
7.0.120.0050.01616.43
7.0.110.0080.01116.16
7.0.100.0160.00616.10
7.0.90.0080.01216.08
7.0.80.0000.01916.27
7.0.70.0060.01316.33
7.0.60.0030.01415.95
7.0.50.0080.01116.18
7.0.40.0100.01016.45
7.0.30.0040.01716.36
7.0.20.0060.01216.30
7.0.10.0100.01016.42
7.0.00.0130.00316.27

preferences:
45.92 ms | 400 KiB | 5 Q