3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo($rewind = false) { static $data = array( array('site_name' => 'bar'), array(), array('site_name' => 'baz') ); if ($rewind) { rewind($data); return; } $current = current($data); next($data); return $current; } while ($bar = foo()) echo $bar['site_name']."\n"; foo(true); echo '-------------------------------------------'."\n"; while (($bar = foo()) !== false) echo $bar['site_name']."\n";

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.0110.00616.38
8.3.50.0110.01022.10
8.3.40.0110.01118.88
8.3.30.0130.00619.00
8.3.20.0080.00020.20
8.3.10.0080.00022.11
8.3.00.0000.00822.34
8.2.180.0090.00616.50
8.2.170.0140.00322.96
8.2.160.0060.01221.07
8.2.150.0040.00424.18
8.2.140.0120.00624.66
8.2.130.0000.00826.16
8.2.120.0080.00017.63
8.2.110.0060.00622.29
8.2.100.0060.00619.57
8.2.90.0040.00419.30
8.2.80.0080.00018.04
8.2.70.0000.00817.50
8.2.60.0040.00417.93
8.2.50.0040.00418.07
8.2.40.0070.00418.28
8.2.30.0070.00018.05
8.2.20.0080.00017.85
8.2.10.0080.00019.50
8.2.00.0040.00417.86
8.1.280.0170.00325.92
8.1.270.0040.00422.02
8.1.260.0050.00326.35
8.1.250.0050.00328.09
8.1.240.0000.00923.95
8.1.230.0000.01019.16
8.1.220.0040.00417.76
8.1.210.0090.00018.77
8.1.200.0060.00317.35
8.1.190.0000.00817.18
8.1.180.0040.00418.74
8.1.170.0030.00618.64
8.1.160.0040.00422.14
8.1.150.0050.00218.77
8.1.140.0050.00317.38
8.1.130.0030.00317.75
8.1.120.0000.00717.47
8.1.110.0000.01017.53
8.1.100.0030.00517.43
8.1.90.0050.00217.41
8.1.80.0000.00717.38
8.1.70.0070.00017.41
8.1.60.0030.00617.60
8.1.50.0030.00517.51
8.1.40.0040.00417.50
8.1.30.0000.00717.69
8.1.20.0040.00417.52
8.1.10.0000.00717.51
8.1.00.0030.00617.56
8.0.300.0000.00818.77
8.0.290.0020.00517.18
8.0.280.0030.00318.43
8.0.270.0070.00017.26
8.0.260.0030.00316.88
8.0.250.0030.00317.09
8.0.240.0040.00416.91
8.0.230.0030.00517.01
8.0.220.0000.00716.97
8.0.210.0000.00716.89
8.0.200.0000.00717.01
8.0.190.0040.00417.07
8.0.180.0040.00416.99
8.0.170.0070.00016.93
8.0.160.0040.00416.96
8.0.150.0040.00416.89
8.0.140.0080.00016.96
8.0.130.0000.00613.37
8.0.120.0000.00816.84
8.0.110.0000.00716.78
8.0.100.0000.00716.95
8.0.90.0040.00417.02
8.0.80.0210.00016.96
8.0.70.0050.00217.00
8.0.60.0000.00717.00
8.0.50.0020.00517.00
8.0.30.0120.00616.96
8.0.20.0110.00617.40
8.0.10.0040.00417.05
8.0.00.0100.00916.93
7.4.330.0000.00515.09
7.4.320.0060.00016.58
7.4.300.0030.00316.65
7.4.290.0000.00716.52
7.4.280.0080.00016.64
7.4.270.0030.00316.49
7.4.260.0030.00316.59
7.4.250.0060.00316.61
7.4.240.0040.00416.47
7.4.230.0040.00416.41
7.4.220.0070.01116.50
7.4.210.0090.00516.54
7.4.200.0030.00316.69
7.4.190.0000.00716.38
7.4.160.0030.01316.43
7.4.150.0080.00817.40
7.4.140.0070.01117.86
7.4.130.0050.01516.47
7.4.120.0080.00916.55
7.4.110.0110.01116.60
7.4.100.0060.01416.56
7.4.90.0100.00716.44
7.4.80.0130.00619.39
7.4.70.0040.01816.55
7.4.60.0070.01016.44
7.4.50.0050.00516.28
7.4.40.0040.00822.77
7.4.30.0040.01416.55
7.4.00.0070.01115.04
7.3.330.0000.00613.44
7.3.320.0000.00513.36
7.3.310.0030.00316.23
7.3.300.0000.00716.21
7.3.290.0070.00716.32
7.3.280.0110.00616.32
7.3.270.0160.00017.40
7.3.260.0120.01516.54
7.3.250.0120.00616.40
7.3.240.0070.01516.37
7.3.230.0080.01116.40
7.3.210.0060.01216.39
7.3.200.0130.00319.39
7.3.190.0110.00616.40
7.3.180.0110.00716.22
7.3.170.0030.01216.38
7.3.160.0110.00516.38
7.3.120.0050.00814.78
7.3.110.0040.01414.86
7.3.100.0040.00714.72
7.3.90.0100.00315.12
7.3.80.0040.01114.57
7.3.70.0100.00714.73
7.3.60.0080.00514.70
7.3.50.0090.00614.80
7.3.40.0100.00614.70
7.3.30.0110.00314.80
7.3.20.0130.00016.77
7.3.10.0030.01016.81
7.3.00.0000.01116.70
7.2.330.0090.01216.79
7.2.320.0030.01316.68
7.2.310.0140.00316.88
7.2.300.0060.01316.50
7.2.290.0060.01016.47
7.2.250.0030.01515.27
7.2.240.0100.01015.18
7.2.230.0040.01414.83
7.2.220.0000.01615.16
7.2.210.0100.00315.13
7.2.200.0090.00614.90
7.2.190.0130.00314.87
7.2.180.0090.00614.99
7.2.170.0000.01915.19
7.2.00.0120.00619.13
7.1.330.0060.00615.77
7.1.320.0040.01215.68
7.1.310.0050.00515.93
7.1.300.0000.01115.61
7.1.290.0110.00715.81
7.1.280.0040.01015.63
7.1.270.0080.00415.70
7.1.260.0110.00615.93
7.1.100.0070.00718.20
7.1.70.0000.01517.34
7.1.60.0060.01919.82
7.1.50.0070.01416.71
7.1.00.0000.07022.36
7.0.200.0030.01316.82
7.0.140.0070.07021.96
7.0.60.0100.07021.69
7.0.50.0070.04017.97
7.0.40.0070.08720.07
7.0.30.0300.07320.06
7.0.20.0300.04020.10
7.0.10.0100.04020.30
7.0.00.0070.06320.23
5.6.280.0000.07721.04
5.6.210.0070.03720.67
5.6.200.0300.04018.14
5.6.190.0170.07720.46
5.6.180.0530.07020.43
5.6.170.0270.08320.54
5.6.160.0000.04320.71
5.6.150.0070.08018.14
5.6.140.0070.03718.28
5.6.130.0170.07718.18
5.6.120.0000.04721.02
5.6.110.0100.06720.99
5.6.100.0170.04321.00
5.6.90.0070.06321.14
5.6.80.0070.08320.29
5.5.350.0070.07320.44
5.5.340.0100.08017.95
5.5.330.0070.08020.40
5.5.320.0430.06720.35
5.5.310.0270.08320.28
5.5.300.0030.06017.94
5.5.290.0030.05317.96
5.5.280.0100.08320.76
5.5.270.0070.08320.83
5.5.260.0170.07320.77
5.5.250.0070.04720.66
5.5.240.0100.06720.15
5.4.450.0270.07719.47
5.4.440.0230.03719.41
5.4.430.0170.06319.43
5.4.420.0200.07319.64
5.4.410.0170.06319.39
5.4.400.0230.04019.20
5.4.390.0030.03718.89
5.4.380.0530.02719.17
5.4.370.0430.06318.84
5.4.360.0170.03719.14
5.4.350.0570.04019.00
5.4.340.0300.06319.19
5.4.320.0370.05019.00
5.4.310.0270.06719.19
5.4.300.0270.07018.99
5.4.290.0600.05719.16
5.4.280.0500.05019.14
5.4.270.3600.03019.21
5.4.260.0070.06019.01
5.4.250.0100.07318.96
5.4.240.0000.07319.10
5.4.230.0070.08019.01
5.4.220.0170.04718.66
5.4.210.0230.05318.99
5.4.200.0100.07319.00
5.4.190.0270.04718.74
5.4.180.0130.07018.89
5.4.170.0130.07318.74
5.4.160.0170.05318.89
5.4.150.0100.07718.92
5.4.140.0100.05316.35
5.4.130.0170.04016.37
5.4.120.0000.06716.37
5.4.110.0130.04716.53
5.4.100.0070.05016.49
5.4.90.0130.04716.49
5.4.80.0030.07316.40
5.4.70.0030.05316.37
5.4.60.0100.04716.40
5.4.50.0130.04716.39
5.4.40.0100.04716.51
5.4.30.0100.05316.46
5.4.20.0070.07316.48
5.4.10.0130.07016.46
5.4.00.0100.07015.97
5.3.290.4030.04014.57
5.3.280.0070.05314.59
5.3.270.0100.06014.61
5.3.260.0130.07014.68
5.3.250.0130.07014.77
5.3.240.0130.05314.57
5.3.230.0000.05714.78
5.3.220.0130.06014.63
5.3.210.0030.06014.63
5.3.200.0070.04714.79
5.3.190.0070.05014.62
5.3.180.0030.07714.40
5.3.170.0070.07714.64
5.3.160.0070.05014.39
5.3.150.0170.05714.58
5.3.140.0170.04314.46
5.3.130.0030.06014.57
5.3.120.0100.07714.68
5.3.110.0130.06014.63
5.3.100.0100.05313.94
5.3.90.0130.06314.10
5.3.80.0130.04714.09
5.3.70.0100.05013.98
5.3.60.0130.05314.09
5.3.50.0130.06313.78
5.3.40.0070.06714.02
5.3.30.0030.06013.98
5.3.20.0070.06713.76
5.3.10.0200.03313.66
5.3.00.0000.06013.81

preferences:
41.45 ms | 400 KiB | 5 Q