3v4l.org

run code in 300+ PHP versions simultaneously
<?php class foo { private function do_something (bool $str) { echo "private function"; } public function call_something(foo $obj) { $obj->do_something(true); } } class bar extends foo { public function do_something (bool $value) { echo "subclass"; } } $a = new foo(); $b = new bar(); $b->call_something($a); $method = new ReflectionMethod($a); $method->invoke($b, true);

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.0140.00716.75
8.3.50.0070.00718.17
8.3.40.0110.00418.59
8.3.30.0140.00018.66
8.3.20.0040.00420.32
8.3.10.0070.00721.73
8.3.00.0000.00819.79
8.2.180.0070.01716.50
8.2.170.0120.00322.96
8.2.160.0070.00720.39
8.2.150.0070.00024.18
8.2.140.0000.00924.66
8.2.130.0080.00019.29
8.2.120.0060.00326.35
8.2.110.0000.00920.57
8.2.100.0070.00717.72
8.2.90.0000.00818.34
8.2.80.0000.00818.22
8.2.70.0000.00817.93
8.2.60.0030.00617.93
8.2.50.0040.00418.10
8.2.40.0000.00720.49
8.2.30.0080.00020.73
8.2.20.0040.00417.73
8.2.10.0070.00018.01
8.2.00.0070.00017.98
8.1.280.0090.00625.92
8.1.270.0050.00320.20
8.1.260.0040.00428.09
8.1.250.0020.00528.09
8.1.240.0100.00023.73
8.1.230.0070.00322.16
8.1.220.0080.00017.74
8.1.210.0050.00318.77
8.1.200.0040.00417.35
8.1.190.0080.00317.23
8.1.180.0080.00018.10
8.1.170.0050.00318.51
8.1.160.0000.00722.19
8.1.150.0000.00818.79
8.1.140.0000.00819.46
8.1.130.0000.00717.56
8.1.120.0030.00517.48
8.1.110.0030.00517.39
8.1.100.0040.00417.38
8.1.90.0040.00317.44
8.1.80.0000.00717.41
8.1.70.0000.00817.21
8.1.60.0080.00017.52
8.1.50.0080.00017.55
8.1.40.0030.00617.54
8.1.30.0050.00317.71
8.1.20.0050.00217.53
8.1.10.0070.00017.56
8.1.00.0000.00717.49
8.0.300.0040.00419.86
8.0.290.0090.00016.88
8.0.280.0000.00718.37
8.0.270.0070.00017.14
8.0.260.0000.00617.31
8.0.250.0000.00816.88
8.0.240.0040.00416.94
8.0.230.0080.00316.86
8.0.220.0020.00516.91
8.0.210.0040.00416.91
8.0.200.0000.00817.02
8.0.190.0070.00416.86
8.0.180.0000.00816.88
8.0.170.0030.00516.92
8.0.160.0040.00416.92
8.0.150.0080.00016.74
8.0.140.0030.00316.87
8.0.130.0060.00013.37
8.0.120.0040.00416.88
8.0.110.0050.00316.90
8.0.100.0040.00416.85
8.0.90.0070.00016.85
8.0.80.0040.01216.85
8.0.70.0040.00416.98
8.0.60.0040.00416.73
8.0.50.0000.00716.80
8.0.30.0090.00817.00
8.0.20.0110.00817.40
8.0.10.0040.00416.97
8.0.00.0100.00716.84
7.4.330.0030.00316.82
7.4.320.0070.00016.61
7.4.300.0000.00616.51
7.4.290.0050.00216.63
7.4.280.0050.00216.51
7.4.270.0060.00016.51
7.4.260.0030.00316.58
7.4.250.0050.00316.41
7.4.240.0050.00216.54
7.4.230.0070.00016.43
7.4.220.0040.01516.58
7.4.210.0090.00916.52
7.4.200.0030.00316.36
7.4.160.0070.00716.43
7.4.150.0130.00717.40
7.4.140.0080.01217.86
7.4.130.0140.00916.37
7.4.120.0150.00216.57
7.4.110.0110.00616.52
7.4.100.0110.00716.48
7.4.90.0070.01316.48
7.4.80.0120.01019.39
7.4.70.0130.00316.56
7.4.60.0090.00616.40
7.4.50.0040.01116.35
7.4.40.0090.00916.40
7.4.30.0080.00816.52
7.4.00.0070.01015.02
7.3.330.0000.00513.43
7.3.320.0050.00013.14
7.3.310.0030.00316.32
7.3.300.0030.00316.37
7.3.290.0090.00616.34
7.3.280.0070.01216.37
7.3.270.0030.01317.40
7.3.260.0130.00716.66
7.3.240.0110.00716.32
7.3.230.0120.00616.39
7.3.210.0100.00716.30
7.3.200.0060.01216.57
7.3.190.0090.00916.38
7.3.180.0100.01016.32
7.3.170.0080.01116.56
7.3.160.0110.00516.62
7.3.120.0040.01514.80
7.3.110.0070.01114.80
7.3.100.0070.01114.74
7.3.90.0070.00715.11
7.3.80.0150.00414.59
7.3.70.0030.01314.96
7.3.60.0090.00614.88
7.3.50.0070.00714.65
7.3.40.0030.01314.71
7.3.30.0070.00714.89
7.3.20.0070.00716.67
7.3.10.0100.00616.72
7.3.00.0160.00016.79
7.2.330.0110.00616.78
7.2.320.0160.00316.57
7.2.310.0150.00816.76
7.2.300.0030.01316.54
7.2.290.0040.01816.64
7.2.250.0040.01414.79
7.2.240.0060.01314.95
7.2.230.0040.01115.17
7.2.220.0000.01415.20
7.2.210.0090.00914.98
7.2.200.0100.00314.99
7.2.190.0060.00315.05
7.2.180.0070.00714.97
7.2.170.0090.00014.67
7.2.160.0090.00614.82
7.2.150.0100.00316.64
7.2.140.0110.00417.02
7.2.130.0090.00616.82
7.2.120.0030.00616.83
7.2.110.0070.00716.73
7.2.100.0000.01316.57
7.2.90.0090.00616.92
7.2.80.0070.01016.86
7.2.70.0070.01017.07
7.2.60.0030.01216.87
7.2.50.0060.01116.63
7.2.40.0100.00716.96
7.2.30.0150.00016.99
7.2.20.0060.00316.88
7.2.10.0060.01017.06
7.2.00.0090.00718.26
7.1.330.0090.00915.48
7.1.320.0070.00715.77
7.1.310.0060.00615.65
7.1.300.0100.00315.70
7.1.290.0030.01015.68
7.1.280.0080.00315.55
7.1.270.0060.00615.80
7.1.260.0030.00715.87
7.1.250.0040.00815.50
7.1.240.0080.00615.85
7.1.230.0060.00615.85
7.1.220.0040.01115.57
7.1.210.0000.01515.57
7.1.200.0050.00915.69
7.1.190.0000.01415.34
7.1.180.0030.00915.80
7.1.170.0000.01315.80
7.1.160.0070.00715.41
7.1.150.0030.01315.76
7.1.140.0060.00915.89
7.1.130.0120.00615.55
7.1.120.0070.00715.69
7.1.110.0030.01015.65
7.1.100.0070.00516.84
7.1.90.0030.00715.82
7.1.80.0030.01315.59
7.1.70.0050.00516.37
7.1.60.0060.01317.54
7.1.50.0090.01016.30
7.1.40.0110.00415.54
7.1.30.0070.00315.74
7.1.20.0070.00715.42
7.1.10.0100.00315.65
7.1.00.0050.03918.99
7.0.330.0100.00315.06
7.0.320.0000.01415.23
7.0.310.0040.01115.54
7.0.300.0060.00315.42
7.0.290.0060.00615.56
7.0.280.0070.00715.38
7.0.270.0100.00615.42
7.0.260.0030.00715.45
7.0.250.0110.00315.41
7.0.240.0060.00615.08
7.0.230.0000.01715.56
7.0.220.0070.01015.30
7.0.210.0040.01115.37
7.0.200.0000.01115.99
7.0.190.0030.00615.29
7.0.180.0070.00715.42
7.0.170.0000.01415.13
7.0.160.0050.00515.21
7.0.150.0000.01415.23
7.0.140.0060.00915.48
7.0.130.0030.01215.21
7.0.120.0090.00615.39
7.0.110.0060.00315.49
7.0.100.0040.01115.33
7.0.90.0000.01515.50
7.0.80.0060.00615.23
7.0.70.0070.00315.21
7.0.60.0080.04317.73
7.0.50.0090.04516.63
7.0.40.0080.02316.82
7.0.30.0290.02716.97
7.0.20.0200.04416.84
7.0.10.0090.03216.61
7.0.00.0100.04016.72
5.6.400.0030.01314.01
5.6.390.0050.00813.90
5.6.380.0000.01514.38
5.6.370.0090.00314.59
5.6.360.0120.00314.21
5.6.350.0070.00314.47
5.6.340.0000.01614.29
5.6.330.0030.01214.35
5.6.320.0060.01014.23
5.6.310.0060.00614.31
5.6.300.0060.00614.11
5.6.290.0060.00614.10
5.6.280.0050.04117.75
5.6.270.0060.00614.15
5.6.260.0110.00014.59
5.6.250.0030.01014.46
5.6.240.0060.00614.36
5.6.230.0040.01114.32
5.6.220.0030.01014.39
5.6.210.0100.03317.39
5.6.200.0070.03516.34
5.6.190.0050.05017.25
5.6.180.0160.03917.35
5.6.170.0250.01817.48
5.6.160.0070.02417.15
5.6.150.0070.04516.20
5.6.140.0070.04616.31
5.6.130.0100.04216.43
5.6.120.0070.03217.70
5.6.110.0030.04917.59
5.6.100.0050.04117.79
5.6.90.0030.02517.59
5.6.80.0030.03217.47
5.6.70.0030.01314.21
5.6.60.0060.00613.93
5.6.50.0000.01314.04
5.6.40.0040.00813.93
5.6.30.0030.01014.32
5.6.20.0120.00014.19
5.6.10.0040.00814.24
5.6.00.0030.01014.13
5.5.380.0030.01014.10
5.5.370.0070.01014.17
5.5.360.0070.00713.85
5.5.350.0080.04517.30
5.5.340.0050.02015.99
5.5.330.0050.04317.05
5.5.320.0260.02917.27
5.5.310.0150.03717.25
5.5.300.0020.02616.14
5.5.290.0080.03316.11
5.5.280.0060.02517.45
5.5.270.0100.03517.62
5.5.260.0060.03017.51
5.5.250.0090.03317.32
5.5.240.2120.02517.29
5.5.230.0030.00913.97
5.5.220.0030.01214.22
5.5.210.0070.00314.20
5.5.200.0070.00713.88
5.5.190.0060.00814.04
5.5.180.0030.01014.07
5.5.170.0080.00614.20
5.5.160.0030.01014.16
5.5.150.0000.01514.00
5.5.140.0030.01014.08
5.5.130.0030.00913.86
5.5.120.0030.00713.86
5.5.110.0070.00714.07
5.5.100.0000.00914.23
5.5.90.0000.01514.26
5.5.80.0060.00713.98
5.5.70.0100.00714.30
5.5.60.0040.00413.94
5.5.50.0030.00614.04
5.5.40.0100.00314.14
5.5.30.0050.00314.23
5.5.20.0050.00514.21
5.5.10.0040.00714.17
5.5.00.0070.00714.14

preferences:
39.97 ms | 400 KiB | 5 Q