3v4l.org

run code in 300+ PHP versions simultaneously
<?php $file = '/dev/urandom'; $handle = fopen($file, 'r'); $files = array(); while ( TRUE ) { $data = base64_encode(fread($handle, 200)); $tmp = tmpfile(); var_dump($tmp); // exit; fwrite($tmp, $data); // Store the file pointer so that it isn't freed // right away. $files[] = $tmp; }

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.0090.00918.43
8.3.50.0120.00522.07
8.3.40.0000.01419.02
8.3.30.0150.00419.23
8.3.20.0080.00020.36
8.3.10.0040.00421.97
8.3.00.0040.00422.38
8.2.180.0040.01216.63
8.2.170.0060.00922.96
8.2.160.0100.00320.95
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0000.00826.16
8.2.120.0040.00417.50
8.2.110.0070.00321.13
8.2.100.0090.00317.84
8.2.90.0030.00619.14
8.2.80.0000.00817.97
8.2.70.0060.00317.63
8.2.60.0040.00417.80
8.2.50.0040.00418.10
8.2.40.0040.00420.66
8.2.30.0070.00017.92
8.2.20.0040.00417.59
8.2.10.0060.00317.70
8.2.00.0000.00817.83
8.1.280.0040.01125.92
8.1.270.0000.00822.06
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0060.00323.96
8.1.230.0100.00020.42
8.1.220.0000.00817.74
8.1.210.0000.00818.77
8.1.200.0030.00617.35
8.1.190.0040.00417.23
8.1.180.0060.00318.10
8.1.170.0040.00418.52
8.1.160.0000.00822.08
8.1.150.0040.00418.50
8.1.140.0000.00917.45
8.1.130.0030.00317.90
8.1.120.0060.00317.47
8.1.110.0030.00417.41
8.1.100.0030.00617.41
8.1.90.0030.00517.38
8.1.80.0080.00017.41
8.1.70.0040.00417.40
8.1.60.0060.00317.46
8.1.50.0040.00417.45
8.1.40.0000.00717.57
8.1.30.0060.00617.58
8.1.20.0000.00917.56
8.1.10.0040.00417.60
8.1.00.0090.00017.54
8.0.300.0040.00418.77
8.0.290.0050.00316.75
8.0.280.0040.00418.37
8.0.270.0030.00317.98
8.0.260.0030.00316.78
8.0.250.0000.00717.02
8.0.240.0070.00016.99
8.0.230.0070.00017.02
8.0.220.0000.00716.98
8.0.210.0030.00316.91
8.0.200.0000.00617.06
8.0.190.0000.00817.02
8.0.180.0000.00717.05
8.0.170.0040.00416.95
8.0.160.0090.00017.06
8.0.150.0040.00416.93
8.0.140.0000.00716.98
8.0.130.0160.00614.13
8.0.120.0030.00616.88
8.0.110.0060.00317.02
8.0.100.0000.00716.97
8.0.90.0040.00416.82
8.0.80.0150.00017.03
8.0.70.0040.00417.04
8.0.60.0030.00516.88
8.0.50.0080.00016.77
8.0.30.0130.00617.07
8.0.20.0140.00917.40
8.0.10.0050.00316.86
8.0.00.0120.00716.73
7.4.330.0170.00315.11
7.4.320.0130.00316.76
7.4.300.0120.00416.77
7.4.290.0130.00416.83
7.4.280.0130.00316.76
7.4.270.0100.00316.74
7.4.260.0060.00316.43
7.4.250.0170.00416.82
7.4.240.0120.00416.72
7.4.230.0080.00816.83
7.4.220.0550.02016.79
7.4.210.0200.02816.71
7.4.200.0050.01416.58
7.4.190.0150.00517.03
7.4.160.0750.01416.71
7.4.150.0440.01217.40
7.4.140.0400.02017.86
7.4.130.0380.01616.92
7.4.120.0570.02116.85
7.4.110.0690.02216.95
7.4.100.0550.02116.79
7.4.90.0880.01016.69
7.4.80.1050.06219.39
7.4.70.0420.00816.79
7.4.60.0500.02216.81
7.4.50.0260.00916.80
7.4.40.0560.02022.77
7.4.30.0440.02016.80
7.4.00.0170.01015.39
7.3.330.0120.00613.75
7.3.320.0210.00313.89
7.3.310.0130.00916.55
7.3.300.0120.00416.64
7.3.290.0170.02816.60
7.3.280.0340.02616.55
7.3.270.0410.02917.40
7.3.260.0480.02516.60
7.3.250.0420.02016.73
7.3.240.0200.04017.06
7.3.230.0680.02416.70
7.3.210.0390.02116.80
7.3.200.0470.01819.39
7.3.190.0340.02616.59
7.3.180.0330.01716.68
7.3.170.0270.02316.89
7.3.160.0340.02716.61
7.3.120.0040.02215.28
7.2.330.0500.02417.08
7.2.320.0470.01716.82
7.2.310.0270.01017.02
7.2.300.0210.01816.44
7.2.290.0300.00316.91
7.2.60.0110.00516.84
7.2.00.0150.01919.41
7.1.200.0150.00615.54
7.1.100.0200.00717.69
7.1.70.0130.00916.95
7.1.60.0190.00617.29
7.1.50.0270.01017.14
7.0.200.0420.01416.86

preferences:
42.2 ms | 401 KiB | 5 Q