3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface ContainerInterface1 { public function get($id); } interface ContainerInterface2 { public function get($id, $params = [], $setters = [], $shared = true); } class Container implements ContainerInterface1, ContainerInterface2 { public function get($id, $params = [], $setters = [], $shared = true) { return $id; } } class Y { public function setContainer(ContainerInterface1 $value) { $this->value = $value; } } $container = new Container(); var_dump($container instanceof ContainerInterface1); var_dump($container instanceof ContainerInterface2); echo $container->get('hello'); $y = new Y(); $y->setContainer($container);

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.5.30.0100.00719.94
8.5.20.0050.01220.10
8.5.10.0130.00320.13
8.5.00.0140.01020.00
8.4.180.0180.00619.77
8.4.170.0120.01023.61
8.4.160.0150.00923.81
8.4.150.0030.00014.05
8.4.140.0150.01117.72
8.4.130.0130.00718.08
8.4.120.0110.00820.29
8.4.110.0130.00822.23
8.4.100.0100.00717.94
8.4.90.0090.01218.44
8.4.80.0080.01218.65
8.4.70.0060.00419.15
8.4.60.0100.00718.97
8.4.50.0050.00420.72
8.4.40.0130.00619.68
8.4.30.0130.00619.61
8.4.20.0170.00317.74
8.4.10.0090.00019.40
8.3.300.0130.00920.93
8.3.290.0150.00620.95
8.3.280.0070.01318.42
8.3.270.0120.00816.50
8.3.260.0070.01316.79
8.3.250.0130.00618.78
8.3.240.0170.00616.73
8.3.230.0140.00816.82
8.3.220.0110.00818.79
8.3.210.0060.00216.86
8.3.200.0040.00516.68
8.3.190.0120.00717.35
8.3.180.0050.00318.98
8.3.170.0000.01018.99
8.3.160.0030.00516.98
8.3.150.0090.00916.46
8.3.140.0070.00718.96
8.3.130.0090.00018.71
8.3.120.0100.00019.08
8.3.110.0060.00320.94
8.3.100.0030.00724.06
8.3.90.0060.00326.77
8.3.80.0060.00618.50
8.3.70.0130.00716.50
8.3.60.0070.00718.55
8.3.50.0090.00922.05
8.3.40.0070.01118.76
8.3.30.0090.00618.83
8.3.20.0040.00418.67
8.3.10.0000.00721.73
8.3.00.0080.00021.56
8.2.300.0130.01218.29
8.2.290.0110.00820.25
8.2.280.0100.00422.30
8.2.270.0040.01416.51
8.2.260.0090.00616.61
8.2.250.0070.00716.67
8.2.240.0060.00317.32
8.2.230.0060.00322.58
8.2.220.0030.00637.54
8.2.210.0160.00326.77
8.2.200.0070.00318.41
8.2.190.0040.01216.58
8.2.180.0120.00316.88
8.2.170.0150.00022.96
8.2.160.0070.00722.13
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0000.00819.73
8.2.120.0040.00426.35
8.2.110.0100.00020.40
8.2.100.0080.00417.91
8.2.90.0040.00419.08
8.2.80.0050.00217.97
8.2.70.0050.00317.50
8.2.60.0070.00317.80
8.2.50.0040.00418.10
8.2.40.0000.00720.37
8.2.30.0050.00219.23
8.2.20.0030.00618.02
8.2.10.0000.00817.95
8.2.00.0040.00417.70
8.1.340.0100.00917.52
8.1.330.0020.00621.95
8.1.320.0050.00317.85
8.1.310.0120.00616.49
8.1.300.0090.00016.41
8.1.290.0040.00430.84
8.1.280.0100.01025.92
8.1.270.0040.00421.93
8.1.260.0040.00428.09
8.1.250.0040.00428.09
8.1.240.0040.00422.23
8.1.230.0080.00422.25
8.1.220.0030.00517.74
8.1.210.0050.00318.77
8.1.200.0000.00917.35
8.1.190.0040.00419.13
8.1.180.0040.00418.10
8.1.170.0030.00518.70
8.1.160.0030.00522.02
8.1.150.0070.00020.20
8.1.140.0000.00719.47
8.1.130.0070.00017.60
8.1.120.0050.00317.53
8.1.110.0030.00517.47
8.1.100.0040.00417.38
8.1.90.0040.00417.37
8.1.80.0050.00317.48
8.1.70.0000.00717.44
8.1.60.0080.00417.65
8.1.50.0000.00817.56
8.1.40.0030.00517.55
8.1.30.0040.00417.53
8.1.20.0000.00817.57
8.1.10.0000.00717.45
8.1.00.0000.00917.46
8.0.300.0000.00818.77
8.0.290.0000.00816.75
8.0.280.0000.00718.38
8.0.270.0050.00317.29
8.0.260.0000.00917.32
8.0.250.0000.00717.09
8.0.240.0040.00417.02
8.0.230.0030.00316.95
8.0.220.0030.00316.91
8.0.210.0070.00017.01
8.0.200.0000.00617.07
8.0.190.0070.00016.93
8.0.180.0040.00416.93
8.0.170.0000.00716.84
8.0.160.0070.00017.11
8.0.150.0000.00816.98
8.0.140.0070.00016.97
8.0.130.0000.00713.40
8.0.120.0040.00416.91
8.0.110.0000.00717.02
8.0.100.0000.00816.75
8.0.90.0080.00016.84
8.0.80.0090.00616.93
8.0.70.0060.00316.99
8.0.60.0000.00817.01
8.0.50.0000.00816.98
8.0.30.0090.00917.13
8.0.20.0130.00717.40
8.0.10.0040.00416.97
8.0.00.0090.00916.79
7.4.330.0050.00015.55
7.4.320.0000.00716.53
7.4.300.0070.00016.53
7.4.290.0000.00716.52
7.4.280.0070.00016.55
7.4.270.0070.00016.59
7.4.260.0040.00416.58
7.4.250.0070.00316.60
7.4.240.0050.00216.54
7.4.230.0030.00316.47
7.4.220.0030.00316.60
7.4.210.0080.00816.56
7.4.200.0070.00016.72
7.4.160.0100.00616.54
7.4.150.0140.00417.40
7.4.140.0100.00817.86
7.4.130.0090.00816.52
7.4.120.0120.00416.60
7.4.110.0180.00316.56
7.4.100.0090.00916.68
7.4.90.0090.00916.45
7.4.80.0070.01019.39
7.4.70.0120.00416.46
7.4.60.0130.00416.38
7.4.50.0030.01016.43
7.4.40.0170.00016.44
7.4.30.0140.00316.43
7.4.00.0100.00614.75
7.3.330.0000.00613.25
7.3.320.0000.00513.30
7.3.310.0030.00316.24
7.3.300.0000.00716.30
7.3.290.0090.00716.24
7.3.280.0070.01016.29
7.3.270.0120.01217.40
7.3.260.0100.00816.51
7.3.250.0100.00916.31
7.3.240.0030.01316.46
7.3.230.0090.00916.58
7.3.210.0120.00416.32
7.3.200.0060.01216.39
7.3.190.0060.01716.32
7.3.180.0110.00516.40
7.3.170.0100.00716.24
7.3.160.0120.00616.32
7.2.330.0100.01016.54
7.2.320.0060.01116.81
7.2.310.0100.00616.61
7.2.300.0150.00916.61
7.2.290.0040.01216.69
7.2.00.0040.00819.41
7.1.70.0030.00717.13
7.1.60.0030.01016.90
7.1.00.0070.07322.44
7.0.200.0130.00614.57
7.0.120.0030.05722.00
7.0.110.0170.04722.07
7.0.100.0030.05722.13
7.0.90.0000.06322.06
7.0.80.0100.05322.04
7.0.70.0100.06022.02
7.0.60.0170.04722.08
7.0.50.0000.06722.07
7.0.40.0070.05722.13
7.0.30.0100.05322.06
7.0.20.0100.05322.11
7.0.10.0030.06022.07
7.0.00.0100.05322.07
5.6.270.0100.06321.08
5.6.260.0130.05021.00
5.6.250.0100.05020.89
5.6.240.0000.06321.01
5.6.230.0070.05720.94
5.6.220.0070.06020.87
5.6.210.0070.06020.90
5.6.200.0030.06320.82
5.6.190.0070.06020.86
5.6.180.0030.07721.02
5.6.170.0030.06020.86
5.6.160.0070.06020.94
5.6.150.0070.07721.00
5.6.140.0100.07321.01
5.6.130.0070.06020.93
5.6.120.0130.06321.05
5.6.110.0100.07021.01
5.6.100.0100.05720.92
5.6.90.0100.05321.01
5.6.80.0070.07020.23
5.6.70.0030.06020.23
5.6.60.0070.06320.42
5.6.50.0000.05720.23
5.6.40.0030.05320.22
5.6.30.0030.06020.38
5.6.20.0100.05720.38
5.6.10.0070.05020.38
5.6.00.0070.05720.21

preferences:
193.26 ms | 403 KiB | 5 Q