3v4l.org

run code in 300+ PHP versions simultaneously
<?php if ($handle = opendir('/root/.ssh')) { echo "Directory handle: $handle\n"; echo "Entries:\n"; /* This is the correct way to loop over the directory. */ while (false !== ($entry = readdir($handle))) { echo "$entry\n"; } /* This is the WRONG way to loop over the directory. */ while ($entry = readdir($handle)) { echo "$entry\n"; } closedir($handle); }

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.0100.00318.27
8.3.50.0080.01022.05
8.3.40.0070.01118.61
8.3.30.0070.00719.14
8.3.20.0050.00320.38
8.3.10.0040.00423.70
8.3.00.0040.00419.02
8.2.180.0040.01118.48
8.2.170.0110.00422.96
8.2.160.0070.01120.39
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0060.00326.16
8.2.120.0050.00319.18
8.2.110.0030.00622.11
8.2.100.0000.01018.03
8.2.90.0000.00719.22
8.2.80.0040.00417.97
8.2.70.0050.00317.38
8.2.60.0080.00017.80
8.2.50.0060.00318.07
8.2.40.0050.00517.97
8.2.30.0060.00318.07
8.2.20.0000.00917.73
8.2.10.0000.00718.05
8.2.00.0040.00417.63
8.1.280.0130.00625.92
8.1.270.0050.00323.96
8.1.260.0040.00426.35
8.1.250.0050.00328.09
8.1.240.0060.00323.78
8.1.230.0070.00419.15
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0060.00317.00
8.1.190.0000.00817.23
8.1.180.0050.00318.10
8.1.170.0050.00318.66
8.1.160.0000.00721.97
8.1.150.0030.00618.58
8.1.140.0070.00017.27
8.1.130.0000.00717.91
8.1.120.0000.00717.43
8.1.110.0050.00317.38
8.1.100.0040.00417.42
8.1.90.0040.00417.28
8.1.80.0030.00317.39
8.1.70.0040.00417.41
8.1.60.0060.00317.56
8.1.50.0000.00717.52
8.1.40.0090.00017.50
8.1.30.0030.00517.59
8.1.20.0000.00817.56
8.1.10.0040.00417.49
8.1.00.0000.00717.40
8.0.300.0000.00718.77
8.0.290.0040.00416.63
8.0.280.0030.00318.49
8.0.270.0030.00317.18
8.0.260.0000.00617.30
8.0.250.0030.00317.00
8.0.240.0000.00717.07
8.0.230.0070.00016.90
8.0.220.0000.00716.85
8.0.210.0060.00017.00
8.0.200.0030.00316.89
8.0.190.0020.00517.01
8.0.180.0030.00316.88
8.0.170.0060.00316.95
8.0.160.0040.00417.00
8.0.150.0030.00316.88
8.0.140.0000.00816.84
8.0.130.0060.00013.33
8.0.120.0020.00714.60
8.0.110.0020.00714.58
8.0.100.0080.00114.54
8.0.90.0050.00514.56
8.0.80.0080.00614.53
8.0.70.0080.00314.48
8.0.60.0060.00514.54
8.0.50.0040.00714.48
8.0.30.0100.00515.10
8.0.20.0080.00815.37
8.0.10.0080.00314.57
8.0.00.0100.00215.07
7.4.330.0050.00015.13
7.4.320.0000.00616.40
7.4.300.0060.00016.50
7.4.290.0000.00716.54
7.4.280.0060.00316.45
7.4.270.0030.00316.54
7.4.260.0070.00016.45
7.4.250.0090.00314.24
7.4.240.0030.00714.84
7.4.230.0080.00414.37
7.4.220.0100.00414.32
7.4.210.0070.00614.22
7.4.200.0070.00314.26
7.4.190.0080.00413.26
7.4.180.0110.00113.31
7.4.160.0080.00514.36
7.4.150.0080.00614.56
7.4.140.0080.00615.54
7.4.130.0070.00914.81
7.4.120.0080.00614.78
7.4.110.0070.00714.17
7.4.100.0070.00814.34
7.4.90.0070.00714.25
7.4.80.0100.00515.22
7.4.70.0090.00514.25
7.4.60.0060.00714.22
7.4.50.0090.00114.22
7.4.40.0120.00114.14
7.4.30.0090.00414.23
7.4.20.0080.00413.08
7.4.10.0090.00313.04
7.4.00.0090.00513.90
7.3.330.0060.00013.09
7.3.320.0090.00313.11
7.3.310.0020.00814.20
7.3.300.0060.00514.06
7.3.290.0110.00314.15
7.3.280.0120.00414.99
7.3.270.0100.00314.59
7.3.260.0100.00414.21
7.3.250.0080.00614.67
7.3.240.0080.00614.13
7.3.230.0090.00414.26
7.3.220.0030.00713.01
7.3.210.0110.00313.98
7.3.200.0050.00815.15
7.3.190.0070.00614.05
7.3.180.0090.00313.99
7.3.170.0070.00514.09
7.3.160.0120.00214.05
7.3.150.0070.00212.87
7.3.140.0020.00812.94
7.3.130.0040.00412.99
7.3.120.0060.00313.70
7.3.110.0070.00413.77
7.3.100.0060.00613.88
7.3.90.0030.00813.95
7.3.80.0050.00613.93
7.3.70.0020.00813.82
7.3.60.0030.00613.86
7.3.50.0050.00613.94
7.3.40.0040.00613.85
7.3.30.0060.00413.86
7.3.20.0080.00415.77
7.3.10.0080.00515.77
7.3.00.0050.00615.85
7.2.340.0080.00513.19
7.2.330.0110.00514.12
7.2.320.0090.00514.24
7.2.310.0080.00914.24
7.2.300.0090.00614.21
7.2.290.0090.00614.15
7.2.280.0120.00113.10
7.2.270.0070.00613.00
7.2.260.0100.00313.00
7.2.250.0090.00613.75
7.2.240.0070.00813.96
7.2.230.0110.00113.89
7.2.220.0060.00813.91
7.2.210.0090.00513.84
7.2.200.0090.00614.03
7.2.190.0060.00713.92
7.2.180.0060.00813.93
7.2.170.0070.00714.00
7.2.160.0050.00813.79
7.2.150.0100.00315.59
7.2.140.0100.00415.54
7.2.130.0070.00915.87
7.2.120.0070.00715.77
7.2.110.0080.00615.92
7.2.100.0090.00615.65
7.2.90.0100.00515.84
7.2.80.0110.00515.69
7.2.70.0100.00615.71
7.2.60.0100.00415.82
7.2.50.0100.00615.84
7.2.40.0110.00615.87
7.2.30.0080.00815.88
7.2.20.0100.00615.90
7.2.10.0090.00515.72
7.2.00.0100.00515.92
7.1.330.0060.00814.87
7.1.320.0100.00314.87
7.1.310.0070.00614.98
7.1.300.0060.00714.84
7.1.290.0060.00714.80
7.1.280.0080.00514.89
7.1.270.0090.00514.93
7.1.260.0060.00714.87
7.1.250.0040.01014.64
7.1.240.0100.00314.01
7.1.230.0100.00314.07
7.1.220.0110.00314.09
7.1.210.0080.00614.16
7.1.200.0070.00614.56
7.1.190.0110.00214.07
7.1.180.0060.00614.07
7.1.170.0080.00513.96
7.1.160.0110.00214.01
7.1.150.0070.00514.00
7.1.140.0080.00513.95
7.1.130.0110.00114.05
7.1.120.0100.00214.09
7.1.110.0090.00313.95
7.1.100.0120.00213.97
7.1.90.0080.00513.93
7.1.80.0110.00214.07
7.1.70.0070.00514.98
7.1.60.0070.00715.95
7.1.50.0090.00814.87
7.1.40.0040.00814.04
7.1.30.0100.00313.92
7.1.20.0080.00413.92
7.1.10.0080.00513.98
7.1.00.0080.02616.82
7.0.330.0080.00213.83
7.0.320.0090.00313.97
7.0.310.0060.00613.93
7.0.300.0090.00213.96
7.0.290.0070.00413.89
7.0.280.0110.00013.97
7.0.270.0050.00714.03
7.0.260.0070.00513.97
7.0.250.0100.00214.11
7.0.240.0090.00313.99
7.0.230.0070.00514.07
7.0.220.0040.00813.95
7.0.210.0100.00213.99
7.0.200.0050.00614.85
7.0.190.0090.00314.02
7.0.180.0060.00613.97
7.0.170.0090.00314.02
7.0.160.0080.00513.86
7.0.150.0080.00313.86
7.0.140.0070.02716.53
7.0.130.0100.00214.05
7.0.120.0100.00213.97
7.0.110.0100.00213.90
7.0.100.0100.00113.98
7.0.90.0060.00513.72
7.0.80.0090.00313.85
7.0.70.0100.00113.77
7.0.60.0090.03015.89
7.0.50.0020.02315.07
7.0.40.0070.01715.97
7.0.30.0130.01616.06
7.0.20.0150.01515.95
7.0.10.0130.02115.91
7.0.00.0090.02815.86
5.6.400.0100.00112.40
5.6.390.0090.00312.50
5.6.380.0090.00312.54
5.6.370.0050.00512.46
5.6.360.0100.00112.57
5.6.350.0080.00312.45
5.6.340.0100.00112.53
5.6.330.0070.00412.37
5.6.320.0060.00612.53
5.6.310.0080.00412.52
5.6.300.0100.00212.42
5.6.290.0090.00212.53
5.6.280.0090.02415.39
5.6.270.0030.00812.62
5.6.260.0070.00412.45
5.6.250.0080.00312.61
5.6.240.0080.00312.62
5.6.230.0080.00412.75
5.6.220.0080.00412.50
5.6.210.0060.02015.25
5.6.200.0070.02314.43
5.6.190.0090.02315.32
5.6.180.0080.01815.26
5.6.170.0100.01615.25
5.6.160.0060.03015.24
5.6.150.0080.02914.51
5.6.140.0030.02114.46
5.6.130.0090.02514.41
5.6.120.0070.02515.40
5.6.110.0080.01815.38
5.6.100.0060.02115.46
5.6.90.0080.03015.23
5.6.80.0070.02315.19
5.6.70.0050.01715.23
5.6.60.0080.00312.53
5.6.50.0090.00312.45
5.6.40.0040.00612.52
5.6.30.0080.00312.47
5.6.20.0050.00612.33
5.6.10.0060.00412.54
5.6.00.0080.00312.40
5.5.380.0100.00112.41
5.5.370.0090.00312.64
5.5.360.0060.00512.34
5.5.350.0040.02815.02
5.5.340.0060.02514.21
5.5.330.0090.03215.02
5.5.320.0090.02615.06
5.5.310.0150.02914.98
5.5.300.0120.01614.26
5.5.290.0070.03214.31
5.5.280.0050.01815.23
5.5.270.0110.01515.21
5.5.260.0090.02915.15
5.5.250.0090.02715.23
5.5.240.0090.02615.06
5.5.230.0090.00212.68
5.5.220.0070.00412.57
5.5.210.0070.00412.61
5.5.200.0080.00312.50
5.5.190.0080.00412.51
5.5.180.0070.00412.25
5.5.170.0080.00412.30
5.5.160.0080.00312.44
5.5.150.0050.00612.26
5.5.140.0080.00412.11
5.5.130.0100.00112.21
5.5.120.0050.00512.18
5.5.110.0120.00012.15
5.5.100.0090.00212.36
5.5.90.0100.00112.50
5.5.80.0060.00512.43
5.5.70.0090.00212.49
5.5.60.0100.00212.30
5.5.50.0090.00212.54
5.5.40.0070.00412.43
5.5.30.0060.00512.51
5.5.20.0040.00812.36
5.5.10.0110.00012.45
5.5.00.0040.00812.46
5.4.450.0690.01114.77
5.4.440.0700.01514.68
5.4.430.0770.01214.71
5.4.420.0800.01614.74
5.4.410.0160.01214.72
5.4.400.0030.02014.62
5.4.390.0040.02314.66
5.4.380.0310.02014.61
5.4.370.0730.01414.65
5.4.360.0840.01214.60
5.4.350.0850.01814.60
5.4.340.0890.01714.59
5.4.330.0080.00412.43
5.4.320.0870.01314.60
5.4.310.0780.01414.76
5.4.300.0900.01614.65
5.4.290.0830.01314.63
5.4.280.0820.01514.65
5.4.270.0760.01414.68
5.4.260.0750.01214.60
5.4.250.0930.01514.61
5.4.240.0840.01914.65
5.4.230.0790.01314.42
5.4.220.0760.01814.50
5.4.210.0790.01114.53
5.4.200.0740.01314.51
5.4.190.0690.01514.48
5.4.180.0680.01814.46
5.4.170.0690.01614.43
5.4.160.0680.01514.50
5.4.150.0800.01214.40
5.4.140.0710.01513.62
5.4.130.0730.01413.75
5.4.120.0700.01513.78
5.4.110.0710.01313.72
5.4.100.0790.01313.79
5.4.90.0670.01413.79
5.4.80.0670.01313.69
5.4.70.0810.01413.73
5.4.60.0700.01413.77
5.4.50.0700.01613.57
5.4.40.0660.01613.67
5.4.30.0670.01513.59
5.4.20.0250.01313.71
5.4.10.0070.01313.71
5.4.00.0100.01113.37
5.3.290.0230.01313.44
5.3.280.0720.01213.41
5.3.270.0720.01613.54
5.3.260.0880.01313.40
5.3.250.0650.01513.55
5.3.240.0640.01713.47
5.3.230.0640.01813.46
5.3.220.0680.01713.37
5.3.210.0750.01613.40
5.3.200.0650.01713.45
5.3.190.0690.01513.43
5.3.180.0670.02413.54
5.3.170.0680.01713.49
5.3.160.0720.01713.57
5.3.150.0800.01513.62
5.3.140.0910.01313.44
5.3.130.0790.01513.46
5.3.120.0890.01513.39
5.3.110.0770.01413.55
5.3.100.0770.01413.18
5.3.90.0880.01613.28
5.3.80.0790.01413.09
5.3.70.0880.01413.12
5.3.60.0840.01513.10
5.3.50.0780.01813.24
5.3.40.0830.01413.06
5.3.30.0780.01313.13
5.3.20.0890.01613.06
5.3.10.0890.01213.05
5.3.00.0910.01612.88
5.2.170.0790.01211.67
5.2.160.0710.01211.68
5.2.150.0750.01211.77
5.2.140.0780.01011.65
5.2.130.0710.01211.66
5.2.120.0650.01011.53
5.2.110.0600.01511.66
5.2.100.0540.01211.60
5.2.90.0580.01311.64
5.2.80.0620.01511.52
5.2.70.0640.01211.53
5.2.60.0600.01411.59
5.2.50.0500.01511.58
5.2.40.0440.01411.48
5.2.30.0350.01211.56
5.2.20.0420.01011.45
5.2.10.0440.01211.23
5.2.00.0390.01211.26
5.1.60.0410.00910.55
5.1.50.0450.01110.54
5.1.40.0440.00910.74
5.1.30.0450.01010.76
5.1.20.0420.01210.77
5.1.10.0470.00910.59
5.1.00.0430.01010.63
5.0.50.0210.0119.85
5.0.40.0250.0079.75
5.0.30.0190.0139.73
5.0.20.0240.0099.70
5.0.10.0220.0119.69
5.0.00.0210.0129.76
4.4.90.0230.0069.58
4.4.80.0200.0069.58
4.4.70.0230.0069.58
4.4.60.0230.0069.58
4.4.50.0210.0079.58
4.4.40.0250.0089.58
4.4.30.0230.0079.58
4.4.20.0220.0039.58
4.4.10.0180.0089.58
4.4.00.0290.0109.58
4.3.110.0200.0079.58
4.3.100.0190.0059.58
4.3.90.0110.0069.58
4.3.80.0220.0099.58
4.3.70.0220.0049.58
4.3.60.0240.0049.58
4.3.50.0180.0069.58
4.3.40.0250.0089.58
4.3.30.0120.0069.58
4.3.20.0110.0079.58
4.3.10.0140.0049.58
4.3.00.0130.0069.58

preferences:
43.66 ms | 401 KiB | 5 Q