3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace Generic\Space { function bar() { echo "bar over here!"; } } namespace Some\Other { class Foo { use \My\TraitSpace\NiceTrait; function baz() { $this->bar = function() {echo 'im a callable bar';}; } } } namespace My\TraitSpace { use \Generic\Space; trait NiceTrait { } } namespace { $foo = new Some\Other\Foo(); $foo->baz(); $foo->bar(); }

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.0070.01018.43
8.3.50.0250.00921.95
8.3.40.0040.01118.82
8.3.30.0000.01419.04
8.3.20.0000.00820.25
8.3.10.0050.00323.66
8.3.00.0060.00320.70
8.2.180.0160.00616.63
8.2.170.0060.00922.96
8.2.160.0200.00020.22
8.2.150.0030.00524.18
8.2.140.0000.00824.66
8.2.130.0030.01026.16
8.2.120.0050.00319.36
8.2.110.0000.01022.07
8.2.100.0050.01020.41
8.2.90.0000.00719.23
8.2.80.0040.00417.97
8.2.70.0040.00417.75
8.2.60.0040.00418.04
8.2.50.0090.00018.07
8.2.40.0000.00819.94
8.2.30.0070.00018.28
8.2.20.0050.00317.73
8.2.10.0040.00418.07
8.2.00.0000.00817.83
8.1.280.0110.00325.92
8.1.270.0000.00822.00
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0040.00421.93
8.1.230.0040.00919.10
8.1.220.0000.00817.74
8.1.210.0050.00318.77
8.1.200.0060.00317.35
8.1.190.0000.00817.13
8.1.180.0080.00418.10
8.1.170.0060.00318.51
8.1.160.0040.00422.09
8.1.150.0030.00518.57
8.1.140.0070.00017.39
8.1.130.0030.00317.83
8.1.120.0030.00517.48
8.1.110.0040.00417.44
8.1.100.0000.00717.41
8.1.90.0000.00717.52
8.1.80.0000.00717.36
8.1.70.0000.00717.35
8.1.60.0040.00417.63
8.1.50.0040.00417.52
8.1.40.0060.00317.39
8.1.30.0030.00617.64
8.1.20.0000.00817.60
8.1.10.0000.00717.61
8.1.00.0000.00717.38
8.0.300.0040.00418.77
8.0.290.0070.00016.58
8.0.280.0000.00718.51
8.0.270.0000.00817.16
8.0.260.0030.00317.17
8.0.250.0000.00717.03
8.0.240.0050.00316.93
8.0.230.0070.00016.94
8.0.220.0030.00316.96
8.0.210.0000.00717.00
8.0.200.0000.00717.03
8.0.190.0000.00816.91
8.0.180.0000.01017.04
8.0.170.0060.00316.95
8.0.160.0040.00416.95
8.0.150.0050.00216.92
8.0.140.0060.00316.85
8.0.130.0030.00313.45
8.0.120.0060.00316.89
8.0.110.0040.00416.98
8.0.100.0040.00417.01
8.0.90.0030.00517.07
8.0.80.0060.00916.97
8.0.70.0040.00417.02
8.0.60.0040.00417.00
8.0.50.0000.00717.00
8.0.30.0140.00516.90
8.0.20.0140.00717.44
8.0.10.0050.00216.96
8.0.00.0140.00616.89
7.4.330.0030.00315.02
7.4.320.0050.00316.65
7.4.300.0000.00616.49
7.4.290.0070.00016.59
7.4.280.0080.00016.64
7.4.270.0030.00316.50
7.4.260.0060.00316.45
7.4.250.0070.00016.46
7.4.240.0050.00216.47
7.4.230.0000.00716.61
7.4.220.0100.00716.50
7.4.210.0040.01116.63
7.4.200.0040.00416.54
7.4.160.0120.00316.62
7.4.150.0090.00817.40
7.4.140.0080.01117.86
7.4.130.0070.01116.62
7.4.120.0060.01116.54
7.4.110.0150.00816.54
7.4.100.0100.00716.54
7.4.90.0070.01016.51
7.4.80.0080.00819.39
7.4.70.0030.01416.44
7.4.60.0100.01016.61
7.4.50.0080.00016.60
7.4.40.0060.00916.46
7.4.30.0120.00616.73
7.4.00.0120.00615.07
7.3.330.0050.00013.37
7.3.320.0050.00013.34
7.3.310.0030.00316.37
7.3.300.0030.00316.22
7.3.290.0140.00316.43
7.3.280.0100.00816.39
7.3.270.0060.01317.40
7.3.260.0070.01016.46
7.3.250.0080.01016.49
7.3.240.0070.01016.48
7.3.230.0060.00916.42
7.3.210.0120.00916.53
7.3.200.0070.01019.39
7.3.190.0130.00616.32
7.3.180.0090.00916.61
7.3.170.0120.00416.41
7.3.160.0090.00616.50
7.3.120.0080.00414.86
7.2.330.0040.01416.40
7.2.320.0000.01716.61
7.2.310.0060.00916.41
7.2.300.0100.01016.76
7.2.290.0060.01216.50
7.2.110.0150.00616.57
7.2.60.0060.00616.93
7.2.00.0090.00619.51
7.1.200.0030.00915.79
7.1.70.0040.00417.14
7.1.60.0060.00617.02
7.1.50.0040.01816.89
7.1.00.0030.07322.51
7.0.200.0060.00316.80
7.0.140.0000.07321.97
7.0.60.0070.04320.04
7.0.50.0030.04717.89
7.0.40.0070.07020.25
7.0.30.0270.07320.23
7.0.20.0100.05720.21
7.0.10.0370.07020.33
7.0.00.0070.04020.41
5.6.280.0030.07320.90
5.6.210.0130.07720.65
5.6.200.0070.03718.18
5.6.190.0030.07020.49
5.6.180.0000.08720.41
5.6.170.0200.04020.63
5.6.160.0100.08020.50
5.6.150.0130.07018.29
5.6.140.0100.04018.11
5.6.130.0000.09318.19
5.6.120.0100.05721.00
5.6.110.0000.04321.13
5.6.100.0200.07021.13
5.6.90.0030.08721.00
5.6.80.0170.07320.52
5.6.70.0300.06720.41
5.5.350.0100.07320.43
5.5.340.0170.07018.08
5.5.330.0030.08320.40
5.5.320.0000.09320.21
5.5.310.0270.06020.36
5.5.300.0100.07018.09
5.5.290.0070.04017.97
5.5.280.0130.04720.87
5.5.270.0030.07020.77
5.5.260.0030.05720.77
5.5.250.0030.06320.70
5.5.240.0030.05720.24
5.4.450.0370.05719.29
5.4.440.0200.04340.20
5.4.430.0230.04335.93
5.4.420.0270.04335.93
5.4.410.0200.04035.93
5.4.400.0130.04335.89
5.4.390.0430.04735.74
5.4.380.0230.05018.54
5.4.370.0130.05318.75
5.4.360.0000.07018.55
5.4.350.0130.05318.61
5.4.340.0230.04718.58
5.4.320.0100.03412.51
5.4.310.0080.04112.51
5.4.300.0080.03412.51
5.4.290.0070.04112.50
5.4.280.0070.03512.40
5.4.270.0050.04912.40
5.4.260.0070.03712.40
5.4.250.0030.04112.40
5.4.240.0100.03212.40
5.4.230.0040.04412.39
5.4.220.0060.04212.39
5.4.210.0070.03512.39
5.4.200.0040.04012.40
5.4.190.0100.03212.39
5.4.180.0080.03412.39
5.4.170.0060.03612.40
5.4.160.0050.03912.39
5.4.150.0090.03412.39
5.4.140.0060.03712.07
5.4.130.0060.03712.06
5.4.120.0100.03212.02
5.4.110.0060.03612.02
5.4.100.0080.03512.02
5.4.90.0040.04012.02
5.4.80.0080.03512.02
5.4.70.0100.03812.02
5.4.60.0030.03612.01
5.4.50.0090.03412.02
5.4.40.0100.03212.00
5.4.30.0100.03612.00
5.4.20.0080.03612.00
5.4.10.0050.04012.00
5.4.00.0090.03211.49
5.3.290.0090.04812.80
5.3.280.0050.04112.71
5.3.270.0110.03312.72
5.3.260.0070.03612.72
5.3.250.0050.04612.72
5.3.240.0070.04012.72
5.3.230.0080.03712.70
5.3.220.0100.03512.68
5.3.210.0080.03812.68
5.3.200.0040.03912.68
5.3.190.0080.03912.68
5.3.180.0080.03612.67
5.3.170.0030.04012.67
5.3.160.0050.04112.67
5.3.150.0080.03612.68
5.3.140.0050.03812.66
5.3.130.0070.03812.66
5.3.120.0030.04112.66
5.3.110.0050.04112.66
5.3.100.0080.04112.12
5.3.90.0050.04212.11
5.3.80.0090.03712.09
5.3.70.0030.04012.09
5.3.60.0040.03812.08
5.3.50.0060.03612.02
5.3.40.0050.03712.02
5.3.30.0090.03111.98
5.3.20.0070.03411.76
5.3.10.0050.03611.73
5.3.00.0070.03511.71
5.2.170.0070.0299.18
5.2.160.0080.0269.18
5.2.150.0050.0309.18
5.2.140.0030.0329.18
5.2.130.0050.0289.14
5.2.120.0070.0269.14
5.2.110.0030.0319.15
5.2.100.0050.0289.14
5.2.90.0040.0299.14
5.2.80.0060.0289.14
5.2.70.0060.0299.14
5.2.60.0080.0329.09
5.2.50.0050.0309.06
5.2.40.0070.0279.03
5.2.30.0020.0329.02
5.2.20.0050.0299.00
5.2.10.0070.0268.93
5.2.00.0060.0338.79
5.1.60.0070.0288.06
5.1.50.0040.0288.06
5.1.40.0030.0258.05
5.1.30.0060.0258.40
5.1.20.0080.0238.42
5.1.10.0040.0288.14
5.1.00.0060.0258.14
5.0.50.0020.0226.63
5.0.40.0050.0196.48
5.0.30.0040.0326.29
5.0.20.0030.0206.27
5.0.10.0040.0196.24
5.0.00.0030.0316.23
4.4.90.0020.0164.78
4.4.80.0030.0174.75
4.4.70.0000.0214.75
4.4.60.0020.0164.76
4.4.50.0030.0154.77
4.4.40.0040.0234.71
4.4.30.0000.0184.76
4.4.20.0030.0164.84
4.4.10.0050.0134.85
4.4.00.0040.0234.76
4.3.110.0020.0164.67
4.3.100.0020.0174.67
4.3.90.0050.0144.63
4.3.80.0030.0294.59
4.3.70.0040.0224.63
4.3.60.0030.0154.62
4.3.50.0030.0154.62
4.3.40.0010.0264.54
4.3.30.0020.0163.29
4.3.20.0010.0183.26
4.3.10.0030.0153.22
4.3.00.0000.01335.40

preferences:
40.6 ms | 401 KiB | 5 Q