3v4l.org

run code in 300+ PHP versions simultaneously
<?php $url = 'http://localhost/img/'; $dir = 'C:\Program Files\Apache Group\Apache2\htdocs\img'; $max = 5; $images = array( '.', '..', 'a.jpg', 'b.GIF', 'C.png', 'd.JPEG', 'e.jpg', 'f.tiff', 'g.png', 'h.bmp', 'i.jpg', 'j.GIF', 'k.png', ); $images = preg_grep('/\.(?:jpe?g|gif|png)\z/i', $images); ?> <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>画像</title> </head> <body> <h1><?=$dir?>内の画像一覧</h1> <?php if (!$images): ?> <p>表示する画像はありません</p> <?php else: ?> <table> <tr> <?php foreach ($images as $i => $img): ?> <?php if ($i !== 0 && $i % $max === 0): ?> </tr> <tr> <?php endif; ?> <td><img src="<?php echo $url.$img; ?>"></td> <?php endforeach; ?> </tr> </table> <?php endif; ?> </body> </html>

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.0090.00616.88
8.3.60.0120.00318.55
8.3.50.0150.00721.14
8.3.40.0150.00618.93
8.3.30.0120.00318.80
8.3.20.0120.00318.74
8.3.10.0040.00421.04
8.3.00.0000.00823.68
8.2.180.0160.00318.54
8.2.170.0070.00722.96
8.2.160.0000.01520.47
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0080.00026.16
8.2.120.0000.00721.20
8.2.110.0060.00322.43
8.2.100.0040.00818.03
8.2.90.0080.00019.09
8.2.80.0000.00917.97
8.2.70.0000.00817.75
8.2.60.0040.00417.93
8.2.50.0000.00818.07
8.2.40.0000.00818.22
8.2.30.0040.00419.87
8.2.20.0030.00517.86
8.2.10.0050.00217.97
8.2.00.0000.00817.96
8.1.280.0090.00625.92
8.1.270.0060.00323.99
8.1.260.0110.00726.35
8.1.250.0000.00828.09
8.1.240.0060.00322.58
8.1.230.0040.00820.96
8.1.220.0040.00418.77
8.1.210.0030.00618.96
8.1.200.0030.00617.47
8.1.190.0040.00417.52
8.1.180.0000.00818.10
8.1.170.0040.00418.84
8.1.160.0050.00318.88
8.1.150.0040.00418.81
8.1.140.0030.00517.64
8.1.130.0030.00317.82
8.1.120.0000.00717.60
8.1.110.0040.00417.59
8.1.100.0070.00017.60
8.1.90.0000.00817.67
8.1.80.0000.00717.51
8.1.70.0000.00717.59
8.1.60.0030.00717.68
8.1.50.0000.00717.62
8.1.40.0000.00917.70
8.1.30.0040.00417.73
8.1.20.0050.00317.86
8.1.10.0030.00517.70
8.1.00.0030.00717.61
8.0.300.0030.00619.86
8.0.290.0030.00716.88
8.0.280.0000.00718.38
8.0.270.0050.00217.20
8.0.260.0030.00316.98
8.0.250.0000.00817.05
8.0.240.0030.00517.12
8.0.230.0000.00717.13
8.0.220.0030.00317.11
8.0.210.0000.00717.04
8.0.200.0030.00317.02
8.0.190.0040.00417.01
8.0.180.0000.00917.08
8.0.170.0080.00017.05
8.0.160.0040.00416.92
8.0.150.0050.00517.06
8.0.140.0040.00417.09
8.0.130.0000.00713.56
8.0.120.0030.00817.07
8.0.110.0040.00316.91
8.0.100.0000.00816.96
8.0.90.0000.00717.11
8.0.80.0120.00317.04
8.0.70.0040.00416.83
8.0.60.0040.00417.12
8.0.50.0000.00816.98
8.0.30.0100.01117.50
8.0.20.0130.00817.40
8.0.10.0040.00417.04
8.0.00.0150.00316.89
7.4.330.0000.00514.86
7.4.320.0000.00716.73
7.4.300.0000.00716.64
7.4.290.0040.00416.71
7.4.280.0030.00316.69
7.4.270.0000.00716.65
7.4.260.0050.00013.39
7.4.250.0000.00816.70
7.4.240.0030.00316.82
7.4.230.0070.00016.83
7.4.220.0060.00916.92
7.4.210.0090.00816.74
7.4.200.0000.00816.84
7.4.190.0000.00716.92
7.4.160.0080.00816.78
7.4.150.0060.01217.40
7.4.140.0130.00517.86
7.4.130.0100.00816.76
7.4.120.0100.00716.77
7.4.110.0070.01116.71
7.4.100.0120.00616.66
7.4.90.0030.01616.64
7.4.80.0120.00619.37
7.4.70.0110.00516.74
7.4.60.0120.00616.78
7.4.50.0030.00616.70
7.4.40.0030.01422.27
7.4.30.0130.00316.57
7.4.00.0090.00915.40
7.3.330.0000.00513.24
7.3.320.0040.00313.37
7.3.310.0030.00316.50
7.3.300.0070.00016.43
7.3.290.0000.01616.46
7.3.280.0100.00716.50
7.3.270.0110.00617.40
7.3.260.0120.00818.24
7.3.250.0110.01016.62
7.3.240.0120.00416.53
7.3.230.0130.00316.68
7.3.210.0100.01316.75
7.3.200.0070.01119.39
7.3.190.0130.00616.79
7.3.180.0130.00316.75
7.3.170.0090.00616.59
7.3.160.0070.01016.57
7.3.120.0090.00615.08
7.2.330.0250.01616.69
7.2.320.0030.01416.77
7.2.310.0070.01016.88
7.2.300.0040.01316.75
7.2.290.0140.00716.91
7.1.70.0060.00317.44
7.1.60.0130.01319.40
7.1.50.0110.01417.13
7.1.00.0030.06722.42
7.0.200.0170.00715.13
7.0.140.0070.07322.05
7.0.60.0330.07319.82
7.0.50.0100.06717.82
7.0.40.0100.06720.25
7.0.30.0170.05020.11
7.0.20.0300.05020.18
7.0.10.0130.05320.21
7.0.00.0030.08020.45
5.6.280.0070.07020.81
5.6.210.0070.08320.51
5.6.200.0100.04018.09
5.6.190.0000.05020.27
5.6.180.0270.08320.44
5.6.170.0330.08320.49
5.6.160.0030.05020.51
5.6.150.0070.08318.15
5.6.140.0030.07318.07
5.6.130.0170.06318.21
5.6.120.0100.05321.02
5.6.110.0030.05021.00
5.6.100.0100.07720.97
5.6.90.0070.08720.99
5.6.80.0100.08020.48
5.5.350.0330.06720.45
5.5.340.0130.04717.91
5.5.330.0130.04720.25
5.5.320.0470.07020.34
5.5.310.0330.08020.29
5.5.300.0100.07318.02
5.5.290.0070.07718.01
5.5.280.0100.08020.65
5.5.270.0070.07720.79
5.5.260.0100.06320.75
5.5.250.0200.07020.61
5.5.240.0070.07720.32
5.4.450.4030.03719.47
5.4.440.0030.08019.48
5.4.430.1530.06019.29
5.4.420.4570.04319.24
5.4.410.3700.03719.29
5.4.400.3970.04018.89
5.4.390.3530.04318.97
5.4.380.3700.04018.97
5.4.370.4070.04018.87
5.4.360.3630.03718.86
5.4.350.3670.02718.88
5.4.340.3970.04019.05
5.4.320.4600.03319.00
5.4.310.3830.04019.04
5.4.300.3700.03719.08
5.4.290.3600.04019.17
5.4.280.0030.07019.05
5.4.270.0070.03719.14
5.4.260.4400.03318.96
5.4.250.4630.02718.91
5.4.240.3500.04019.14
5.4.230.3830.04319.19
5.4.220.3800.04319.05
5.4.210.3630.04019.12
5.4.200.3770.04019.03
5.4.190.4530.04018.89
5.4.180.0170.05319.04
5.4.170.3230.04319.05
5.4.160.4130.04019.02
5.4.150.4130.03319.01
5.4.140.4500.04316.39
5.4.130.4330.04016.13
5.4.120.4600.03316.39
5.4.110.4630.03316.40
5.4.100.3930.03716.35
5.4.90.3730.03316.33
5.4.80.3830.04016.14
5.4.70.3370.03716.26
5.4.60.4070.03316.35
5.4.50.4030.03316.46
5.4.40.3730.03316.33
5.4.30.3730.03316.47
5.4.20.3700.02716.23
5.4.10.3630.03316.24
5.4.00.3730.03315.89
5.3.290.4470.04314.63
5.3.280.4700.03314.53
5.3.270.0070.05314.43
5.3.260.4500.04314.56
5.3.250.3600.03014.57
5.3.240.4330.03014.51
5.3.230.4630.03314.50
5.3.220.4370.04014.53
5.3.210.3900.03314.59
5.3.200.3570.03314.36
5.3.190.3970.03014.67
5.3.180.3770.03714.53
5.3.170.3730.03714.44
5.3.160.4270.04014.35
5.3.150.3830.04014.49
5.3.140.4170.03314.50
5.3.130.4070.04014.49
5.3.120.3700.03014.50
5.3.110.3630.04014.37
5.3.100.3670.04014.13
5.3.90.3670.03713.95
5.3.80.3400.03713.97
5.3.70.3530.03713.81
5.3.60.3670.03013.98
5.3.50.2730.03713.96
5.3.40.3600.03014.04
5.3.30.4030.04013.70
5.3.20.3970.03013.78
5.3.10.3630.03713.60
5.3.00.3900.03013.47
5.2.170.3030.03011.23
5.2.160.2970.03011.09
5.2.150.3170.02711.09
5.2.140.3030.03010.97
5.2.130.3400.03311.09
5.2.120.3270.03010.96
5.2.110.3370.05311.10
5.2.100.3400.03311.09
5.2.90.2970.03011.09
5.2.80.2930.03311.09
5.2.70.3870.03011.05
5.2.60.2930.03310.95
5.2.50.3200.02710.95
5.2.40.3030.03010.82
5.2.30.2830.02711.05
5.2.20.2830.03011.05
5.2.10.3030.03010.91
5.2.00.3270.02310.60
5.1.60.2970.0209.99
5.1.50.2700.0209.96
5.1.40.2470.0279.88
5.1.30.3170.02310.34
5.1.20.3070.02710.34
5.1.10.2900.02310.08
5.1.00.3200.0279.99
5.0.50.1270.0238.55
5.0.40.1470.0208.32
5.0.30.1770.0308.21
5.0.20.1800.0238.34
5.0.10.2030.0138.32
5.0.00.1800.0338.18
4.4.90.1430.0176.50
4.4.80.1500.0176.50
4.4.70.1270.0206.50
4.4.60.1730.0176.50
4.4.50.1800.0136.50
4.4.40.1430.0236.51
4.4.30.1470.0136.51
4.4.20.1630.0176.51
4.4.10.1430.0176.51
4.4.00.1770.0276.51
4.3.110.1700.0176.51
4.3.100.1670.0176.51
4.3.90.1530.0176.51
4.3.80.1630.0306.51
4.3.70.1270.0206.51
4.3.60.1200.0136.51
4.3.50.1500.0176.51
4.3.40.1400.0306.51
4.3.30.0800.0206.51
4.3.20.0900.0276.51
4.3.10.0130.0176.51
4.3.00.0900.0206.51

preferences:
50.65 ms | 401 KiB | 5 Q