3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Requires the GD Library header("Content-type: image/png"); $im = imagecreatetruecolor(512, 512) or die("Cannot Initialize new GD image stream"); $white = imagecolorallocate($im, 255, 255, 255); for ($y = 0; $y < 512; $y++) { for ($x = 0; $x < 512; $x++) { if (rand(0, 1)) { imagesetpixel($im, $x, $y, $white); } } } imagepng($im); imagedestroy($im);

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.1.30.0110.00617.60
8.1.20.0150.00217.47
8.1.10.0130.00317.45
8.1.00.0130.00417.38
8.0.160.0120.00316.80
8.0.150.0080.00616.84
8.0.140.0070.00716.76
8.0.130.0080.00616.76
8.0.120.0100.00316.83
8.0.110.0120.00116.76
8.0.100.0060.00816.80
8.0.90.0110.00416.76
8.0.80.0090.00716.83
8.0.70.0090.00716.71
8.0.60.0080.00616.78
8.0.50.0050.00916.82
8.0.30.0130.00216.89
8.0.20.0070.00716.89
8.0.10.0110.00316.90
8.0.00.0070.00516.93
7.4.280.0110.00416.45
7.4.270.0110.00616.39
7.4.260.0130.00516.46
7.4.250.0100.00516.49
7.4.240.0070.00816.41
7.4.230.0110.00416.40
7.4.220.0110.00316.44
7.4.210.0080.00616.46
7.4.200.0110.00216.48
7.4.190.0130.00016.50
7.4.180.0140.00216.44
7.4.160.0060.00916.46
7.4.150.0090.00416.48
7.4.140.0080.00516.35
7.4.130.0090.00316.42
7.4.120.0100.00316.42
7.4.110.0060.00816.36
7.4.100.0120.00216.45
7.4.90.0100.00316.28
7.4.80.0110.00216.35
7.4.70.0060.00716.33
7.4.60.0090.00516.37
7.4.50.0060.00716.25
7.4.40.0110.00216.36
7.4.30.0080.00516.29
7.4.20.0090.00316.33
7.4.10.0110.00415.90
7.4.00.0080.00915.57
7.3.330.0160.00416.22
7.3.320.0170.00316.14
7.3.310.0170.00316.24
7.3.300.0160.00416.17
7.3.290.0170.00216.17
7.3.280.0150.00516.18
7.3.270.0120.00816.20
7.3.260.0160.00416.31
7.3.250.0170.00216.14
7.3.240.0100.00916.34
7.3.230.0120.00616.10
7.3.220.0170.00216.08
7.3.210.0140.00516.13
7.3.200.0130.00616.15
7.3.190.0110.00816.18
7.3.180.0150.00416.26
7.3.170.0130.00616.05
7.3.160.0140.00516.02
7.3.150.0170.00216.30
7.3.140.0150.00416.14
7.3.130.0140.00415.59
7.3.120.0100.00915.29
7.3.110.0110.00715.20
7.3.100.0110.00615.39
7.3.90.0070.00915.49
7.3.80.0110.00415.27
7.3.70.0100.00615.33
7.3.60.0100.00615.28
7.3.50.0070.00815.30
7.3.40.0120.00515.31
7.3.30.0070.00815.38
7.3.20.0070.00817.17
7.3.10.0100.00517.14
7.3.00.0120.00517.21
7.2.340.0140.00416.03
7.2.330.0140.00616.13
7.2.320.0150.00516.20
7.2.310.0150.00516.21
7.2.300.0160.00316.28
7.2.290.0120.00816.20
7.2.280.0160.00316.19
7.2.270.0120.00816.15
7.2.260.0140.00515.83
7.2.250.0100.00915.29
7.2.240.0100.00815.47
7.2.230.0080.00815.34
7.2.220.0080.00915.38
7.2.210.0080.00915.34
7.2.200.0100.00715.54
7.2.190.0080.00815.56
7.2.180.0090.00715.39
7.2.170.0100.00715.49
7.2.160.0100.00615.50
7.2.150.0090.00717.52
7.2.140.0130.00417.35
7.2.130.0140.00717.43
7.2.120.0110.00817.49
7.2.110.0150.00417.48
7.2.100.0120.00617.51
7.2.90.0140.00417.56
7.2.80.0100.00917.43
7.2.70.0120.00617.52
7.2.60.0100.00617.47
7.2.50.0080.00917.54
7.2.40.0110.00817.54
7.2.30.0130.00517.53
7.2.20.0110.00817.51
7.2.10.0110.00617.49
7.2.00.0140.00817.56
7.1.330.0130.00516.24
7.1.320.0080.00616.20
7.1.310.0090.00716.25
7.1.300.0110.00716.31
7.1.290.0120.00316.29
7.1.280.0100.00616.22
7.1.270.0080.00716.25
7.1.260.0110.00416.23
7.1.250.0110.00816.48
7.1.240.0110.00716.19
7.1.230.0100.00716.47
7.1.220.0120.00516.46
7.1.210.0100.00816.45
7.1.200.0110.00816.28
7.1.190.0100.00816.37
7.1.180.0080.00616.34
7.1.170.0080.00916.31
7.1.160.0120.00416.44
7.1.150.0100.00716.41
7.1.140.0100.00816.33
7.1.130.0130.00316.40
7.1.120.0130.00516.35
7.1.110.0130.00416.45
7.1.100.0110.00416.36
7.1.90.0120.00516.37
7.1.80.0100.00616.38
7.1.70.0080.00716.47
7.1.60.0090.00916.58
7.1.50.0130.00416.55
7.1.40.0080.00716.40
7.1.30.0120.00516.46
7.1.20.0120.00516.35
7.1.10.0090.00716.42
7.1.00.0080.00616.42
7.0.330.0100.00516.04
7.0.320.0120.00316.04
7.0.310.0140.00316.09
7.0.300.0110.00516.14
7.0.290.0090.00516.04
7.0.280.0090.00616.03
7.0.270.0120.00516.08
7.0.260.0100.00516.07
7.0.250.0120.00316.10
7.0.240.0080.00816.18
7.0.230.0090.00816.10
7.0.220.0120.00515.99
7.0.210.0090.00816.02
7.0.200.0090.00716.18
7.0.190.0090.00516.21
7.0.180.0130.00316.20
7.0.170.0090.00716.22
7.0.160.0110.00316.23
7.0.150.0090.00616.19
7.0.140.0110.00416.20
7.0.130.0080.00616.23
7.0.120.0110.00516.23
7.0.110.0090.00516.20
7.0.100.0100.00416.18
7.0.90.0070.00916.21
7.0.80.0090.00616.17
7.0.70.0070.00716.18
7.0.60.0090.00416.17
7.0.50.0070.00816.11
7.0.40.0070.00715.50
7.0.30.0110.00415.51
7.0.20.0070.00815.37
7.0.10.0100.00415.49
7.0.00.0080.00815.46
5.6.400.0090.00514.96
5.6.390.0100.00414.78
5.6.380.0090.00514.82
5.6.370.0080.00714.78
5.6.360.0130.00314.72
5.6.350.0070.00714.93
5.6.340.0090.00714.77
5.6.330.0110.00514.85
5.6.320.0080.00814.86
5.6.310.0090.00714.75
5.6.300.0080.01215.88
5.6.290.0080.01415.98
5.6.280.0080.01416.11
5.6.270.0060.01516.04
5.6.260.0060.01516.03
5.6.250.0110.01316.17
5.6.240.0070.01415.95
5.6.230.0090.01516.11
5.6.220.0070.01416.03
5.6.210.0060.01715.99
5.6.200.0100.01216.05
5.6.190.0090.01416.15
5.6.180.0070.01416.10
5.6.170.0070.01616.01
5.6.160.0060.01416.16
5.6.150.0080.01316.12
5.6.140.0170.01316.13
5.6.130.0080.01316.08
5.6.120.0080.01715.96
5.6.110.0100.01115.98
5.6.100.0100.01116.05
5.6.90.0090.01216.07
5.6.80.0080.01215.92
5.6.70.0080.01315.86
5.6.60.0140.01215.92
5.6.50.0090.01115.85
5.6.40.0080.01315.84
5.6.30.0070.01315.86
5.6.20.0050.01415.80
5.6.10.0070.01915.87
5.6.00.0110.01015.82
5.5.380.0080.02116.26
5.5.370.0100.01716.35
5.5.360.0230.01816.08
5.5.350.0100.01916.09
5.5.340.0090.01716.21
5.5.330.0080.01816.27
5.5.320.0080.01916.28
5.5.310.0070.01916.44
5.5.300.0110.01416.33
5.5.290.0100.01716.26
5.5.280.0110.01516.33
5.5.270.0120.01616.28
5.5.260.0090.01816.26
5.5.250.0110.01416.30
5.5.240.0100.01516.27
5.5.230.0090.01616.21
5.5.220.0100.01516.26
5.5.210.0190.01216.18
5.5.200.0100.01616.00
5.5.190.0120.01815.90
5.5.180.0110.01516.08
5.5.170.0100.00615.37
5.5.160.0100.01415.95
5.5.150.0100.01615.88
5.5.140.0090.01615.83
5.5.130.0080.01615.99
5.5.120.0090.01816.01
5.5.110.0120.01215.97
5.5.100.0080.02116.04
5.5.90.0090.01816.09
5.5.80.0120.01316.05
5.5.70.0070.02115.99
5.5.60.0100.01716.02
5.5.50.0080.01715.99
5.5.40.0080.01616.02
5.5.30.0100.01616.14
5.5.20.0090.01516.09
5.5.10.0090.01616.05
5.5.00.0080.01616.08
5.4.450.0070.01614.69
5.4.440.0090.01314.73
5.4.430.0060.01714.70
5.4.420.0080.01614.79
5.4.410.0100.01514.57
5.4.400.0070.01614.49
5.4.390.0090.01514.60
5.4.380.0050.01714.62
5.4.370.0070.01514.57
5.4.360.0090.01514.54
5.4.350.0070.01714.50
5.4.340.0080.01614.64
5.4.330.0120.00212.27
5.4.320.0070.01714.63
5.4.310.0050.01814.58
5.4.300.0090.01414.65
5.4.290.0100.02214.57
5.4.280.0120.01214.61
5.4.270.0090.01414.48
5.4.260.0100.01514.63
5.4.250.0100.01514.55
5.4.240.0070.01414.62
5.4.230.0090.01614.43
5.4.220.0080.01714.51
5.4.210.0110.01314.37
5.4.200.0070.01814.36
5.4.190.0080.01814.46
5.4.180.0080.01514.41
5.4.170.0130.01414.55
5.4.160.0100.01614.43
5.4.150.0090.01614.33
5.4.140.0050.02113.69
5.4.130.0080.01713.74
5.4.120.0090.01513.79
5.4.110.0070.01713.79
5.4.100.0110.01413.74
5.4.90.0100.01413.77
5.4.80.0100.01213.78
5.4.70.0090.01613.89
5.4.60.0110.01213.86
5.4.50.0100.01313.70
5.4.40.0120.01113.83
5.4.30.0090.01513.85
5.4.20.0090.01513.75
5.4.10.0090.01513.88
5.4.00.0090.01313.75
5.3.290.0170.01614.20
5.3.280.0060.02114.16
5.3.270.0080.01714.19
5.3.260.0100.01514.05
5.3.250.0090.01414.20
5.3.240.0090.01613.98
5.3.230.0080.01514.11
5.3.220.0090.01314.04
5.3.210.0070.01814.13
5.3.200.0130.01714.05
5.3.190.0070.01614.15
5.3.180.0090.01514.16
5.3.170.0100.01314.26
5.3.160.0070.01614.17
5.3.150.0090.01414.18
5.3.140.0160.01414.29
5.3.130.0060.01814.30
5.3.120.0090.01514.18
5.3.110.0090.01514.18
5.3.100.0080.01514.09
5.3.90.0080.01614.22
5.3.80.0090.01414.02
5.3.70.0070.01513.99
5.3.60.0100.01214.23
5.3.50.0060.01714.08
5.3.40.0060.01714.18
5.3.30.0100.01314.19
5.3.20.0080.01414.01
5.3.10.0090.01314.02
5.3.00.0060.01713.96

preferences:
44.94 ms | 401 KiB | 5 Q