3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace hippos; trait test { public static function getClassName() { return 'hi hippo'; } } namespace lions; trait test { public static function getClassName() { return 'hi giraffe'; } } namespace girrafe; use lions\test; use hippos\test as hipposTest; class lemons { use hipposTest, test { test::getClassName insteadof hipposTest; } public function sup() { var_dump(method_exists('lemons', 'getClassName')); var_dump(method_exists(get_class(), 'getClassName')); var_dump(method_exists(get_class(), 'myGetClassName')); echo $this->getClassName(); echo $this->myGetClassName(); } } (new \girrafe\lemons)->sup();

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.00616.75
8.3.50.0120.00721.93
8.3.40.0090.00618.66
8.3.30.0070.00718.64
8.3.20.0050.00320.39
8.3.10.0050.00323.66
8.3.00.0030.00619.50
8.2.180.0130.00318.29
8.2.170.0100.00322.96
8.2.160.0130.00020.39
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0040.00717.50
8.2.120.0040.00426.35
8.2.110.0100.00021.12
8.2.100.0090.00317.84
8.2.90.0040.00419.23
8.2.80.0030.00617.97
8.2.70.0060.00317.63
8.2.60.0050.00317.80
8.2.50.0000.00818.10
8.2.40.0030.00819.31
8.2.30.0040.00420.65
8.2.20.0040.00417.84
8.2.10.0040.00418.15
8.2.00.0080.00017.96
8.1.280.0100.00725.92
8.1.270.0040.00422.11
8.1.260.0070.00428.09
8.1.250.0040.00428.09
8.1.240.0030.00622.68
8.1.230.0040.00819.48
8.1.220.0000.00817.75
8.1.210.0090.00018.77
8.1.200.0000.00817.23
8.1.190.0040.00417.25
8.1.180.0000.00818.10
8.1.170.0000.00818.52
8.1.160.0040.00421.95
8.1.150.0040.00420.60
8.1.140.0030.00519.54
8.1.130.0030.00317.62
8.1.120.0040.00417.33
8.1.110.0040.00417.45
8.1.100.0000.00717.30
8.1.90.0050.00217.33
8.1.80.0080.00317.31
8.1.70.0030.00317.29
8.1.60.0040.00417.57
8.1.50.0000.00817.52
8.1.40.0040.00417.38
8.1.30.0080.00017.58
8.1.20.0060.00317.55
8.1.10.0050.00317.61
8.1.00.0040.00417.50
8.0.300.0040.00418.77
8.0.290.0030.00516.61
8.0.280.0000.00718.47
8.0.270.0000.00717.21
8.0.260.0030.00317.29
8.0.250.0000.00816.95
8.0.240.0050.00316.91
8.0.230.0000.00716.98
8.0.220.0020.00517.00
8.0.210.0000.00717.02
8.0.200.0000.00616.92
8.0.190.0000.00817.11
8.0.180.0000.00717.00
8.0.170.0040.00417.00
8.0.160.0030.00517.04
8.0.150.0040.00316.95
8.0.140.0080.00316.84
8.0.130.0050.00013.35
8.0.120.0040.00417.01
8.0.110.0040.00417.03
8.0.100.0000.00816.98
8.0.90.0000.00716.79
8.0.80.0090.00616.93
8.0.70.0000.00716.90
8.0.60.0020.00517.01
8.0.50.0050.00316.92
8.0.30.0060.01217.20
8.0.20.0080.01017.40
8.0.10.0070.00016.88
8.0.00.0130.01016.72
7.4.330.0000.00515.08
7.4.320.0030.00316.48
7.4.300.0060.00016.47
7.4.290.0040.00416.48
7.4.280.0030.00516.48
7.4.270.0000.00816.55
7.4.260.0030.00316.42
7.4.250.0050.00316.43
7.4.240.0030.00316.50
7.4.230.0000.00716.35
7.4.220.0060.01116.60
7.4.210.0070.00716.54
7.4.200.0070.00016.57
7.4.160.0100.00616.56
7.4.150.0140.00517.40
7.4.140.0150.01517.86
7.4.130.0080.00916.59
7.4.120.0110.00816.47
7.4.110.0170.00916.29
7.4.100.0120.00616.39
7.4.90.0070.01016.48
7.4.80.0150.01119.39
7.4.70.0070.01116.54
7.4.60.0060.01016.46
7.4.50.0000.00716.41
7.4.40.0030.01316.67
7.4.30.0000.01816.55
7.4.00.0070.00715.01
7.3.330.0000.00513.39
7.3.320.0030.00313.23
7.3.310.0000.00816.46
7.3.300.0060.00316.29
7.3.290.0050.00216.40
7.3.280.0050.01116.39
7.3.270.0090.00817.40
7.3.260.0140.01016.47
7.3.250.0090.01116.42
7.3.240.0060.01116.41
7.3.230.0150.00316.43
7.3.210.0100.00716.54
7.3.200.0070.01016.52
7.3.190.0040.01216.41
7.3.180.0200.00616.52
7.3.170.0110.00616.61
7.3.160.0120.00416.37
7.2.330.0040.02016.76
7.2.320.0060.01616.74
7.2.310.0030.01416.78
7.2.300.0090.00916.46
7.2.290.0100.01016.57
7.2.60.0160.00616.58
7.1.200.0060.00615.72
7.1.70.0040.00416.97
7.1.60.0060.00919.48
7.1.50.0090.01516.71
7.1.00.0030.07322.43
7.0.200.0250.00714.63
7.0.60.0000.08720.04
7.0.50.0070.08317.97
7.0.40.0170.08020.13
7.0.30.0270.08020.07
7.0.20.0300.06020.04
7.0.10.0030.04320.15
7.0.00.0070.07720.24
5.6.210.0000.04320.73
5.6.200.0070.07318.18
5.6.190.0070.06020.61
5.6.180.0300.07020.33
5.6.170.0270.04720.44
5.6.160.0230.06320.44
5.6.150.0070.05318.12
5.6.140.0100.08018.14
5.6.130.0100.07718.18
5.6.120.0070.08321.03
5.6.110.0100.05720.89
5.6.100.0070.08021.02
5.6.90.0030.04021.00
5.6.80.0000.06720.40
5.5.350.3800.04020.48
5.5.340.0030.08018.00
5.5.330.0070.08720.46
5.5.320.0570.07320.32
5.5.310.0170.06720.29
5.5.300.0030.04318.04
5.5.290.0070.03717.99
5.5.280.0000.06020.98
5.5.270.0030.04320.77
5.5.260.0030.08720.77
5.5.250.0030.08320.59
5.5.240.0130.04320.13

preferences:
58.51 ms | 401 KiB | 5 Q