3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Parcel { protected $weight; protected $destinationCountry; public function setWeight($weight) { echo "the weight is" . $weight; $this->weight = $weight; return $weight; } public function setCountry($destinationCountry) { echo "country is " . $destinationCountry; $this->destinationCountry = $destinationCountry; return $destinationCountry; } }

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.00918.05
8.3.50.0070.00718.17
8.3.40.0070.01018.57
8.3.30.0110.00418.75
8.3.20.0080.00020.20
8.3.10.0030.00521.78
8.3.00.0080.00019.06
8.2.180.0070.01418.29
8.2.170.0100.00722.96
8.2.160.0100.00722.26
8.2.150.0040.01524.18
8.2.140.0070.00724.66
8.2.130.0040.00426.16
8.2.120.0040.00419.54
8.2.110.0090.00022.25
8.2.100.0100.00317.91
8.2.90.0080.00019.09
8.2.80.0040.00417.97
8.2.70.0030.00517.50
8.2.60.0040.00817.68
8.2.50.0000.00918.07
8.2.40.0040.00419.76
8.2.30.0060.00317.88
8.2.20.0070.00017.46
8.2.10.0030.00517.80
8.2.00.0000.00717.57
8.1.280.0140.00325.92
8.1.270.0090.00018.75
8.1.260.0100.00026.35
8.1.250.0050.00328.09
8.1.240.0040.00423.86
8.1.230.0080.00419.16
8.1.220.0000.00817.74
8.1.210.0040.00418.77
8.1.200.0040.00417.10
8.1.190.0040.00417.11
8.1.180.0080.00018.10
8.1.170.0060.00618.51
8.1.160.0030.00621.95
8.1.150.0040.00418.65
8.1.140.0000.00818.98
8.1.130.0080.00017.71
8.1.120.0000.00717.38
8.1.110.0050.00317.35
8.1.100.0030.00517.21
8.1.90.0030.00317.24
8.1.80.0000.00717.33
8.1.70.0050.00317.20
8.1.60.0050.00317.38
8.1.50.0030.00617.45
8.1.40.0040.00417.34
8.1.30.0080.00017.50
8.1.20.0070.00017.52
8.1.10.0000.00717.32
8.1.00.0040.00417.32
8.0.300.0000.00718.77
8.0.290.0000.00716.63
8.0.280.0030.00318.32
8.0.270.0030.00517.13
8.0.260.0040.00417.13
8.0.250.0040.00416.85
8.0.240.0000.00816.80
8.0.230.0000.00716.86
8.0.220.0000.00616.78
8.0.210.0000.00816.64
8.0.200.0020.00516.71
8.0.190.0040.00416.80
8.0.180.0050.00316.74
8.0.170.0030.00516.66
8.0.160.0000.00716.64
8.0.150.0050.00316.80
8.0.140.0000.00916.60
8.0.130.0050.00013.19
8.0.120.0050.00316.68
8.0.110.0000.00716.60
8.0.100.0000.00716.53
8.0.90.0030.00516.70
8.0.80.0110.01116.71
8.0.70.0060.00316.74
8.0.60.0050.00216.66
8.0.50.0000.00816.74
8.0.30.0130.01216.75
8.0.20.0060.01517.40
8.0.10.0040.00416.73
8.0.00.0110.00516.59
7.4.330.0040.00415.03
7.4.320.0060.00016.40
7.4.300.0000.00716.38
7.4.290.0000.00716.47
7.4.280.0070.00016.39
7.4.270.0040.00416.47
7.4.260.0030.00716.47
7.4.250.0030.00316.32
7.4.240.0020.00516.39
7.4.230.0070.00016.48
7.4.220.0130.00416.46
7.4.210.0040.01116.47
7.4.200.0040.00416.56
7.4.160.0090.00616.60
7.4.150.0180.00017.40
7.4.140.0110.00617.86
7.4.130.0060.01016.27
7.4.120.0170.00316.29
7.4.110.0190.00316.35
7.4.100.0090.01516.22
7.4.90.0060.01316.24
7.4.80.0090.01319.39
7.4.70.0080.00816.36
7.4.60.0120.00616.33
7.4.50.0050.00316.21
7.4.40.0170.00016.49
7.4.30.0100.00616.40
7.4.00.0090.00714.85
7.3.330.0050.00013.20
7.3.320.0030.00213.14
7.3.310.0070.00016.20
7.3.300.0000.00616.05
7.3.290.0060.00816.15
7.3.280.0110.00716.15
7.3.270.0100.00617.40
7.3.260.0070.01716.12
7.3.250.0050.01216.27
7.3.240.0100.00716.20
7.3.230.0110.01016.40
7.3.210.0130.00716.25
7.3.200.0000.01619.39
7.3.190.0150.00316.36
7.3.180.0080.00816.42
7.3.170.0100.01016.27
7.3.160.0100.00716.38
7.3.120.0100.00614.92
7.3.110.0090.00914.71
7.3.100.0040.00814.66
7.3.90.0120.00314.94
7.3.80.0070.00714.40
7.3.70.0000.01014.68
7.3.60.0070.00714.77
7.3.50.0050.00514.36
7.3.40.0100.00714.80
7.3.30.0100.00014.66
7.3.20.0070.00716.64
7.3.10.0040.00716.58
7.3.00.0030.01016.64
7.2.330.0060.01216.58
7.2.320.0030.01616.33
7.2.310.0190.00316.48
7.2.300.0030.01416.48
7.2.290.0070.01016.22
7.2.250.0000.01614.87
7.2.240.0070.01314.79
7.2.230.0130.00314.80
7.2.220.0130.00014.88
7.2.210.0060.00914.96
7.2.200.0100.00714.73
7.2.190.0070.01014.45
7.2.180.0030.01415.00
7.2.170.0000.01014.85
7.2.00.0060.00619.13
7.1.330.0030.01015.87
7.1.320.0030.01015.57
7.1.310.0040.00815.35
7.1.300.0110.00615.64
7.1.290.0050.00515.61
7.1.280.0000.01315.80
7.1.270.0070.01115.41
7.1.260.0060.00915.62
7.1.100.0060.00618.09
7.1.70.0030.00516.97
7.1.60.0100.00719.46
7.1.50.0070.01716.88
7.1.00.0070.07322.40
7.0.200.0140.00716.78
7.0.140.0000.05722.22
7.0.60.0000.04319.93
7.0.50.0230.06717.81
7.0.40.0070.08720.11
7.0.30.0200.08720.15
7.0.20.0300.05320.21
7.0.10.0170.07020.19
7.0.00.0100.06720.07
5.6.280.0030.07020.79
5.6.210.0130.06720.70
5.6.200.0100.08318.21
5.6.190.0030.05020.61
5.6.180.0230.04720.46
5.6.170.0270.05720.71
5.6.160.0070.03720.51
5.6.150.0100.06318.21
5.6.140.0070.06018.15
5.6.130.0070.05018.28
5.6.120.0100.05021.00
5.6.110.0030.08721.12
5.6.100.0030.04021.00
5.6.90.0070.06321.00
5.6.80.0100.07020.40
5.5.350.0070.08720.43
5.5.340.0170.05718.05
5.5.330.0000.09020.21
5.5.320.0370.08020.27
5.5.310.0330.03720.25
5.5.300.0070.08317.99
5.5.290.0070.07018.03
5.5.280.0100.06020.80
5.5.270.0100.08320.77
5.5.260.0200.07720.73
5.5.250.0200.07720.69
5.5.240.3470.03720.12
5.4.450.0200.05319.55
5.4.440.0570.05719.47
5.4.430.0100.05719.52
5.4.420.0130.06019.63
5.4.410.0230.04319.27
5.4.400.0130.04719.07
5.4.390.0230.05018.71
5.4.380.0230.05318.75
5.4.370.0100.06318.44
5.4.360.0100.06018.69
5.4.350.0170.05318.72
5.4.340.0300.04318.79
5.4.320.0270.06018.78
5.4.310.0200.05718.56
5.4.300.0230.05318.72
5.4.290.0170.05318.80
5.4.280.0230.04318.42
5.4.270.0170.06018.83
5.4.260.0200.05318.55
5.4.250.0230.05018.73
5.4.240.0100.06318.72
5.4.230.0130.05718.55
5.4.220.0270.04718.77
5.4.210.0200.05018.71
5.4.200.0130.05316.59
5.4.190.0100.05718.43
5.4.180.0130.06318.45
5.4.170.0200.05018.79
5.4.160.0100.05718.74
5.4.150.0170.05718.54
5.4.140.0170.05016.22
5.4.130.0200.05016.30
5.4.120.0230.04716.18
5.4.110.0130.05316.45
5.4.100.0170.05016.45
5.4.90.0200.04716.43
5.4.80.0130.05016.27
5.4.70.0270.04316.18
5.4.60.0130.05316.23
5.4.50.0170.06316.39
5.4.40.0270.06016.16
5.4.30.0200.05716.25
5.4.20.0200.04716.19
5.4.10.0230.04316.16
5.4.00.0230.06015.70
5.3.290.0170.05714.77
5.3.280.0230.04714.71
5.3.270.0200.05014.83
5.3.260.0070.06314.63
5.3.250.0170.05014.64
5.3.240.0200.06714.59
5.3.230.0170.07314.79
5.3.220.0200.07014.70
5.3.210.0300.05314.57
5.3.200.0270.04014.74
5.3.190.0200.06714.67
5.3.180.0130.05314.60
5.3.170.0130.05314.63
5.3.160.0200.04714.70
5.3.150.0170.05314.59
5.3.140.0130.05314.56
5.3.130.0300.04714.61
5.3.120.0130.06314.66
5.3.110.0170.05314.59
5.3.100.0230.04314.22
5.3.90.0100.05714.05
5.3.80.0070.06014.01
5.3.70.0070.05714.13
5.3.60.0270.04014.05
5.3.50.0070.06014.08
5.3.40.0230.04313.99
5.3.30.0230.06314.12
5.3.20.0130.05013.73
5.3.10.0130.05013.70
5.3.00.0130.05313.86
5.2.170.0070.04711.18
5.2.160.0130.04011.26
5.2.150.0100.04311.25
5.2.140.0070.05011.14
5.2.130.0130.04311.15
5.2.120.0100.04311.14
5.2.110.0200.04311.23
5.2.100.0200.03011.11
5.2.90.0100.04311.13
5.2.80.0030.05711.31
5.2.70.0270.05011.21
5.2.60.0130.04311.07
5.2.50.0070.04711.02
5.2.40.0130.04310.98
5.2.30.0230.04711.05
5.2.20.0100.05311.00
5.2.10.0130.03710.93
5.2.00.0100.04310.76
5.1.60.0070.03710.02
5.1.50.0130.03010.13
5.1.40.0100.03710.02
5.1.30.0200.03010.56
5.1.20.0070.04310.35
5.1.10.0170.03010.14
5.1.00.0070.04010.11
5.0.50.0030.0338.74
5.0.40.0000.0338.45
5.0.30.0170.0478.43
5.0.20.0100.0338.23
5.0.10.0100.0278.15
5.0.00.0030.0478.29
4.4.90.0130.0135.93
4.4.80.0030.0335.89
4.4.70.0100.0275.86
4.4.60.0070.0305.88
4.4.50.0070.0205.89
4.4.40.0000.0405.95
4.4.30.0100.0175.88
4.4.20.0030.0235.92
4.4.10.0030.0235.98
4.4.00.0070.0335.95
4.3.110.0070.0205.87
4.3.100.0070.0205.80
4.3.90.0070.0205.84
4.3.80.0030.0335.77
4.3.70.0030.0235.78
4.3.60.0070.0205.87
4.3.50.0000.0335.87
4.3.40.0070.0335.80
4.3.30.0070.0234.55
4.3.20.0070.0204.53
4.3.10.0030.0204.52
4.3.00.0000.02712.53

preferences:
45.47 ms | 400 KiB | 5 Q