3v4l.org

run code in 300+ PHP versions simultaneously
<?php class B { public function method() { echo "BBB"; } } class A { public function method() { echo "I'not suppose to"; } } class TestParentClass extends A { public function method() { print_r('Parent method'); print "\n"; } } trait TestTrait { public function method() { print_r('Trait method'); print "\n"; } } class TestChildClass extends TestParentClass { use TestTrait { B::method as mth; /* TestTrait::method as methodAlias; TestParentClass::method insteadof TestTrait; */ } } (new TestChildClass)->mth(); (new TestChildClass)->method(); (new TestChildClass)->method(); (new TestChildClass)->methodAlias();

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.0110.00418.43
8.3.50.0120.00522.05
8.3.40.0100.00718.76
8.3.30.0100.00718.55
8.3.20.0030.00518.79
8.3.10.0080.00020.40
8.3.00.0000.00823.51
8.2.180.0140.00416.88
8.2.170.0140.00422.96
8.2.160.0030.01020.37
8.2.150.0080.00024.18
8.2.140.0000.00824.66
8.2.130.0090.00026.16
8.2.120.0050.00319.49
8.2.110.0060.00321.24
8.2.100.0100.00317.91
8.2.90.0080.00019.28
8.2.80.0000.00817.97
8.2.70.0040.00417.63
8.2.60.0080.00017.80
8.2.50.0040.00418.07
8.2.40.0040.00418.09
8.2.30.0080.00418.02
8.2.20.0040.00417.47
8.2.10.0070.00017.62
8.2.00.0000.00717.63
8.1.280.0100.00725.92
8.1.270.0050.00223.99
8.1.260.0130.00326.35
8.1.250.0000.00828.09
8.1.240.0150.00622.34
8.1.230.0040.00720.84
8.1.220.0040.00418.77
8.1.210.0050.00318.89
8.1.200.0060.00317.23
8.1.190.0000.00717.28
8.1.180.0040.00418.10
8.1.170.0000.00818.78
8.1.160.0000.00818.76
8.1.150.0040.00418.47
8.1.140.0050.00217.43
8.1.130.0040.00417.64
8.1.120.0050.00317.36
8.1.110.0040.00417.39
8.1.100.0080.00017.32
8.1.90.0030.00517.28
8.1.80.0030.00317.39
8.1.70.0000.00717.27
8.1.60.0030.00617.40
8.1.50.0020.00517.26
8.1.40.0000.00817.52
8.1.30.0050.00317.51
8.1.20.0000.00917.56
8.1.10.0060.00317.38
8.1.00.0070.00017.19
8.0.300.0080.00020.02
8.0.290.0030.00616.75
8.0.280.0000.00718.38
8.0.270.0050.00317.11
8.0.260.0030.00318.35
8.0.250.0000.00716.93
8.0.240.0040.00516.96
8.0.230.0030.00316.88
8.0.220.0050.00316.95
8.0.210.0050.00316.90
8.0.200.0030.00316.84
8.0.190.0000.00716.83
8.0.180.0030.00716.85
8.0.170.0030.00416.95
8.0.160.0070.00016.98
8.0.150.0020.00516.90
8.0.140.0000.00816.86
8.0.130.0030.00313.30
8.0.120.0080.00016.90
8.0.110.0000.00716.88
8.0.100.0060.00316.88
8.0.90.0000.00716.94
8.0.80.0110.00316.83
8.0.70.0000.00716.87
8.0.60.0040.00416.96
8.0.50.0000.00716.86
8.0.30.0100.00817.04
8.0.20.0130.00617.40
8.0.10.0050.00317.02
8.0.00.0140.00616.84
7.4.330.0050.00014.70
7.4.320.0000.00616.49
7.4.300.0060.00016.57
7.4.290.0040.00416.58
7.4.280.0050.00316.39
7.4.270.0030.00316.41
7.4.260.0030.00313.16
7.4.250.0030.00516.49
7.4.240.0080.00016.43
7.4.230.0000.00716.61
7.4.220.0100.00716.40
7.4.210.0120.00616.41
7.4.200.0050.00216.44
7.4.190.0000.00716.70
7.4.160.0150.00316.48
7.4.150.0070.01017.40
7.4.140.0140.00817.86
7.4.130.0160.00516.45
7.4.120.0100.00816.48
7.4.110.0100.00716.64
7.4.100.0060.01616.45
7.4.90.0100.00716.30
7.4.80.0030.01319.04
7.4.70.0100.00616.30
7.4.60.0100.01016.30
7.4.50.0030.00516.39
7.4.40.0040.01122.27
7.4.30.0130.00616.57
7.4.00.0020.01615.06
7.3.330.0020.00213.25
7.3.320.0000.00713.27
7.3.310.0030.00316.14
7.3.300.0000.00716.23
7.3.290.0100.00316.31
7.3.280.0100.00616.30
7.3.270.0100.00617.40
7.3.260.0160.00518.24
7.3.250.0080.01016.24
7.3.240.0170.00016.35
7.3.230.0000.01516.39
7.3.210.0090.00916.37
7.3.200.0110.00719.39
7.3.190.0060.01516.39
7.3.180.0120.00816.35
7.3.170.0100.00616.43
7.3.160.0080.00816.58
7.3.120.0050.01214.57
7.3.110.0070.01014.89
7.3.100.0080.00814.82
7.3.90.0030.01014.84
7.3.80.0090.00614.60
7.3.70.0040.01114.63
7.3.60.0100.00314.71
7.3.50.0040.01014.63
7.3.40.0030.00614.78
7.3.30.0040.01114.57
7.3.20.0110.00316.51
7.3.10.0040.01216.27
7.3.00.0050.00316.69
7.2.330.0120.00416.57
7.2.320.0130.00316.50
7.2.310.0090.00916.62
7.2.300.0070.01016.66
7.2.290.0110.01116.38
7.2.250.0030.01314.85
7.2.240.0090.00914.73
7.2.230.0000.02015.08
7.2.220.0070.00714.83
7.2.210.0090.00314.99
7.2.200.0060.00914.97
7.2.190.0000.01414.50
7.2.180.0000.01414.97
7.2.170.0030.00614.54
7.2.60.0040.01116.54
7.2.00.0040.01119.42
7.1.330.0080.00815.74
7.1.320.0090.00015.80
7.1.310.0030.01115.61
7.1.300.0060.00615.54
7.1.290.0030.01015.64
7.1.280.0030.00915.87
7.1.270.0100.00615.62
7.1.260.0000.01115.60
7.1.200.0060.00315.72
7.1.100.0030.01017.75
7.1.70.0070.00317.11
7.1.60.0100.01419.40
7.1.50.0060.01616.95
7.1.00.0030.03722.36
7.0.200.0100.00016.66
7.0.140.0000.07721.95
7.0.60.0030.09019.93
7.0.50.0000.04317.88
7.0.40.0070.08720.40
7.0.30.0270.07320.25
7.0.20.0300.05320.19
7.0.10.0430.06720.16
7.0.00.0000.09320.16
5.6.280.0130.06721.13
5.6.210.0100.07720.51
5.6.200.0100.04718.25
5.6.190.0100.04320.57
5.6.180.0300.07020.67
5.6.170.0270.06720.46
5.6.160.0200.07320.48
5.6.150.0100.07718.14
5.6.140.0000.04318.12
5.6.130.0030.05718.27
5.6.120.0070.04321.10
5.6.110.0000.05021.02
5.6.100.0030.05721.11
5.6.90.0130.06721.11
5.6.80.0030.06320.36
5.6.70.0330.05720.43
5.5.350.3970.04720.39
5.5.340.0000.08017.95
5.5.330.0030.04320.43
5.5.320.0200.06320.21
5.5.310.0370.07020.32
5.5.300.0000.08318.08
5.5.290.0070.04017.92
5.5.280.0070.04720.66
5.5.270.0130.05320.87
5.5.260.0030.08720.80
5.5.250.0070.07320.79
5.5.240.0000.06720.36
5.4.450.1770.04319.54
5.4.440.2000.04319.54
5.4.430.1870.04719.56
5.4.420.2130.03719.40
5.4.410.1830.04319.41
5.4.400.1970.02718.95
5.4.390.1830.03719.25
5.4.380.1230.05019.30
5.4.370.0070.03319.09
5.4.360.0130.06018.98
5.4.350.1370.03319.13
5.4.340.1930.04319.09
5.4.320.1970.04719.24
5.4.310.1870.04019.16
5.4.300.1830.04319.16
5.4.290.1730.03319.06
5.4.280.1830.04019.05
5.4.270.1800.04019.18
5.4.260.1830.03718.96
5.4.250.2100.04019.19
5.4.240.1730.04318.94
5.4.230.0030.06318.83
5.4.220.0170.03718.97
5.4.210.0630.04318.87
5.4.200.1970.04018.86
5.4.190.1970.04718.96
5.4.180.0400.04019.07
5.4.170.0100.07019.08
5.4.160.0000.04019.13
5.4.150.0030.03719.29
5.4.140.1900.04016.39
5.4.130.2230.04016.45
5.4.120.2000.04316.34
5.4.110.2000.03716.60
5.4.100.1930.04716.45
5.4.90.2030.04316.60
5.4.80.1730.03716.61
5.4.70.2070.04316.28
5.4.60.2000.04016.25
5.4.50.2030.03716.53
5.4.40.2000.04316.22
5.4.30.1770.03316.42
5.4.20.2000.04316.32
5.4.10.2100.03016.42
5.4.00.1770.03715.96
5.3.290.1800.03314.89
5.3.280.1930.04714.57
5.3.270.2000.04714.76
5.3.260.1800.04314.68
5.3.250.1800.03014.51
5.3.240.2030.04714.54
5.3.230.2030.04714.57
5.3.220.2100.04014.69
5.3.210.1830.03014.57
5.3.200.1800.04014.54
5.3.190.2100.04014.47
5.3.180.1930.03714.49
5.3.170.1770.03714.65
5.3.160.1830.04314.64
5.3.150.2030.04314.71
5.3.140.2070.03314.55
5.3.130.2000.03714.45
5.3.120.1730.04314.54
5.3.110.1970.04714.57
5.3.100.2130.04313.95
5.3.90.1830.03714.25
5.3.80.1700.03314.09
5.3.70.1700.03313.92
5.3.60.1800.03313.92
5.3.50.1900.04014.03
5.3.40.1800.04013.96
5.3.30.1730.03713.99
5.3.20.2370.04013.75
5.3.10.1930.03313.57
5.3.00.1900.03313.66
5.2.170.1570.02711.74
5.2.160.1370.02311.74
5.2.150.0000.03011.74
5.2.140.0100.02011.74
5.2.130.0000.03011.74
5.2.120.1870.03011.74
5.2.110.1670.01711.74
5.2.100.1530.03011.74
5.2.90.1570.03311.74
5.2.80.1530.03011.74
5.2.70.1600.02311.74
5.2.60.1400.03011.74
5.2.50.1600.02311.74
5.2.40.1230.03011.74
5.2.30.1230.03011.74
5.2.20.1100.03011.74
5.2.10.1270.02711.74
5.2.00.1270.02711.74
5.1.60.1230.02311.74
5.1.50.1200.02011.74
5.1.40.1300.02011.74
5.1.30.1470.03711.74
5.1.20.1470.03011.74
5.1.10.1200.02311.74
5.1.00.1170.02711.74
5.0.50.0730.02311.74
5.0.40.0630.01711.74
5.0.30.0770.04711.74
5.0.20.0700.02011.74
5.0.10.0730.03311.74
5.0.00.0600.02711.74
4.4.90.0670.01711.74
4.4.80.0570.02011.74
4.4.70.0670.02311.74
4.4.60.0670.01311.74
4.4.50.0600.01711.74
4.4.40.0600.03011.74
4.4.30.0870.02711.74
4.4.20.0730.02711.74
4.4.10.0770.02311.74
4.4.00.0670.04011.74
4.3.110.0430.03011.74
4.3.100.0730.02011.74
4.3.90.0530.01711.74
4.3.80.0700.03711.74
4.3.70.0730.02311.74
4.3.60.0730.02011.74
4.3.50.0570.02011.74
4.3.40.0530.02711.74
4.3.30.0330.03011.74
4.3.20.0330.03311.74
4.3.10.0300.02011.74
4.3.00.0000.01711.74

preferences:
53.04 ms | 401 KiB | 5 Q