3v4l.org

run code in 300+ PHP versions simultaneously
<?php interface VisitorInterface { } interface SerializeVisitorInterface extends VisitorInterface { public function visitSomething(); } class SerializeVisitor implements SerializeVisitorInterface { public function visitSomething() { echo 'Hi something'; } } class BaseEvent { protected $visitor; public function getVisitor(): VisitorInterface { return $this->visitor; } } class SerializeEvent extends BaseEvent { public function __construct() { $this->visitor = new SerializeVisitor(); } public function getVisitor(): SerializeVisitorInterface { return $this->visitor; } } $event = new SerializeEvent(); $event->getVisitor()->visitSomething();

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.110.0080.00018.46
8.3.100.0030.00516.85
8.3.90.0160.00626.77
8.3.80.0000.01116.63
8.3.70.0150.00018.56
8.3.60.0120.00318.31
8.3.50.0090.00923.72
8.3.40.0160.00018.71
8.3.30.0000.01418.55
8.3.20.0000.00720.87
8.3.10.0060.00323.50
8.3.00.0040.00419.68
8.2.230.0070.00320.94
8.2.220.0080.00024.06
8.2.210.0070.00026.77
8.2.200.0090.00016.50
8.2.190.0070.01416.63
8.2.180.0180.00418.16
8.2.170.0070.01122.96
8.2.160.0090.00622.26
8.2.150.0030.00624.18
8.2.140.0040.00424.66
8.2.130.0000.00726.16
8.2.120.0050.00326.16
8.2.110.0060.00322.20
8.2.100.0060.00617.78
8.2.90.0040.00417.75
8.2.80.0000.00818.75
8.2.70.0040.00417.63
8.2.60.0040.00417.75
8.2.50.0040.00417.63
8.2.40.0040.00417.80
8.2.30.0040.00419.54
8.2.20.0050.00218.04
8.2.10.0070.00019.33
8.2.00.0030.00519.11
8.1.290.0030.00630.84
8.1.280.0070.00725.92
8.1.270.0050.00320.68
8.1.260.0050.00326.35
8.1.250.0000.00728.09
8.1.240.0060.00323.97
8.1.230.0040.00822.74
8.1.220.0060.00317.74
8.1.210.0050.00318.77
8.1.200.0040.00417.35
8.1.190.0030.01117.38
8.1.180.0040.00418.10
8.1.170.0040.00417.62
8.1.160.0040.00419.01
8.1.150.0040.00418.82
8.1.140.0050.00218.83
8.1.130.0000.00722.09
8.1.120.0000.00817.46
8.1.110.0070.00317.36
8.1.100.0040.00417.34
8.1.90.0050.00217.39
8.1.80.0000.00817.45
8.1.70.0040.00417.33
8.1.60.0000.01017.62
8.1.50.0000.00817.42
8.1.40.0000.00817.41
8.1.30.0000.00917.54
8.1.20.0000.00717.64
8.1.10.0040.00417.60
8.1.00.0040.00417.49
8.0.300.0040.00418.77
8.0.290.0040.00816.75
8.0.280.0030.00318.56
8.0.270.0000.00718.06
8.0.260.0030.00319.96
8.0.250.0030.00316.97
8.0.240.0050.00316.95
8.0.230.0030.00316.93
8.0.220.0040.00416.91
8.0.210.0040.00416.88
8.0.200.0070.00016.96
8.0.190.0000.00716.82
8.0.180.0040.00416.88
8.0.170.0060.00316.79
8.0.160.0000.00816.87
8.0.150.0040.00416.76
8.0.140.0030.00516.79
8.0.130.0000.00613.30
8.0.120.0000.00816.90
8.0.110.0060.00316.75
8.0.100.0040.00416.93
8.0.90.0040.00416.92
8.0.80.0090.00816.81
8.0.70.0040.00416.74
8.0.60.0090.00016.95
8.0.50.0040.00416.96
8.0.30.0030.01316.95
8.0.20.0100.00917.17
8.0.10.0050.00316.82
8.0.00.0120.00616.70
7.4.330.0000.00615.55
7.4.320.0030.00316.63
7.4.300.0000.00616.59
7.4.290.0040.00416.60
7.4.280.0030.00516.49
7.4.270.0000.00816.61
7.4.260.0050.00013.34
7.4.250.0040.00416.45
7.4.240.0040.00316.50
7.4.230.0080.00016.50
7.4.220.0050.00216.63
7.4.210.0060.00916.46
7.4.200.0040.00416.64
7.4.130.0120.00916.65
7.4.120.0100.00616.57
7.4.110.0110.00716.58
7.4.100.0100.01016.49
7.4.90.0160.02316.57
7.4.80.0110.01119.39
7.4.70.0130.00916.33
7.4.60.0100.01016.62
7.4.50.0000.01516.61
7.4.40.0030.01316.47
7.4.20.0030.01216.60
7.4.10.0090.00616.28
7.4.00.0170.00016.40
7.3.330.0000.00716.15
7.3.320.0000.00513.23
7.3.310.0030.00316.35
7.3.300.0000.00716.24
7.3.290.0080.00716.18
7.3.260.0120.00616.24
7.3.240.0090.01016.28
7.3.230.0090.00916.20
7.3.210.0100.00616.41
7.3.200.0160.00316.52
7.3.190.0080.01216.25
7.3.180.0070.00716.41
7.3.170.0100.00716.51
7.3.160.0090.01316.46
7.3.140.0090.00616.30
7.3.130.0060.00916.18
7.3.120.0000.01616.41
7.3.110.0120.00316.45
7.3.100.0000.01616.18
7.3.90.0060.00916.30
7.3.80.0120.00916.05
7.3.70.0080.01216.09
7.3.60.0170.00416.23
7.3.50.0080.00816.20
7.3.40.0120.00316.19
7.3.30.0120.00416.20
7.3.20.0100.00716.02
7.3.10.0120.00616.32
7.3.00.0250.00716.34
7.2.330.0100.01316.29
7.2.320.0130.01016.20
7.2.310.0120.00916.30
7.2.300.0030.01416.49
7.2.290.0150.00316.42
7.2.270.0140.00816.32
7.2.260.0090.00916.34
7.2.250.0030.01316.20
7.2.240.0100.00716.52
7.2.230.0130.00516.26
7.2.220.0130.00616.44
7.2.210.0150.00616.26
7.2.200.0100.01116.47
7.2.190.0140.00416.27
7.2.180.0160.00016.17
7.2.170.0090.00616.22
7.2.160.0090.00616.15
7.2.150.0070.01016.33
7.2.140.0110.00616.43
7.2.130.0060.01616.29
7.2.120.0050.01116.27
7.2.110.0080.00816.19
7.2.100.0060.01016.34
7.2.90.0090.00716.31
7.2.80.0100.00716.43
7.2.70.0030.01416.21
7.2.60.0080.00816.38
7.2.50.0050.01116.55
7.2.40.0110.00516.34
7.2.30.0160.00016.25
7.2.20.0100.00716.23
7.2.10.0100.00616.27
7.2.00.0040.01216.43

preferences:
29.4 ms | 403 KiB | 5 Q