3v4l.org

run code in 300+ PHP versions simultaneously
<?php function gen1() { return [4, 5, 6] } function gen2() { yield from gen1(); } $g = gen2(); foreach($g as $val) { var_dump($val); } var_dump($g->getReturn());

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)
5.6.140.0000.04718.28
5.6.130.0100.08318.27
5.6.120.0170.07721.00
5.6.110.0030.07021.13
5.6.100.0130.08321.05
5.6.90.0130.07720.98
5.6.80.0130.07320.48
5.5.300.0070.07018.01
5.5.290.0100.03717.94
5.5.280.0000.08720.88
5.5.270.0100.08020.75
5.5.260.0070.08720.79
5.5.250.0070.08020.68
5.5.240.0030.07020.16
5.4.450.0730.05319.55
5.4.440.0830.05019.55
5.4.430.0730.05319.58
5.4.420.0770.05019.30
5.4.410.0730.05319.45
5.4.400.0730.05019.29
5.4.390.0730.05318.83
5.4.380.0800.04719.29
5.4.370.0770.04718.87
5.4.360.0730.05719.15
5.4.350.0830.04318.84
5.4.340.0770.06319.29
5.4.320.0670.05719.15
5.4.310.0530.06319.26
5.4.300.0270.07018.97
5.4.290.0570.05319.22
5.4.280.0570.05719.15
5.4.270.0670.04719.37
5.4.260.0070.05319.15
5.4.250.0200.04019.14
5.4.240.0400.05318.97
5.4.230.0670.05719.30
5.4.220.0300.05319.14
5.4.210.0130.04718.85
5.4.200.0300.05719.14
5.4.190.0570.05718.83
5.4.180.0770.06019.02
5.4.170.0630.06019.16
5.4.160.0670.06019.27
5.4.150.0870.07319.14
5.4.140.0570.06316.73
5.4.130.0770.04016.50
5.4.120.0600.04716.41
5.4.110.0670.04716.57
5.4.100.0670.06016.43
5.4.90.0870.06016.45
5.4.80.0770.04716.61
5.4.70.0170.03316.57
5.4.60.0000.06016.43
5.4.50.0030.03716.16
5.4.40.0270.06716.55
5.4.30.0300.06716.54
5.4.20.0070.03716.39

preferences:
127.66 ms | 1398 KiB | 7 Q