3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public $stage; public function __construct($stage) { $this->stage = $stage; } public function __toString() { return $this->stage.''; } } $array['test'] = function ($i) {return new Test($i);}; echo $array['test']('2');

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.00316.50
8.3.50.0120.00316.61
8.3.40.0140.00018.83
8.3.30.0070.00718.84
8.3.20.0070.00020.20
8.3.10.0040.00421.79
8.3.00.0050.00317.72
8.2.180.0090.00618.41
8.2.170.0130.00622.96
8.2.160.0100.00320.39
8.2.150.0080.00024.18
8.2.140.0140.00024.66
8.2.130.0030.00820.53
8.2.120.0050.00326.35
8.2.110.0030.00719.21
8.2.100.0040.00817.84
8.2.90.0040.00419.34
8.2.80.0040.00418.03
8.2.70.0030.00717.63
8.2.60.0000.00917.93
8.2.50.0040.00418.10
8.2.40.0040.00422.20
8.2.30.0000.00921.07
8.2.20.0070.00018.05
8.2.10.0030.00518.16
8.2.00.0000.00718.13
8.1.280.0040.01525.92
8.1.270.0000.00822.17
8.1.260.0000.00726.35
8.1.250.0000.00928.09
8.1.240.0060.00321.37
8.1.230.0100.00317.52
8.1.220.0000.00817.74
8.1.210.0030.00518.77
8.1.200.0060.00317.38
8.1.190.0030.00517.23
8.1.180.0030.00718.10
8.1.170.0000.00818.64
8.1.160.0070.00018.97
8.1.150.0000.00820.52
8.1.140.0050.00319.57
8.1.130.0030.00518.71
8.1.120.0030.00317.39
8.1.110.0040.00417.45
8.1.100.0030.00517.35
8.1.90.0050.00317.45
8.1.80.0000.00817.48
8.1.70.0030.00317.49
8.1.60.0060.00317.60
8.1.50.0080.00017.56
8.1.40.0000.00817.54
8.1.30.0030.00617.63
8.1.20.0000.01017.70
8.1.10.0030.00617.49
8.1.00.0000.00917.45
8.0.300.0080.00418.77
8.0.290.0040.00416.75
8.0.280.0030.00318.40
8.0.270.0030.00317.32
8.0.260.0060.00016.91
8.0.250.0000.00817.03
8.0.240.0030.00516.80
8.0.230.0080.00016.96
8.0.220.0000.00716.78
8.0.210.0000.00716.91
8.0.200.0000.00716.97
8.0.190.0060.00316.85
8.0.180.0000.00716.93
8.0.170.0000.00816.92
8.0.160.0070.00016.89
8.0.150.0070.00016.94
8.0.140.0040.00416.77
8.0.130.0000.00513.29
8.0.120.0000.00716.88
8.0.110.0030.00316.87
8.0.100.0000.00716.95
8.0.90.0070.00016.88
8.0.80.0130.01216.88
8.0.70.0030.00516.90
8.0.60.0070.00016.96
8.0.50.0050.00316.90
8.0.30.0040.01317.26
8.0.20.0100.01117.40
8.0.10.0040.00417.09
8.0.00.0110.00716.83
7.4.330.0000.00515.55
7.4.320.0000.00716.43
7.4.300.0060.00016.57
7.4.290.0030.00316.50
7.4.280.0040.00416.58
7.4.270.0040.00416.53
7.4.260.0040.00416.39
7.4.250.0070.00016.59
7.4.240.0040.00416.50
7.4.230.0000.00716.48
7.4.220.0060.01216.53
7.4.210.0090.00616.52
7.4.200.0080.00016.51
7.4.160.0100.00816.53
7.4.150.0120.00617.40
7.4.140.0080.01217.86
7.4.130.0130.00416.54
7.4.120.0100.01116.53
7.4.110.0130.01016.32
7.4.100.0080.01516.44
7.4.90.0110.00916.48
7.4.80.0150.00819.39
7.4.70.0060.00916.60
7.4.60.0070.01016.73
7.4.50.0110.00416.46
7.4.40.0080.00816.50
7.4.30.0150.00616.41
7.4.00.0090.00614.91
7.3.330.0030.00213.39
7.3.320.0050.00013.17
7.3.310.0050.00216.18
7.3.300.0060.00016.29
7.3.290.0000.00716.27
7.3.280.0080.00916.31
7.3.270.0090.01217.40
7.3.260.0120.01116.38
7.3.250.0080.01116.49
7.3.240.0150.00616.48
7.3.230.0060.01616.23
7.3.210.0060.01316.31
7.3.200.0040.01116.45
7.3.190.0060.01016.32
7.3.180.0030.01416.32
7.3.170.0110.00716.43
7.3.160.0030.01216.66
7.2.330.0030.01816.63
7.2.320.0100.00716.63
7.2.310.0170.00016.67
7.2.300.0070.01016.67
7.2.290.0090.01016.67
7.2.120.0090.00616.72
7.2.110.0060.00316.51
7.2.100.0050.01016.73
7.2.90.0120.00616.75
7.2.80.0100.00316.53
7.2.70.0120.00216.85
7.2.60.0110.00816.91
7.2.50.0090.00316.79
7.2.40.0060.00316.93
7.2.30.0040.00716.75
7.2.20.0050.00517.02
7.2.10.0000.01116.96
7.2.00.0100.00218.15
7.1.240.0080.00815.85
7.1.230.0080.00415.42
7.1.220.0170.00015.64
7.1.210.0120.00415.93
7.1.200.0100.00715.68
7.1.190.0100.00515.70
7.1.180.0150.00015.95
7.1.170.0060.00615.99
7.1.160.0030.00515.77
7.1.150.0060.00915.85
7.1.140.0030.00715.58
7.1.130.0070.00415.88
7.1.120.0060.00615.93
7.1.110.0050.00315.73
7.1.100.0050.00917.03
7.1.90.0120.00015.91
7.1.80.0040.00415.73
7.1.70.0080.00516.51
7.1.60.0150.00525.48
7.1.50.0110.00825.37
7.1.40.0140.01025.22
7.1.30.0100.01325.19
7.1.20.0140.01025.03
7.1.10.0070.00716.23
7.1.00.0020.01416.15
7.0.320.0130.00315.39
7.0.310.0080.00415.36
7.0.300.0090.00015.36
7.0.290.0040.00415.37
7.0.280.0060.00315.47
7.0.270.0030.00715.45
7.0.260.0100.00015.39
7.0.250.0030.00915.38
7.0.240.0060.00315.64
7.0.230.0030.00715.64
7.0.220.0060.00615.36
7.0.210.0040.00815.45
7.0.200.0030.00716.10
7.0.190.0030.00815.96
7.0.180.0070.00515.88
7.0.170.0060.00816.03
7.0.160.0030.01316.02
7.0.150.0020.01315.82
7.0.140.0090.00715.91
7.0.130.0000.01215.90
7.0.120.0020.00916.15
7.0.110.0040.01015.91
7.0.100.0100.00415.87
7.0.90.0030.01015.91
7.0.80.0060.00815.91
7.0.70.0050.01116.09
7.0.60.0060.00915.72
7.0.50.0000.01115.93
7.0.40.0080.00914.82
7.0.30.0070.00814.95
7.0.20.0020.01014.94
7.0.10.0060.00615.10
7.0.00.0050.00614.89
5.6.380.0060.00914.57

preferences:
54.59 ms | 400 KiB | 5 Q