3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Value { protected $value; public function __construct($value) { $this->value = $value; } public function getValue() { return $this->value; } } $three = new Value(3); $four = new Value(4); $closure = function ($delta) { var_dump(0 + $delta); var_dump($delta); }; //$a = new closure(); $closure(4); $closure->call($three, 4, 3, 5); $closure->call($four, 4, 2 , 1); ?>

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.0150.00318.30
8.3.60.0090.00616.50
8.3.50.0080.01121.94
8.3.40.0140.00718.78
8.3.30.0110.00718.85
8.3.20.0040.00420.16
8.3.10.0030.00520.36
8.3.00.0070.00423.45
8.2.180.0110.00316.63
8.2.170.0070.00722.96
8.2.160.0030.01019.47
8.2.150.0070.00024.18
8.2.140.0050.00224.66
8.2.130.0040.00420.75
8.2.120.0040.00426.35
8.2.110.0030.00720.89
8.2.100.0080.00418.03
8.2.90.0080.00019.22
8.2.80.0000.00817.97
8.2.70.0000.01017.50
8.2.60.0050.00317.91
8.2.50.0060.00318.09
8.2.40.0040.00422.11
8.2.30.0040.00419.42
8.2.20.0000.00717.75
8.2.10.0040.00418.00
8.2.00.0040.00418.02
8.1.280.0100.01025.92
8.1.270.0060.01322.11
8.1.260.0140.00028.09
8.1.250.0000.00728.09
8.1.240.0060.00323.79
8.1.230.0100.00317.49
8.1.220.0040.00417.74
8.1.210.0000.00818.77
8.1.200.0060.00317.48
8.1.190.0000.00817.13
8.1.180.0000.00818.10
8.1.170.0000.00818.59
8.1.160.0050.00320.77
8.1.150.0110.00020.67
8.1.140.0000.00819.54
8.1.130.0020.00517.68
8.1.120.0040.00317.37
8.1.110.0040.00417.39
8.1.100.0000.00817.46
8.1.90.0040.00417.38
8.1.80.0040.00417.37
8.1.70.0030.00317.42
8.1.60.0000.00717.57
8.1.50.0000.00817.45
8.1.40.0040.00417.41
8.1.30.0050.00217.57
8.1.20.0030.00517.52
8.1.10.0050.00317.54
8.1.00.0040.00417.33
8.0.300.0040.00418.77
8.0.290.0030.00616.63
8.0.280.0040.00418.39
8.0.270.0030.00317.12
8.0.260.0000.00817.19
8.0.250.0000.00616.88
8.0.240.0060.00016.80
8.0.230.0000.00716.96
8.0.220.0070.00016.89
8.0.210.0000.00816.76
8.0.200.0000.00716.88
8.0.190.0000.00716.85
8.0.180.0040.00416.93
8.0.170.0000.00716.83
8.0.160.0040.00416.87
8.0.150.0070.00016.80
8.0.140.0050.00516.84
8.0.130.0030.00313.32
8.0.120.0050.00216.86
8.0.110.0050.00216.89
8.0.100.0070.00016.95
8.0.90.0050.00216.95
8.0.80.0110.00616.95
8.0.70.0000.00716.79
8.0.60.0000.00717.01
8.0.50.0050.00216.75
8.0.30.0060.01316.92
8.0.20.0120.00817.40
8.0.10.0040.00417.06
8.0.00.0140.00316.82
7.4.330.0000.00516.72
7.4.320.0000.00816.52
7.4.300.0000.00716.51
7.4.290.0000.00716.61
7.4.280.0040.00416.62
7.4.270.0030.00316.49
7.4.260.0030.00516.48
7.4.250.0040.00416.61
7.4.240.0040.00416.62
7.4.230.0030.00316.71
7.4.220.0170.00016.58
7.4.210.0080.00816.58
7.4.200.0000.00716.66
7.4.160.0090.00916.55
7.4.150.0120.00617.40
7.4.140.0120.00617.86
7.4.130.0090.00816.55
7.4.120.0120.00516.62
7.4.110.0140.00516.56
7.4.100.0050.01516.32
7.4.90.0070.01116.46
7.4.80.0030.01419.39
7.4.70.0120.00816.45
7.4.60.0160.00316.47
7.4.50.0090.00316.25
7.4.40.0110.00616.35
7.4.30.0190.00316.61
7.4.00.0140.00314.83
7.3.330.0030.00313.27
7.3.320.0050.00013.29
7.3.310.0000.00716.30
7.3.300.0030.00316.25
7.3.290.0070.00016.32
7.3.280.0120.00716.29
7.3.270.0040.01417.40
7.3.260.0070.01416.20
7.3.250.0090.01116.49
7.3.240.0050.01316.34
7.3.230.0060.01516.39
7.3.210.0060.01216.19
7.3.200.0070.01019.39
7.3.190.0100.00716.55
7.3.180.0150.00616.63
7.3.170.0180.00016.37
7.3.160.0060.01016.25
7.3.120.0080.00914.87
7.3.110.0080.00914.81
7.3.100.0070.00814.72
7.3.90.0060.00714.80
7.3.80.0050.01314.93
7.3.70.0060.00914.65
7.3.60.0040.00914.68
7.3.50.0000.01314.71
7.3.40.0060.00914.59
7.3.30.0040.00914.84
7.3.20.0070.00816.43
7.3.10.0080.00416.46
7.3.00.0040.00816.71
7.2.330.0090.00916.78
7.2.320.0060.01216.59
7.2.310.0050.01516.42
7.2.300.0090.01116.35
7.2.290.0030.01316.70
7.2.250.0060.01314.87
7.2.240.0130.00515.03
7.2.230.0060.00815.05
7.2.220.0060.00815.14
7.2.210.0050.01014.81
7.2.200.0050.00815.17
7.2.190.0080.00614.99
7.2.180.0050.01115.01
7.2.170.0070.00614.98
7.2.60.0040.00816.89
7.2.00.0060.00619.46
7.1.330.0050.01015.67
7.1.320.0050.00715.74
7.1.310.0060.00715.73
7.1.300.0020.01115.59
7.1.290.0050.00815.58
7.1.280.0040.01015.71
7.1.270.0030.01115.55
7.1.260.0030.01115.74
7.1.200.0090.00315.79
7.1.100.0000.01018.13
7.1.70.0050.00217.20
7.1.60.0120.01219.40
7.1.50.0110.01116.61
7.1.00.0030.07722.34
7.0.200.0420.00614.72
7.0.60.0200.08021.83
7.0.50.0170.06017.88
7.0.40.0070.07320.11
7.0.30.0370.07020.18
7.0.20.0070.05020.21
7.0.10.0130.08320.30
7.0.00.0100.08020.14
5.6.280.0030.07021.11
5.6.210.0100.07720.47
5.6.200.0070.08018.20
5.6.190.0100.04020.41
5.6.180.0300.07320.34
5.6.170.0270.06320.71
5.6.160.0000.05320.48
5.6.150.0070.08018.18
5.6.140.0000.08718.15
5.6.130.0130.07318.16
5.6.120.0130.06721.02
5.6.110.0100.06021.01
5.6.100.0100.05721.12
5.6.90.0000.07020.97
5.6.80.0000.04320.51
5.5.350.0270.05320.34
5.5.340.0100.08317.96
5.5.330.0000.05720.30
5.5.320.0430.05020.25
5.5.310.0200.07720.28
5.5.300.0130.06718.06
5.5.290.0070.07318.10
5.5.280.0070.05320.80
5.5.270.0130.06720.68
5.5.260.0100.08020.77
5.5.250.0100.07020.59
5.5.240.0230.08320.25

preferences:
48.84 ms | 401 KiB | 5 Q