3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = function($b) { print "$b\n"; }; $a('lulz'); $b['lulz'] = $a; $b['lulz']('more lulz'); class Lulz { public $do; function __construct(callable $callable) { $this->do = $callable; } public function do() { print "hope"; } } $d = new Lulz($a); $d->do('nope'); call_user_func_array(array($d, 'do'), array('nope')); $c = new stdclass(); $c->do = $a; $c->do('nope'); call_user_func_array(array($c, 'do'), array('nope'));

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.0070.01118.68
8.3.60.0120.00318.38
8.3.50.0070.01121.21
8.3.40.0070.00718.82
8.3.30.0120.00319.04
8.3.20.0120.00320.16
8.3.10.0040.00422.10
8.3.00.0120.00620.44
8.2.180.0120.00316.49
8.2.170.0100.00722.96
8.2.160.0070.00720.43
8.2.150.0030.00624.18
8.2.140.0120.00324.66
8.2.130.0070.01126.16
8.2.120.0040.00419.79
8.2.110.0090.00022.26
8.2.100.0000.01219.25
8.2.90.0000.00819.24
8.2.80.0000.00818.16
8.2.70.0030.00617.63
8.2.60.0060.00318.05
8.2.50.0090.00018.07
8.2.40.0040.00418.34
8.2.30.0070.00018.10
8.2.20.0050.00317.89
8.2.10.0070.00017.90
8.2.00.0040.00417.71
8.1.280.0160.00625.92
8.1.270.0060.00320.31
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0090.00023.82
8.1.230.0070.00419.16
8.1.220.0000.00817.79
8.1.210.0050.00318.77
8.1.200.0100.00017.48
8.1.190.0050.00317.51
8.1.180.0000.00818.73
8.1.170.0000.00818.51
8.1.160.0000.00822.16
8.1.150.0070.00018.79
8.1.140.0070.00017.46
8.1.130.0000.00717.81
8.1.120.0080.00017.36
8.1.110.0040.00417.54
8.1.100.0050.00317.46
8.1.90.0050.00317.40
8.1.80.0050.00317.57
8.1.70.0040.00417.46
8.1.60.0100.00317.62
8.1.50.0050.00317.55
8.1.40.0000.00817.46
8.1.30.0070.00017.64
8.1.20.0000.00817.58
8.1.10.0030.00517.62
8.1.00.0030.00517.41
8.0.300.0030.00418.77
8.0.290.0040.00417.18
8.0.280.0070.00018.53
8.0.270.0000.00717.28
8.0.260.0060.00018.59
8.0.250.0030.00317.09
8.0.240.0040.00416.94
8.0.230.0030.00316.91
8.0.220.0070.00017.00
8.0.210.0000.00816.85
8.0.200.0000.00717.06
8.0.190.0000.00716.96
8.0.180.0050.00316.89
8.0.170.0000.00817.06
8.0.160.0040.00416.91
8.0.150.0000.00716.94
8.0.140.0000.00816.87
8.0.130.0050.00013.41
8.0.120.0000.00816.94
8.0.110.0030.00516.94
8.0.100.0040.00416.96
8.0.90.0020.00516.81
8.0.80.0060.01316.96
8.0.70.0040.00416.84
8.0.60.0000.00716.91
8.0.50.0000.00816.98
8.0.30.0140.00517.13
8.0.20.0150.00617.40
8.0.10.0040.00416.99
8.0.00.0070.01116.90
7.4.330.0060.00015.00
7.4.320.0060.00016.51
7.4.300.0030.00316.60
7.4.290.0000.00816.54
7.4.280.0000.00716.65
7.4.270.0030.00316.55
7.4.260.0030.00316.59
7.4.250.0070.00016.58
7.4.240.0020.00516.47
7.4.230.0000.00716.57
7.4.220.0050.01116.65
7.4.210.0060.00816.61
7.4.200.0050.00216.51
7.4.190.0070.00016.43
7.4.160.0030.01416.61
7.4.150.0070.01017.40
7.4.140.0120.00817.86
7.4.130.0070.01116.58
7.4.120.0110.00616.65
7.4.110.0120.00916.56
7.4.100.0090.01216.51
7.4.90.0040.01816.57
7.4.80.0130.00519.39
7.4.70.0190.00316.65
7.4.60.0060.00916.54
7.4.50.0040.00416.61
7.4.40.0070.01022.77
7.4.30.0040.01116.66
7.4.00.0110.00714.84
7.3.330.0030.00313.38
7.3.320.0000.00513.46
7.3.310.0030.00316.41
7.3.300.0030.00316.46
7.3.290.0110.00716.45
7.3.280.0070.00816.49
7.3.270.0090.00917.40
7.3.260.0150.00316.62
7.3.250.0070.01216.49
7.3.240.0190.00016.44
7.3.230.0090.01016.50
7.3.210.0100.01316.53
7.3.200.0060.01219.39
7.3.190.0110.00616.55
7.3.180.0110.01116.60
7.3.170.0100.00716.35
7.3.160.0070.01016.43
7.3.120.0040.00414.98
7.2.330.0170.01016.66
7.2.320.0000.01716.84
7.2.310.0100.00716.80
7.2.300.0150.00716.87
7.2.290.0070.01016.77
7.2.60.0070.00717.04
7.2.00.0000.01219.23
7.1.200.0080.00015.99
7.1.100.0040.00417.89
7.1.70.0100.00017.20
7.1.60.0060.01519.82
7.1.50.0130.00717.03
7.1.00.0030.04722.37
7.0.200.0650.01014.27
7.0.140.0030.07322.00
7.0.60.0000.04719.87
7.0.50.0030.08017.98
7.0.40.0100.04320.18
7.0.30.0230.05020.36
7.0.20.0270.08020.08
7.0.10.0170.08020.06
7.0.00.0100.08020.09
5.6.280.0100.06721.05
5.6.210.0070.08020.72
5.6.200.0100.06318.18
5.6.190.0000.06720.56
5.6.180.0300.07720.33
5.6.170.0230.07720.44
5.6.160.0070.09020.57
5.6.150.0170.07018.27
5.6.140.0130.07318.29
5.6.130.0200.07318.16
5.6.120.0100.04020.93
5.6.110.0070.08320.98
5.6.100.0070.07721.09
5.6.90.0100.07321.01
5.6.80.0100.07320.38
5.5.350.0000.08320.44
5.5.340.0070.07718.01
5.5.330.0030.09320.42
5.5.320.0500.07320.31
5.5.310.0300.07320.34
5.5.300.0070.08318.07
5.5.290.0030.04018.07
5.5.280.0000.04720.89
5.5.270.0000.05020.96
5.5.260.0030.06320.64
5.5.250.0000.08720.58
5.5.240.0070.07020.15
5.4.450.0330.07019.59
5.4.440.0300.06719.59
5.4.430.0430.06019.16
5.4.420.0100.06019.58
5.4.410.0200.07719.50
5.4.400.0500.06318.63
5.4.390.0530.06018.57
5.4.380.0200.05718.54
5.4.370.0200.04318.81
5.4.360.0170.04718.51
5.4.350.0080.04512.03
5.4.340.0210.06012.03
5.4.320.0050.04812.52
5.4.310.0060.03812.52
5.4.300.0070.03912.52
5.4.290.0070.04812.52
5.4.280.0070.03512.41
5.4.270.0060.04112.41
5.4.260.0110.04912.41
5.4.250.0130.04319.00
5.4.240.0070.05718.80
5.4.230.0070.05018.96
5.4.220.0130.04718.78
5.4.210.0070.05318.97
5.4.200.0070.05318.95
5.4.190.0000.06018.98
5.4.180.0070.06018.80
5.4.170.0130.05018.98
5.4.160.0100.06318.93
5.4.150.0100.05018.64
5.4.140.0030.06016.45
5.4.130.0030.05016.48
5.4.120.0130.04716.48
5.4.110.0070.05016.53
5.4.100.0070.05016.68
5.4.90.0070.04716.57
5.4.80.0170.03716.40
5.4.70.0100.04316.70
5.4.60.0100.04316.60
5.4.50.0130.04316.36
5.4.40.0100.04316.44
5.4.30.0130.05716.62
5.4.20.0070.04716.38
5.4.10.0000.05316.54
5.4.00.0030.05015.84
5.3.290.0090.04212.80
5.3.280.0070.06714.66
5.3.270.0070.05714.79
5.3.260.0100.07014.69
5.3.250.0030.05714.77
5.3.240.0070.05014.70
5.3.230.0070.05014.68
5.3.220.0030.05314.73
5.3.210.0130.05014.66
5.3.200.0030.05014.75
5.3.190.0100.05314.40
5.3.180.0000.05714.65
5.3.170.0070.07014.75
5.3.160.0070.05014.64
5.3.150.0100.04314.53
5.3.140.0030.05014.64
5.3.130.0070.07314.45
5.3.120.0170.04014.64
5.3.110.0100.05014.60
5.3.100.0030.05014.22
5.3.90.0030.05013.99
5.3.80.0030.05314.18
5.3.70.0170.04013.99
5.3.60.0130.04014.16
5.3.50.0070.04714.17
5.3.40.0030.05313.79
5.3.30.0030.05013.93
5.3.20.0130.05313.72
5.3.10.0100.05313.57
5.3.00.0070.05013.66
5.2.170.0070.04011.13
5.2.160.0030.04011.16
5.2.150.0100.04011.16
5.2.140.0130.03311.02
5.2.130.0130.03011.10
5.2.120.0000.04311.25
5.2.110.0070.03711.11
5.2.100.0030.05311.00
5.2.90.0000.05711.09
5.2.80.0070.03711.09
5.2.70.0030.04011.09
5.2.60.0000.04311.04
5.2.50.0070.03711.03
5.2.40.0030.04010.99
5.2.30.0030.04011.08
5.2.20.0070.04710.88
5.2.10.0100.03010.94
5.2.00.0030.04010.78
5.1.60.0030.0339.93
5.1.50.0030.03310.14
5.1.40.0030.0479.91
5.1.30.0000.04010.41
5.1.20.0070.03310.43
5.1.10.0030.04010.21
5.1.00.0030.03710.13
5.0.50.0030.0309.09
5.0.40.0000.0309.09
5.0.30.0030.0409.09
5.0.20.0070.0239.09
5.0.10.0030.0379.09
5.0.00.0100.0339.09
4.4.90.0000.0239.09
4.4.80.0000.0239.09
4.4.70.0070.0179.09
4.4.60.0070.0179.09
4.4.50.0030.0279.09
4.4.40.0000.0339.09
4.4.30.0000.0239.09
4.4.20.0000.0309.09
4.4.10.0000.0309.09
4.4.00.0030.0339.09
4.3.110.0000.0239.09
4.3.100.0070.0239.09
4.3.90.0000.0209.09
4.3.80.0030.0439.09
4.3.70.0030.0209.09
4.3.60.0030.0209.09
4.3.50.0030.0209.09
4.3.40.0030.0309.09
4.3.30.0000.0309.09
4.3.20.0030.0209.09
4.3.10.0030.0179.09
4.3.00.0030.0207.63

preferences:
51.55 ms | 401 KiB | 5 Q