3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace concrete5; interface AttributeInterface { /** * Attribute Handle */ public function renderedContent(); } /* ...... */ class MyCustomObject extends Model implements AttributeInterface { public function renderedContent() { return 'derp'; } } /* .... Register the attribute */ Attribute::registerAttribute('my_custom_attribute', function () { return new MyCustomObject; }); /* .... Show attribute */ class SomeRenderingClass { function renderAttribute(AttributeInterface $attribute) { return $attribute->renderedContent(); } function renderAttributes() { $attributes = Attribute::getAllAttributes(); $rendered = array(); foreach($attributes as $attribute) { $rendered[] = $this->renderAttribute($attribute); } } }

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.0040.01118.41
8.3.50.0100.01021.20
8.3.40.0040.01118.80
8.3.30.0090.00619.09
8.3.20.0140.00420.22
8.3.10.0000.00921.70
8.3.00.0040.00422.58
8.2.180.0060.01316.63
8.2.170.0030.01022.96
8.2.160.0000.01419.17
8.2.150.0050.00324.18
8.2.140.0100.00024.66
8.2.130.0040.00426.16
8.2.120.0000.00819.54
8.2.110.0070.00319.27
8.2.100.0120.00017.88
8.2.90.0050.00319.22
8.2.80.0040.00418.05
8.2.70.0030.00517.50
8.2.60.0100.00017.93
8.2.50.0050.00318.10
8.2.40.0000.00817.91
8.2.30.0000.00718.15
8.2.20.0080.00017.79
8.2.10.0050.00217.67
8.2.00.0000.00817.75
8.1.280.0150.00425.92
8.1.270.0060.00322.14
8.1.260.0080.00026.35
8.1.250.0040.00428.09
8.1.240.0040.00420.64
8.1.230.0110.00020.26
8.1.220.0060.00317.74
8.1.210.0050.00318.77
8.1.200.0030.00617.48
8.1.190.0030.00517.23
8.1.180.0000.00818.10
8.1.170.0060.00318.54
8.1.160.0040.00422.21
8.1.150.0040.00418.64
8.1.140.0030.00517.45
8.1.130.0070.00017.73
8.1.120.0000.00717.33
8.1.110.0040.00417.40
8.1.100.0070.00017.42
8.1.90.0050.00217.29
8.1.80.0050.00217.37
8.1.70.0040.00317.32
8.1.60.0060.00317.50
8.1.50.0020.00517.46
8.1.40.0000.00817.47
8.1.30.0000.00717.49
8.1.20.0060.00317.58
8.1.10.0030.00617.48
8.1.00.0040.00417.50
8.0.300.0040.00418.77
8.0.290.0030.00516.72
8.0.280.0000.00718.38
8.0.270.0030.00317.30
8.0.260.0060.00016.89
8.0.250.0080.00017.04
8.0.240.0030.00516.90
8.0.230.0000.00716.98
8.0.220.0000.00716.91
8.0.210.0040.00416.95
8.0.200.0000.00616.95
8.0.190.0060.00616.94
8.0.180.0030.00516.98
8.0.170.0040.00416.99
8.0.160.0030.00516.94
8.0.150.0000.00816.89
8.0.140.0000.00716.84
8.0.130.0000.00613.40
8.0.120.0050.00316.98
8.0.110.0040.00416.84
8.0.100.0000.00717.02
8.0.90.0000.00817.00
8.0.80.0100.00716.89
8.0.70.0000.00716.86
8.0.60.0000.00817.00
8.0.50.0030.00516.80
8.0.30.0130.00817.16
8.0.20.0160.00517.40
8.0.10.0040.00416.92
8.0.00.0120.00616.82
7.4.330.0030.00416.89
7.4.320.0000.00616.52
7.4.300.0030.00316.55
7.4.290.0060.00016.47
7.4.280.0030.00316.55
7.4.270.0030.00316.45
7.4.260.0070.00016.43
7.4.250.0030.00516.48
7.4.240.0050.00216.45
7.4.230.0030.00316.64
7.4.220.0070.01016.59
7.4.210.0080.00716.55
7.4.200.0020.00516.36
7.4.190.0070.00016.59
7.4.160.0120.00416.27
7.4.150.0070.01517.40
7.4.140.0100.01017.86
7.4.130.0110.00916.50
7.4.120.0110.00816.50
7.4.110.0060.01016.50
7.4.100.0100.00716.37
7.4.90.0100.00716.59
7.4.80.0060.01619.39
7.4.70.0120.00316.31
7.4.60.0060.01016.51
7.4.50.0060.00016.46
7.4.40.0090.00722.77
7.4.30.0180.00216.58
7.4.00.0030.01514.68
7.3.330.0000.00613.28
7.3.320.0000.00613.15
7.3.310.0070.00016.32
7.3.300.0030.00316.31
7.3.290.0110.00816.26
7.3.280.0050.01016.29
7.3.270.0090.00817.40
7.3.260.0160.00716.43
7.3.250.0120.00516.38
7.3.240.0070.01016.55
7.3.230.0140.00916.41
7.3.210.0140.00416.33
7.3.200.0140.00719.39
7.3.190.0120.00916.37
7.3.180.0160.00416.45
7.3.170.0060.01016.41
7.3.160.0090.00616.39
7.3.120.0030.01014.84
7.3.10.0070.00516.61
7.3.00.0050.00816.64
7.2.330.0130.00416.55
7.2.320.0120.00916.61
7.2.310.0040.01316.55
7.2.300.0100.01416.38
7.2.290.0100.00716.30
7.2.130.0090.00616.80
7.2.120.0080.00516.65
7.2.110.0060.00616.52
7.2.100.0020.01116.79
7.2.90.0040.00816.85
7.2.80.0060.00716.61
7.2.70.0050.00516.62
7.2.60.0040.00816.59
7.2.50.0010.01216.85
7.2.40.0090.00716.76
7.2.30.0070.00516.94
7.2.20.0070.00916.49
7.2.10.0000.01116.71
7.2.00.0050.00917.65
7.1.250.0030.00715.33
7.1.240.0000.00815.64
7.1.230.0000.00915.53
7.1.220.0060.00315.52
7.1.210.0060.00315.44
7.1.200.0060.00615.54
7.1.190.0070.01015.52
7.1.180.0000.00815.34
7.1.170.0100.00315.60
7.1.160.0120.00615.21
7.1.150.0170.00315.48
7.1.140.0000.01015.34
7.1.130.0160.00315.62
7.1.120.0210.00715.81
7.1.110.0120.00015.68
7.1.100.0140.00616.32
7.1.90.0030.00715.57
7.1.80.0120.00915.51
7.1.70.0050.00316.17
7.1.60.0080.00817.73
7.1.50.0090.00916.26
7.1.40.0090.00315.57
7.1.30.0030.00615.50
7.1.20.0070.00715.44
7.1.10.0100.00015.56
7.1.00.0100.03218.87
7.0.330.0070.00315.10
7.0.320.0100.00415.09
7.0.310.0030.00715.16
7.0.300.0130.00315.25
7.0.290.0000.01014.98
7.0.280.0140.00015.16
7.0.270.0120.00014.91
7.0.260.0070.01114.79
7.0.250.0240.00315.03
7.0.240.0120.00615.32
7.0.230.0060.00314.65
7.0.220.0070.00715.03
7.0.210.0110.01115.11
7.0.200.0130.00215.93
7.0.190.0090.00615.02
7.0.180.0140.00315.30
7.0.170.0070.00715.07
7.0.160.0000.01215.25
7.0.150.0090.00315.22
7.0.140.0100.03618.48
7.0.130.0040.01215.29
7.0.120.0070.00715.08
7.0.110.0080.00315.08
7.0.100.0150.00314.96
7.0.90.0000.00815.12
7.0.80.0130.00315.08
7.0.70.0210.00015.19
7.0.60.0050.04517.60
7.0.50.0120.03316.48
7.0.40.0070.04716.85
7.0.30.0150.04216.73
7.0.20.0200.04516.67
7.0.10.0130.04116.70
7.0.00.0050.02816.62
5.6.380.0070.00714.04
5.6.370.0060.00614.36
5.6.360.0090.00314.49
5.6.350.0070.00314.33
5.6.340.0080.00514.13
5.6.330.0070.00714.15
5.6.320.0080.00414.10
5.6.310.0070.00814.16
5.6.300.0190.00614.37
5.6.290.0090.00013.89
5.6.280.0030.04017.54
5.6.270.0060.01314.27
5.6.260.0120.00013.98
5.6.250.0030.00613.98
5.6.240.0030.01213.99
5.6.230.0000.01114.19
5.6.220.0030.00714.25
5.6.210.0180.03517.30
5.6.200.0080.02216.22
5.6.190.0050.04417.37
5.6.180.0250.04417.20
5.6.170.0120.04717.33
5.6.160.0170.02217.44
5.6.150.0070.02916.16
5.6.140.0050.03216.06
5.6.130.0090.02816.06
5.6.120.0150.02217.52
5.6.110.0110.04517.57
5.6.100.0080.03517.50
5.6.90.0030.04917.47
5.6.80.0070.04217.21
5.6.70.2340.02217.12
5.6.60.0040.00813.91
5.6.50.0310.00013.98
5.6.40.0130.00314.38
5.6.30.0100.00514.04
5.6.20.0110.01113.83
5.6.10.0100.00713.88
5.6.00.0060.00614.04
5.5.380.0030.00310.73
5.5.370.0000.00511.02
5.5.360.0000.00611.14
5.5.350.0110.02315.65
5.5.340.0100.02814.25
5.5.330.0030.03015.43
5.5.320.0220.04315.56
5.5.310.0170.02315.47
5.5.300.0090.03214.45
5.5.290.0030.02314.55
5.5.280.0010.04915.67
5.5.270.0080.04315.83
5.5.260.0100.03815.82
5.5.250.0070.04115.68
5.5.240.0110.03315.68
5.5.230.0100.00010.79
5.5.220.0140.00010.70
5.5.210.0090.00010.81
5.5.200.0130.00310.59
5.5.190.0060.00610.96
5.5.180.0030.00610.53
5.5.170.0170.00311.00
5.5.160.0120.00310.48
5.5.150.0100.00710.85
5.5.140.0080.00010.85
5.5.130.0040.00410.68
5.5.120.0080.00011.03
5.5.110.0060.00610.95
5.5.100.0170.00310.70
5.5.90.0100.00010.98
5.5.80.0240.00310.73
5.5.70.0060.00310.75
5.5.60.0050.00210.63
5.5.50.0070.00710.88
5.5.40.0120.00310.93
5.5.30.0070.00310.73
5.5.20.0030.00310.66
5.5.10.0030.00610.42
5.5.00.0060.00011.07
5.4.450.0370.03315.16
5.4.440.0450.04415.00
5.4.430.0130.02915.28
5.4.420.0120.03315.05
5.4.410.0400.03014.91
5.4.400.0140.03114.89
5.4.390.0430.03014.84
5.4.380.0480.02714.64
5.4.370.0170.02814.63
5.4.360.0200.02814.63
5.4.350.0030.02211.33
5.4.340.0070.01911.27
5.4.330.0040.00710.49
5.4.320.0120.02911.65
5.4.310.0040.02411.62
5.4.300.0080.02111.42
5.4.290.0060.02411.58
5.4.280.0070.02511.60
5.4.270.0100.02211.51
5.4.260.0100.02514.78
5.4.250.0050.03014.65
5.4.240.0020.03314.84
5.4.230.0090.02914.63
5.4.220.0130.02714.76
5.4.210.0100.02314.79
5.4.200.0020.03214.91
5.4.190.0050.03014.79
5.4.180.0030.02914.75
5.4.170.0050.02714.64
5.4.160.0030.02814.83
5.4.150.0060.03014.92
5.4.140.0080.02813.45
5.4.130.0090.03913.52
5.4.120.0150.02813.57
5.4.110.0050.03213.55
5.4.100.0050.02613.75
5.4.90.0080.02213.36
5.4.80.0080.02313.47
5.4.70.0020.02913.70
5.4.60.0050.02613.51
5.4.50.0060.02513.46
5.4.40.0030.02913.77
5.4.30.0020.03013.40
5.4.20.0050.04113.42
5.4.10.0050.02713.31
5.4.00.0060.02813.24
5.3.290.0100.02311.64
5.3.280.0070.02712.47
5.3.270.0080.02512.53
5.3.260.0090.02712.55
5.3.250.0030.03412.51
5.3.240.0030.02912.31
5.3.230.0080.02912.44
5.3.220.0070.02812.34
5.3.210.0050.03212.30
5.3.200.0020.03112.39
5.3.190.0090.02312.54
5.3.180.0070.02512.48
5.3.170.0050.03912.45
5.3.160.0080.03312.50
5.3.150.0080.02312.42
5.3.140.0070.02712.57
5.3.130.0060.03112.52
5.3.120.0180.02312.42
5.3.110.0110.02512.51
5.3.100.0100.02512.25
5.3.90.0050.03012.10
5.3.80.0070.02812.19
5.3.70.0050.02612.16
5.3.60.0010.03112.01
5.3.50.0140.02012.23
5.3.40.0060.02612.07
5.3.30.0080.02412.12
5.3.20.0060.02612.04
5.3.10.0060.02611.84
5.3.00.0090.02911.80
5.2.170.0120.02010.41
5.2.160.0060.02010.40
5.2.150.0060.02210.46
5.2.140.0140.01610.41
5.2.130.0140.01810.38
5.2.120.0040.02310.39
5.2.110.0030.02310.39
5.2.100.0080.02010.35
5.2.90.0110.02510.44
5.2.80.0020.02610.38
5.2.70.0030.02310.34
5.2.60.0070.02210.37
5.2.50.0090.02810.35
5.2.40.0070.02010.21
5.2.30.0090.02710.33
5.2.20.0070.02010.27
5.2.10.0070.02710.31
5.2.00.0070.02210.14
5.1.60.0090.0189.91
5.1.50.0060.0189.79
5.1.40.0080.0189.84
5.1.30.0060.0279.96
5.1.20.0030.02110.01
5.1.10.0030.0199.99
5.1.00.0100.0229.91
5.0.50.0050.0179.08
5.0.40.0030.0169.13
5.0.30.0020.0228.99
5.0.20.0060.0128.93
5.0.10.0030.0178.88
5.0.00.0050.0188.91
4.4.90.0040.0118.57
4.4.80.0040.0148.57
4.4.70.0010.0188.57
4.4.60.0080.0108.57
4.4.50.0030.0168.57
4.4.40.0020.0198.57
4.4.30.0050.0108.57
4.4.20.0000.0138.57
4.4.10.0060.0108.57
4.4.00.0020.0228.57
4.3.110.0000.0138.57
4.3.100.0030.0108.57
4.3.90.0020.0128.57
4.3.80.0040.0158.57
4.3.70.0020.0108.57
4.3.60.0030.0148.57
4.3.50.0010.0138.57
4.3.40.0020.0208.57
4.3.30.0070.0088.57
4.3.20.0030.0158.57
4.3.10.0010.0128.57
4.3.00.0020.0148.42

preferences:
42.86 ms | 401 KiB | 5 Q