3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait theTrait { protected function test($a, $x=[]) { echo $a; } } class theClass { use theTrait; } class theExtend extends theClass { protected function test($a) { echo 'prefixed: ' . $a; } } $x = new theClass;

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.43
8.3.50.0100.00718.08
8.3.40.0070.00720.73
8.3.30.0110.00418.55
8.3.20.0040.00424.18
8.3.10.0000.00824.66
8.3.00.0030.00626.16
8.2.180.0230.00025.92
8.2.170.0130.01018.79
8.2.160.0160.00622.96
8.2.150.0080.00825.66
8.2.140.0060.00324.66
8.2.130.0050.00326.16
8.2.120.0040.00419.64
8.2.110.0060.00322.05
8.2.100.0090.00317.91
8.2.90.0050.00317.91
8.2.80.0090.00018.09
8.2.70.0000.00817.63
8.2.60.0060.00318.22
8.2.50.0050.00318.07
8.2.40.0040.00418.10
8.2.30.0000.00818.05
8.2.20.0000.00818.04
8.2.10.0050.00318.75
8.2.00.0040.00419.21
8.1.270.0020.00523.99
8.1.260.0000.00926.35
8.1.250.0040.00428.09
8.1.240.0060.00319.01
8.1.230.0040.00722.11
8.1.220.0060.00317.74
8.1.210.0070.00718.77
8.1.200.0060.00317.35
8.1.190.0040.00417.23
8.1.180.0000.00818.10
8.1.170.0000.00818.71
8.1.160.0000.00818.82
8.1.150.0050.00218.57
8.1.140.0070.00017.34
8.1.130.0060.00318.28
8.1.120.0090.00318.14
8.1.110.0080.00418.14
8.1.100.0070.00417.89
8.1.90.0060.00618.15
8.1.80.0040.00918.19
8.1.70.0110.00318.12
8.1.60.0130.00218.28
8.1.50.0090.00518.29
8.1.40.0130.00218.26
8.1.30.0100.00518.26
8.1.20.0090.00618.33
8.1.10.0120.00318.14
8.1.00.0070.00518.06
8.0.300.0050.00320.03
8.0.290.0040.00416.63
8.0.280.0030.00318.31
8.0.270.0040.00418.03
8.0.260.0000.00718.91
8.0.250.0050.00618.27
8.0.240.0120.00017.62
8.0.230.0100.00217.60
8.0.220.0050.00717.58
8.0.210.0100.00217.57
8.0.200.0060.00617.63
8.0.190.0080.00517.63
8.0.180.0090.00417.65
8.0.170.0060.00817.62
8.0.160.0050.00817.63
8.0.150.0100.00317.54
8.0.140.0100.00317.56
8.0.130.0090.00516.38
8.0.120.0080.00517.62
8.0.110.0070.00417.20
8.0.100.0070.00617.54
8.0.90.0090.00317.62
8.0.80.0100.00317.53
8.0.70.0090.00417.54
8.0.60.0100.00217.59
8.0.50.0070.00517.54
8.0.30.0060.00717.58
8.0.20.0080.00517.64
8.0.10.0070.00517.69
8.0.00.0060.00617.74
7.4.330.0080.00315.03
7.4.320.0080.00517.15
7.4.300.0090.00317.24
7.4.290.0110.00317.28
7.4.280.0100.00417.26
7.4.270.0050.00817.20
7.4.260.0090.00416.14
7.4.250.0120.00217.21
7.4.240.0060.00417.10
7.4.230.0070.00317.27
7.4.220.0100.00117.23
7.4.210.0070.00417.23
7.4.200.0020.00817.21
7.4.190.0070.00617.27
7.4.180.0060.00617.29
7.4.160.0080.00417.26
7.4.150.0070.00417.22
7.4.140.0080.00417.21
7.4.130.0100.00317.18
7.4.120.0110.00217.02
7.4.110.0060.00617.09
7.4.100.0050.00517.23
7.4.90.0060.00417.21
7.4.80.0040.00617.61
7.4.70.0060.00317.09
7.4.60.0050.00617.05
7.4.50.0010.00717.03
7.4.40.0040.00517.11
7.4.30.0050.00417.06
7.4.20.0030.00817.07
7.4.10.0040.00617.10
7.4.00.0060.00417.09
7.3.330.0050.00616.45
7.3.320.0090.00215.93
7.3.310.0100.00316.97
7.3.300.0100.00216.98
7.3.290.0070.00616.99
7.3.280.0090.00317.00
7.3.270.0090.00516.96
7.3.260.0070.00617.00
7.3.250.0100.00216.96
7.3.240.0080.00416.95
7.3.230.0080.00517.01
7.3.220.0080.00516.88
7.3.210.0090.00416.86
7.3.200.0060.00616.90
7.3.190.0080.00416.89
7.3.180.0080.00516.92
7.3.170.0100.00316.93
7.3.160.0080.00516.99
7.3.150.0080.00516.85
7.3.140.0100.00216.88
7.3.130.0070.00616.99
7.3.120.0120.00017.00
7.3.110.0080.00416.79
7.3.100.0120.00116.93
7.3.90.0080.00517.13
7.3.80.0100.00416.84
7.3.70.0060.00716.97
7.3.60.0090.00317.08
7.3.50.0100.00417.03
7.3.40.0070.00517.04
7.3.30.0060.00617.10
7.3.20.0070.00718.88
7.3.10.0110.00218.78
7.3.00.0110.00318.87

preferences:
57.03 ms | 400 KiB | 5 Q