3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait ClosureInATrait { public static function getClosureInTrait() { return __CLASS__; } } class ClassConstantTest { use ClosureInATrait; } var_dump(ClassConstantTest::getClosureInTrait());

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.0120.00316.75
8.3.50.0100.00921.98
8.3.40.0140.00018.57
8.3.30.0030.01219.14
8.3.20.0030.00619.98
8.3.10.0040.00423.66
8.3.00.0080.00020.92
8.2.180.0070.00716.32
8.2.170.0090.00622.96
8.2.160.0070.00720.39
8.2.150.0070.00024.18
8.2.140.0070.00024.66
8.2.130.0040.00426.16
8.2.120.0040.00420.64
8.2.110.0050.00522.12
8.2.100.0070.00320.55
8.2.90.0040.00419.23
8.2.80.0090.00017.97
8.2.70.0000.00817.48
8.2.60.0000.00817.93
8.2.50.0040.00418.07
8.2.40.0040.00419.82
8.2.30.0040.00418.25
8.2.20.0000.00817.64
8.2.10.0070.00018.00
8.2.00.0070.00017.50
8.1.280.0200.00025.92
8.1.270.0040.00423.96
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0090.00021.96
8.1.230.0040.00819.16
8.1.220.0040.00417.74
8.1.210.0040.00418.77
8.1.200.0060.00317.35
8.1.190.0050.00317.10
8.1.180.0030.00618.10
8.1.170.0040.00418.54
8.1.160.0070.00022.00
8.1.150.0000.00718.57
8.1.140.0000.00817.43
8.1.130.0070.00017.63
8.1.120.0120.00017.39
8.1.110.0000.00717.28
8.1.100.0000.00717.41
8.1.90.0040.00417.39
8.1.80.0040.00417.43
8.1.70.0080.00017.30
8.1.60.0090.00317.49
8.1.50.0050.00317.39
8.1.40.0080.00017.34
8.1.30.0050.00317.57
8.1.20.0030.00617.57
8.1.10.0000.00817.39
8.1.00.0040.00417.46
8.0.300.0000.00818.77
8.0.290.0040.00416.58
8.0.280.0000.00718.33
8.0.270.0080.00016.82
8.0.260.0060.00017.31
8.0.250.0000.00717.01
8.0.240.0040.00416.84
8.0.230.0030.00316.98
8.0.220.0000.00716.92
8.0.210.0000.00716.92
8.0.200.0030.00316.97
8.0.190.0000.00716.91
8.0.180.0000.00716.91
8.0.170.0040.00416.88
8.0.160.0000.00716.92
8.0.150.0030.00316.75
8.0.140.0040.00416.67
8.0.130.0060.00013.21
8.0.120.0030.00516.79
8.0.110.0000.00716.77
8.0.100.0050.00216.71
8.0.90.0050.00216.82
8.0.80.0040.01116.82
8.0.70.0040.00416.95
8.0.60.0000.00716.87
8.0.50.0000.00816.79
8.0.30.0100.00817.02
8.0.20.0080.01017.40
8.0.10.0070.00017.01
8.0.00.0140.00516.71
7.4.330.0050.00015.00
7.4.320.0030.00316.50
7.4.300.0070.00016.54
7.4.290.0000.00616.46
7.4.280.0030.00516.37
7.4.270.0030.00316.38
7.4.260.0000.00716.41
7.4.250.0040.00416.30
7.4.240.0050.00216.52
7.4.230.0030.00316.64
7.4.220.0200.00816.52
7.4.210.0160.00316.52
7.4.200.0050.00316.32
7.4.190.0000.00816.48
7.4.160.0160.00616.48
7.4.150.0130.00417.40
7.4.140.0110.00517.86
7.4.130.0100.00916.37
7.4.120.0100.00816.41
7.4.110.0130.01016.55
7.4.100.0130.00316.53
7.4.90.0030.01416.40
7.4.80.0130.01019.39
7.4.70.0040.01216.41
7.4.60.0090.00816.48
7.4.50.0040.00416.47
7.4.40.0030.01516.39
7.4.30.0030.01316.46
7.4.00.0100.00714.84
7.3.330.0040.00413.07
7.3.320.0000.00513.10
7.3.310.0000.00716.29
7.3.300.0050.00316.25
7.3.290.0100.00616.25
7.3.280.0110.00416.23
7.3.270.0030.01417.40
7.3.260.0040.01316.51
7.3.250.0100.00816.38
7.3.240.0070.01116.38
7.3.230.0120.00616.39
7.3.210.0270.01816.22
7.3.200.0120.00919.39
7.3.190.0030.01416.41
7.3.180.0040.01316.38
7.3.170.0150.00016.42
7.3.160.0030.01316.29
7.3.120.0070.00714.63
7.2.330.0120.00616.54
7.2.320.0090.00916.72
7.2.310.0080.01416.70
7.2.300.0080.00816.65
7.2.290.0030.01416.44
7.2.60.0100.00316.81
7.2.00.0060.00919.31
7.1.200.0080.00415.80
7.1.100.0040.01117.99
7.1.70.0000.00717.07
7.1.60.0130.00919.70
7.1.50.0000.01116.92
7.1.00.0030.07022.33
7.0.200.0050.00216.69
7.0.140.0100.06722.15
7.0.60.0100.06719.88
7.0.50.0070.04717.86
7.0.40.0030.07319.96
7.0.30.0130.04720.35
7.0.20.0430.07720.22
7.0.10.0070.09020.16
7.0.00.0100.06320.09
5.6.280.0130.06321.12
5.6.210.0070.07320.54
5.6.200.0070.06018.20
5.6.190.0030.04720.77
5.6.180.0400.07320.39
5.6.170.0230.08720.50
5.6.160.0200.07020.51
5.6.150.0030.04018.19
5.6.140.0030.08718.28
5.6.130.0130.08018.14
5.6.120.0030.04321.12
5.6.110.0030.06321.14
5.6.100.0070.07721.01
5.6.90.0130.06021.10
5.6.80.0030.06720.39
5.5.350.0130.07320.45
5.5.340.0000.04018.05
5.5.330.0130.08020.35
5.5.320.0370.03720.20
5.5.310.0300.06720.24
5.5.300.0070.04018.00
5.5.290.0070.05018.04
5.5.280.0030.04020.80
5.5.270.0130.08020.86
5.5.260.0100.07720.76
5.5.250.0130.06720.69
5.5.240.0100.07320.37
5.4.450.0230.05019.21
5.4.440.0200.04719.41
5.4.430.0370.03719.63
5.4.420.0200.03319.65
5.4.410.0230.04719.26
5.4.400.0230.04719.23
5.4.390.0270.04719.27
5.4.380.0130.05718.56
5.4.370.0100.05718.68
5.4.360.0200.07018.58
5.4.350.0070.06018.69
5.4.340.0200.04718.59
5.4.320.0120.06712.50
5.4.310.0060.04112.50
5.4.300.0080.04112.50
5.4.290.0070.03712.50
5.4.280.0060.03712.39
5.4.270.0080.03512.39
5.4.260.0070.03712.39
5.4.250.0040.04212.39
5.4.240.0060.03812.40
5.4.230.0100.03512.39
5.4.220.0080.03512.39
5.4.210.0070.03512.38
5.4.200.0110.04212.39
5.4.190.0100.03412.38
5.4.180.0060.03712.38
5.4.170.0090.03512.39
5.4.160.0100.03312.39
5.4.150.0040.03812.39
5.4.140.0110.05812.07
5.4.130.0080.03812.05
5.4.120.0090.03212.02
5.4.110.0040.03812.01
5.4.100.0060.03612.01
5.4.90.0050.03712.01
5.4.80.0060.03612.01
5.4.70.0070.03512.01
5.4.60.0060.03512.01
5.4.50.0060.03612.01
5.4.40.0070.03512.00
5.4.30.0080.04111.99
5.4.20.0070.04011.99
5.4.10.0070.03511.99
5.4.00.0050.03911.48
5.3.290.0050.04412.80
5.3.280.0100.03612.71
5.3.270.0080.04512.73
5.3.260.0050.04512.72
5.3.250.0090.03812.72
5.3.240.0110.03412.71
5.3.230.0070.03812.71
5.3.220.0090.04012.68
5.3.210.0100.03812.68
5.3.200.0070.03612.68
5.3.190.0050.03912.68
5.3.180.0100.03312.67
5.3.170.0030.04012.67
5.3.160.0090.03412.67
5.3.150.0090.03512.68
5.3.140.0040.03912.66
5.3.130.0070.03812.66
5.3.120.0090.03712.66
5.3.110.0110.03712.66
5.3.100.0040.04312.12
5.3.90.0110.03412.09
5.3.80.0090.03312.07
5.3.70.0060.03812.08
5.3.60.0050.04212.07
5.3.50.0080.03312.00
5.3.40.0080.03912.00
5.3.30.0060.04311.95
5.3.20.0060.03611.73
5.3.10.0050.03611.70
5.3.00.0080.03311.68
5.2.170.0040.0329.18
5.2.160.0060.0299.18
5.2.150.0050.0309.18
5.2.140.0030.0319.18
5.2.130.0070.0279.14
5.2.120.0110.0229.14
5.2.110.0030.0319.14
5.2.100.0070.0269.14
5.2.90.0050.0299.14
5.2.80.0040.0309.14
5.2.70.0040.0319.14
5.2.60.0050.0319.09
5.2.50.0030.0359.06
5.2.40.0050.0329.03
5.2.30.0030.0309.01
5.2.20.0030.0309.00
5.2.10.0060.0268.92
5.2.00.0050.0288.78
5.1.60.0060.0268.07
5.1.50.0090.0238.06
5.1.40.0020.0268.04
5.1.30.0020.0288.39
5.1.20.0080.0358.42
5.1.10.0070.0298.14
5.1.00.0050.0268.14
5.0.50.0050.0196.62
5.0.40.0040.0226.48
5.0.30.0040.0316.29
5.0.20.0030.0196.27
5.0.10.0050.0186.24
5.0.00.0070.0316.23
4.4.90.0020.0164.78
4.4.80.0030.0154.75
4.4.70.0020.0164.76
4.4.60.0040.0144.75
4.4.50.0020.0164.77
4.4.40.0030.0284.71
4.4.30.0030.0204.75
4.4.20.0020.0214.84
4.4.10.0060.0204.85
4.4.00.0010.0364.76
4.3.110.0040.0224.67
4.3.100.0030.0224.66
4.3.90.0040.0224.63
4.3.80.0060.0254.58
4.3.70.0040.0214.63
4.3.60.0030.0184.62
4.3.50.0050.0134.63
4.3.40.0020.0314.54
4.3.30.0010.0193.29
4.3.20.0020.0153.26
4.3.10.0020.0153.22
4.3.00.0030.01716.92

preferences:
47.16 ms | 401 KiB | 5 Q