3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait foo { public function bar() { echo 'trait'; } } class a { public function bar() { echo 'parent'; } } class b extends a { use foo { a::bar insteadof bar; bar as bat; } } (new b)->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.4.120.0090.00723.92
8.4.110.0110.00918.62
8.4.100.0140.00718.77
8.4.90.0120.00820.29
8.4.80.0060.00518.49
8.4.70.0050.00318.94
8.4.60.0100.00918.79
8.4.50.0120.00820.21
8.4.40.0090.00019.61
8.4.30.0060.00317.55
8.4.20.0140.00717.64
8.4.10.0080.01117.59
8.3.250.0120.00618.70
8.3.240.0040.00416.99
8.3.230.0120.00516.44
8.3.220.0060.00319.17
8.3.210.0100.00816.56
8.3.200.0060.00516.79
8.3.190.0070.01318.69
8.3.180.0080.01018.79
8.3.170.0090.00916.59
8.3.160.0040.00417.16
8.3.150.0070.00416.73
8.3.140.0040.00418.77
8.3.130.0040.00816.56
8.3.120.0090.00020.91
8.3.110.0080.00820.94
8.3.100.0040.00418.58
8.3.90.0040.00418.60
8.3.80.0060.00318.55
8.3.70.0080.00818.40
8.3.60.0070.01018.55
8.3.50.0110.00721.95
8.3.40.0090.00918.67
8.3.30.0070.00718.55
8.3.20.0000.00720.07
8.3.10.0050.00320.36
8.3.00.0040.00420.64
8.2.290.0060.00220.44
8.2.280.0050.00618.16
8.2.270.0110.00418.93
8.2.260.0140.00316.66
8.2.250.0060.00318.35
8.2.240.0120.00618.54
8.2.230.0050.00522.58
8.2.220.0060.00324.06
8.2.210.0000.00826.77
8.2.200.0040.00416.63
8.2.190.0090.00616.58
8.2.180.0100.01018.42
8.2.170.0110.00418.91
8.2.160.0090.00622.96
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0050.00319.36
8.2.120.0030.00526.35
8.2.110.0070.00320.52
8.2.100.0090.00317.72
8.2.90.0060.00319.23
8.2.80.0040.00417.97
8.2.70.0060.00317.38
8.2.60.0040.00417.66
8.2.50.0040.00818.10
8.2.40.0000.00920.66
8.2.30.0000.00919.30
8.2.20.0040.00417.71
8.2.10.0020.00517.87
8.2.00.0000.00717.94
8.1.330.0100.00822.07
8.1.320.0110.00917.73
8.1.310.0030.01415.74
8.1.300.0160.00315.88
8.1.290.0060.00318.88
8.1.280.0150.00025.92
8.1.270.0050.00223.87
8.1.260.0070.00028.09
8.1.250.0040.00428.09
8.1.240.0030.00623.71
8.1.230.0040.00720.87
8.1.220.0030.00517.74
8.1.210.0030.00518.77
8.1.200.0030.00717.23
8.1.190.0080.00017.10
8.1.180.0150.00018.10
8.1.170.0060.00318.50
8.1.160.0040.00420.68
8.1.150.0040.00418.81
8.1.140.0000.00819.41
8.1.130.0000.00717.65
8.1.120.0030.00617.29
8.1.110.0050.00317.28
8.1.100.0030.00517.26
8.1.90.0040.00417.28
8.1.80.0040.00417.41
8.1.70.0040.00417.27
8.1.60.0000.00717.50
8.1.50.0000.00817.46
8.1.40.0050.00317.53
8.1.30.0000.00817.43
8.1.20.0040.00417.54
8.1.10.0040.00417.38
8.1.00.0030.00617.28
8.0.300.0040.00418.77
8.0.290.0000.00716.75
8.0.280.0040.00418.37
8.0.270.0000.00716.87
8.0.260.0000.00617.12
8.0.250.0030.00316.95
8.0.240.0030.00316.90
8.0.230.0000.00716.84
8.0.220.0030.00516.82
8.0.210.0040.00416.75
8.0.200.0030.00316.93
8.0.190.0030.00716.86
8.0.180.0040.00416.80
8.0.170.0040.00416.81
8.0.160.0070.00016.79
8.0.150.0080.00016.93
8.0.140.0000.00716.69
8.0.130.0030.00313.24
8.0.120.0030.00616.85
8.0.110.0040.00416.83
8.0.100.0040.00416.83
8.0.90.0040.00416.73
8.0.80.0070.01416.82
8.0.70.0070.00016.94
8.0.60.0040.00416.66
8.0.50.0000.00716.84
8.0.30.0080.01017.08
8.0.20.0080.01217.40
8.0.10.0070.00016.90
8.0.00.0110.00616.61
7.4.330.0070.00015.08
7.4.320.0060.00016.45
7.4.300.0040.00416.39
7.4.290.0030.00316.53
7.4.280.0040.00316.34
7.4.270.0000.00716.41
7.4.260.0030.00316.51
7.4.250.0030.00616.46
7.4.240.0000.00716.47
7.4.230.0060.00016.53
7.4.220.0110.00416.52
7.4.210.0080.00916.52
7.4.200.0080.00016.51
7.4.160.0050.01016.49
7.4.150.0080.01217.40
7.4.140.0100.00817.86
7.4.130.0100.00716.49
7.4.120.0080.00916.31
7.4.110.0070.01016.71
7.4.100.0030.01316.46
7.4.90.0180.00316.38
7.4.80.0070.01019.39
7.4.70.0130.00216.42
7.4.60.0120.00316.42
7.4.50.0030.00716.26
7.4.40.0030.01316.52
7.4.30.0120.00616.54
7.4.00.0100.00314.91
7.3.330.0050.00013.32
7.3.320.0000.00613.11
7.3.310.0030.00316.40
7.3.300.0030.00316.18
7.3.290.0000.00616.21
7.3.280.0070.01016.26
7.3.270.0110.00817.40
7.3.260.0110.00616.31
7.3.250.0120.00516.37
7.3.240.0100.00716.40
7.3.230.0030.01316.43
7.3.210.0090.01116.31
7.3.200.0100.00616.34
7.3.190.0140.00716.52
7.3.180.0110.00416.56
7.3.170.0100.01016.60
7.3.160.0090.00616.34
7.2.330.0070.01016.61
7.2.320.0110.00616.54
7.2.310.0080.01516.56
7.2.300.0090.00716.34
7.2.290.0090.00716.50
7.2.60.0090.00616.71
7.2.00.0100.00718.77
7.1.200.0030.00715.58
7.1.100.0060.00618.20
7.1.70.0000.00916.90
7.1.60.0170.00719.12
7.1.50.0000.01816.80
7.1.00.0030.07722.53
7.0.200.0000.00816.69
7.0.60.0230.06719.99
7.0.50.0030.08717.88
7.0.40.0030.05020.30
7.0.30.0230.08320.09
7.0.20.0500.04720.23
7.0.10.0100.03720.09
7.0.00.0070.08320.05
5.6.280.0100.06720.91
5.6.210.0030.07720.73
5.6.200.0030.05718.24
5.6.190.0030.04720.77
5.6.180.0100.03320.67
5.6.170.0270.06320.55
5.6.160.0170.07720.50
5.6.150.0130.06018.17
5.6.140.0030.05318.15
5.6.130.0030.05018.18
5.6.120.0070.07721.10
5.6.110.0070.07320.99
5.6.100.0170.08021.11
5.6.90.0070.08021.03
5.6.80.0170.07020.39
5.5.350.0300.07320.40
5.5.340.0100.07717.98
5.5.330.0000.04320.43
5.5.320.0530.07320.35
5.5.310.0230.07720.20
5.5.300.0030.04317.98
5.5.290.0200.07018.00
5.5.280.0070.05020.76
5.5.270.0130.07720.87
5.5.260.0300.05320.94
5.5.250.0070.05320.59
5.5.240.0170.05720.15

preferences:
27.55 ms | 403 KiB | 5 Q