3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_mode=1); interface BarInterface { } interface ServerBarInterface { public function doBar(); } interface FooInterface { public function doFoo(BarInterface $bar); } class SomeFoo implements FooInterface { public function doFoo(ServerBarInterface $bar) { $bar->doBar(); } } class RegularBar implements BarInterface {} class ServerBar implements ServerBarInterface { public function doBar() { echo "works"; } } $foo = new SomeFoo; $bar = new RegularBar; $foo->doFoo($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.3.70.0070.01118.30
8.3.60.0070.01416.73
8.3.50.0070.01121.92
8.3.40.0070.00718.79
8.3.30.0100.00718.71
8.3.20.0110.00720.16
8.3.10.0040.00423.70
8.3.00.0050.00319.25
8.2.190.0160.00016.63
8.2.180.0070.00716.63
8.2.170.0120.00322.96
8.2.160.0070.01020.35
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0040.00417.38
8.2.120.0050.00326.35
8.2.110.0040.00420.39
8.2.100.0100.00017.91
8.2.90.0050.00319.13
8.2.80.0040.00417.97
8.2.70.0040.00417.36
8.2.60.0070.00417.68
8.2.50.0030.00518.07
8.2.40.0000.00719.31
8.2.30.0040.00420.50
8.2.20.0060.00317.54
8.2.10.0080.00017.96
8.2.00.0040.00418.02
8.1.280.0170.00325.92
8.1.270.0110.00023.77
8.1.260.0030.00628.09
8.1.250.0050.00228.09
8.1.240.0080.00022.14
8.1.230.0060.00617.66
8.1.220.0040.00417.74
8.1.210.0040.00418.77
8.1.200.0040.00417.22
8.1.190.0040.00417.00
8.1.180.0040.00418.10
8.1.170.0030.00620.25
8.1.160.0070.00022.00
8.1.150.0070.00018.86
8.1.140.0090.00019.51
8.1.130.0030.00317.74
8.1.120.0000.00717.36
8.1.110.0000.00717.36
8.1.100.0030.00517.42
8.1.90.0000.00817.27
8.1.80.0040.00417.39
8.1.70.0030.00317.32
8.1.60.0080.00017.39
8.1.50.0000.00817.46
8.1.40.0040.00417.42
8.1.30.0090.00017.57
8.1.20.0040.00417.44
8.1.10.0040.00417.26
8.1.00.0040.00417.31
8.0.300.0040.00418.77
8.0.290.0040.00416.75
8.0.280.0040.00418.38
8.0.270.0000.00717.13
8.0.260.0000.00617.20
8.0.250.0000.00716.95
8.0.240.0040.00416.91
8.0.230.0040.00416.97
8.0.220.0020.00516.91
8.0.210.0000.00816.79
8.0.200.0000.00616.88
8.0.190.0000.00816.98
8.0.180.0030.00716.91
8.0.170.0050.00316.89
8.0.160.0000.00716.93
8.0.150.0040.00416.69
8.0.140.0050.00316.82
8.0.130.0050.00013.28
8.0.120.0000.00816.77
8.0.110.0000.00716.86
8.0.100.0060.00316.66
8.0.90.0000.00716.79
8.0.80.0000.01716.85
8.0.70.0040.00416.93
8.0.60.0050.00216.78
8.0.50.0070.00016.90
8.0.30.0100.00817.09
8.0.20.0120.00717.40
8.0.10.0040.00416.88
8.0.00.0080.01116.70
7.4.330.0030.00315.08
7.4.320.0030.00316.48
7.4.300.0070.00016.32
7.4.290.0000.00616.43
7.4.280.0000.00816.43
7.4.270.0000.00716.36
7.4.260.0070.00016.42
7.4.250.0070.00016.30
7.4.240.0020.00516.40
7.4.230.0030.00316.42
7.4.220.0070.01516.61
7.4.210.0090.00616.48
7.4.200.0060.00316.53
7.4.160.0030.01216.29
7.4.150.0100.01017.40
7.4.140.0100.00917.86
7.4.130.0090.01116.41
7.4.120.0050.01316.39
7.4.110.0090.00916.28
7.4.100.0040.01916.40
7.4.90.0170.00716.48
7.4.80.0110.00519.39
7.4.70.0120.00616.52
7.4.60.0100.00616.58
7.4.50.0060.01116.30
7.4.40.0060.00916.69
7.4.30.0070.01016.73
7.4.10.0030.01414.80
7.4.00.0080.01115.05
7.3.330.0070.00013.25
7.3.320.0060.00013.09
7.3.310.0030.00316.28
7.3.300.0000.00716.10
7.3.290.0080.00616.24
7.3.280.0130.00416.24
7.3.270.0040.01317.40
7.3.260.0100.00716.18
7.3.250.0060.01316.45
7.3.240.0060.01016.28
7.3.230.0090.00916.57
7.3.210.0030.01416.17
7.3.200.0040.01816.34
7.3.190.0080.01016.55
7.3.180.0120.00416.30
7.3.170.0190.00316.45
7.3.160.0110.00516.24
7.3.130.0100.01014.96
7.3.120.0070.00714.81
7.3.110.0100.01014.86
7.3.100.0060.01214.90
7.3.90.0000.01014.93
7.3.80.0030.01314.84
7.3.70.0000.01714.85
7.3.60.0120.00314.82
7.3.50.0130.00614.57
7.3.40.0040.00814.60
7.3.30.0060.00614.67
7.3.20.0130.00316.70
7.3.10.0030.01316.57
7.3.00.0060.00316.70
7.2.330.0130.00316.55
7.2.320.0130.01016.52
7.2.310.0070.01016.67
7.2.300.0110.00616.56
7.2.290.0100.01316.49
7.2.260.0110.00714.99
7.2.250.0110.00714.65
7.2.240.0060.00914.99
7.2.230.0070.01014.87
7.2.220.0040.01214.75
7.2.210.0030.01014.49
7.2.200.0120.00314.81
7.2.190.0030.01615.03
7.2.180.0000.01814.47
7.2.170.0060.00915.07
7.2.160.0000.01414.57
7.2.150.0030.01316.82
7.2.140.0060.00916.75
7.2.130.0060.01016.56
7.2.120.0030.00916.82
7.2.110.0110.00416.81
7.2.100.0060.00916.79
7.2.90.0070.01016.81
7.2.80.0000.01416.73
7.2.70.0000.01416.79
7.2.60.0020.01116.48
7.2.50.0060.01016.84
7.2.40.0030.01016.76
7.2.30.0100.00316.86
7.2.20.0060.01216.60
7.2.10.0000.01416.94
7.2.00.0020.01217.87
7.1.330.0030.00515.86
7.1.320.0070.01015.76
7.1.310.0000.01115.81
7.1.300.0090.00915.48
7.1.290.0040.00815.64
7.1.280.0030.00515.71
7.1.270.0070.01115.71
7.1.260.0070.00715.63
7.1.250.0100.00315.72
7.1.240.0040.01115.74
7.1.230.0080.00815.73
7.1.220.0060.00315.57
7.1.210.0030.00815.57
7.1.200.0030.01215.57
7.1.190.0090.00315.47
7.1.180.0000.01215.79
7.1.170.0070.00715.49
7.1.160.0000.01215.44
7.1.150.0030.00615.79
7.1.140.0030.01015.74
7.1.130.0000.01415.80
7.1.120.0030.00715.83
7.1.110.0110.00315.65
7.1.100.0060.00616.39
7.1.90.0040.00815.43
7.1.80.0000.01715.63
7.1.70.0030.00616.28
7.1.60.0120.00617.65
7.1.50.0150.00116.17
7.1.40.0120.00315.36
7.1.30.0090.00615.68
7.1.20.0040.00615.64
7.1.10.0000.01515.60
7.1.00.0050.04219.02
7.0.330.0030.01315.20
7.0.320.0040.00415.24
7.0.310.0000.01215.19
7.0.300.0000.00915.13
7.0.290.0050.00315.15
7.0.280.0000.00915.15
7.0.270.0030.00915.45
7.0.260.0000.01215.30
7.0.250.0060.00915.52
7.0.240.0030.00915.29
7.0.230.0070.00715.29
7.0.220.0120.00015.28
7.0.210.0000.00915.42
7.0.200.0120.00915.00
7.0.190.0070.00315.34
7.0.180.0100.00615.05
7.0.170.0090.00615.34
7.0.160.0040.00715.31
7.0.150.0040.00814.95
7.0.140.0030.00714.94
7.0.130.0060.00915.34
7.0.120.0030.01415.17
7.0.110.0000.01215.35
7.0.100.0040.00715.35
7.0.90.0090.00315.37
7.0.80.0060.00815.46
7.0.70.0030.00715.12
7.0.60.0120.03517.64
7.0.50.0050.04016.57
7.0.40.0100.02916.59
7.0.30.0080.04916.76
7.0.20.0170.02316.69
7.0.10.0070.04716.82
7.0.00.0030.02516.81
5.6.400.0060.00314.10
5.6.390.0060.00814.25
5.6.380.0000.01014.03
5.6.370.0090.00314.06
5.6.360.0050.00514.08
5.6.350.0000.01213.80
5.6.340.0030.00614.43
5.6.330.0110.00014.23
5.6.320.0060.00614.27
5.6.310.0040.00714.06
5.6.300.0170.00014.23
5.6.290.0090.00614.12
5.6.280.0030.02317.72
5.6.270.0030.01314.08
5.6.260.0000.00914.40
5.6.250.0070.01014.10
5.6.240.0030.01614.00
5.6.230.0030.01014.11
5.6.220.0060.00314.00
5.6.210.0090.02617.46
5.6.200.0050.02216.10
5.6.190.0040.02717.24
5.6.180.0220.03817.40
5.6.170.0150.03017.36
5.6.160.0050.04517.23
5.6.150.0100.03916.33
5.6.140.0070.04016.20
5.6.130.0050.02516.20
5.6.120.0020.02917.62
5.6.110.0080.04017.58
5.6.100.0070.04017.72
5.6.90.0100.03717.66
5.6.80.0020.03617.20
5.6.70.0070.00713.84
5.6.60.0030.00713.92
5.6.50.0070.00713.90
5.6.40.0000.01313.82
5.6.30.0100.00713.90
5.6.20.0070.01014.00
5.6.10.0070.01114.17
5.6.00.0100.00314.10
5.5.380.0070.00713.84
5.5.370.0070.01113.98
5.5.360.0060.00614.02
5.5.350.0200.03717.18
5.5.340.0070.02216.04
5.5.330.0040.02717.05
5.5.320.0060.03017.10
5.5.310.0150.03617.22
5.5.300.0080.03515.93
5.5.290.0030.04116.07
5.5.280.0130.03817.61
5.5.270.0040.02817.40
5.5.260.0020.04517.45
5.5.250.0050.04817.15
5.5.240.0130.04317.09
5.5.230.0060.00913.91
5.5.220.0060.00813.83
5.5.210.0030.00814.13
5.5.200.0000.01213.94
5.5.190.0030.01413.60
5.5.180.0060.00813.75
5.5.170.0030.01313.69
5.5.160.0030.00614.12
5.5.150.0070.00413.80
5.5.140.0060.00314.04
5.5.130.0000.01114.02
5.5.120.0060.00913.76
5.5.110.0000.00913.89
5.5.100.0030.01214.11
5.5.90.0000.01414.04
5.5.80.0110.00414.05
5.5.70.0030.01013.70
5.5.60.0040.01113.92
5.5.50.0000.00913.96
5.5.40.0040.01013.40
5.5.30.0120.00613.75
5.5.20.0030.01013.91
5.5.10.0040.01113.74
5.5.00.0000.01313.46

preferences:
51.55 ms | 401 KiB | 5 Q