3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Currency { public $currencyCode; public function __construct($currencyCode) { $this->currencyCode = $currencyCode; } public function equals(Currency $currency) { return $this->currencyCode === $currency->currencyCode; } } class Money { public $amount; public $currency; public function __construct($amount, Currency $currency = null) { $this->currency = $currency ?: new Currency('USD'); } } $revenue = new Money(55, new Currency('GBP')); var_dump($revenue->currency->equals(new Currency('GBP')));

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.40.0070.00718.82
8.3.30.0070.00719.07
8.3.20.0080.00020.33
8.3.10.0050.00320.58
8.3.00.0030.00519.91
8.2.170.0110.00422.96
8.2.160.0130.00020.52
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0040.00422.09
8.2.110.0040.00421.18
8.2.100.0060.00619.51
8.2.90.0040.00418.01
8.2.80.0060.00317.97
8.2.70.0000.01017.38
8.2.60.0040.00418.04
8.2.50.0080.00018.07
8.2.40.0090.00318.16
8.2.30.0000.00719.25
8.2.20.0040.00417.57
8.2.10.0000.00818.07
8.2.00.0000.00817.67
8.1.270.0000.01522.02
8.1.260.0000.00826.35
8.1.250.0070.00028.09
8.1.240.0030.00619.12
8.1.230.0080.00320.88
8.1.220.0030.00617.74
8.1.210.0000.00918.87
8.1.200.0090.00017.35
8.1.190.0000.00817.23
8.1.180.0040.00418.10
8.1.170.0000.00918.55
8.1.160.0050.00322.05
8.1.150.0020.00518.88
8.1.140.0000.00717.36
8.1.130.0070.00017.72
8.1.120.0000.00717.39
8.1.110.0050.00317.34
8.1.100.0070.00017.53
8.1.90.0000.00717.44
8.1.80.0000.00717.45
8.1.70.0000.00717.48
8.1.60.0050.00517.58
8.1.50.0050.00317.38
8.1.40.0060.00317.55
8.1.30.0040.00417.65
8.1.20.0050.00317.62
8.1.10.0040.00417.48
8.1.00.0080.00417.50
8.0.300.0070.00020.07
8.0.290.0000.00716.75
8.0.280.0000.00718.45
8.0.270.0000.00717.32
8.0.260.0000.00617.22
8.0.250.0000.00717.04
8.0.240.0030.00316.91
8.0.230.0030.00317.00
8.0.220.0000.00717.00
8.0.210.0060.00016.86
8.0.200.0040.00416.93
8.0.190.0070.00417.02
8.0.180.0050.00316.95
8.0.170.0040.00416.97
8.0.160.0040.00416.93
8.0.150.0000.00817.00
8.0.140.0070.00016.95
8.0.130.0050.00013.33
8.0.120.0040.00416.96
8.0.110.0050.00316.90
8.0.100.0000.00716.91
8.0.90.0080.00016.79
8.0.80.0060.01016.89
8.0.70.0040.00416.99
8.0.60.0050.00216.88
8.0.50.0040.00416.80
8.0.30.0050.01617.10
8.0.20.0100.01117.40
8.0.10.0040.00416.90
8.0.00.0120.00616.91
7.4.330.0020.00215.07
7.4.320.0060.00016.59
7.4.300.0060.00016.61
7.4.290.0000.00616.55
7.4.280.0050.00216.61
7.4.270.0070.00016.61
7.4.260.0070.00016.51
7.4.250.0000.00716.45
7.4.240.0040.00416.48
7.4.230.0040.00416.41
7.4.220.0030.01216.55
7.4.210.0000.01516.61
7.4.200.0000.00816.35
7.4.160.0070.01316.58
7.4.150.0120.00617.40
7.4.140.0060.01117.86
7.4.130.0100.00816.43
7.4.120.0130.00516.53
7.4.110.0100.00916.57
7.4.100.0100.00716.43
7.4.90.0100.00716.57
7.4.80.0120.00616.50
7.4.70.0070.01016.46
7.4.60.0090.00616.59
7.4.50.0000.00616.39
7.4.40.0100.00716.68
7.4.30.0090.00616.44
7.4.10.0030.01015.05
7.4.00.0050.01215.02
7.3.330.0050.00013.19
7.3.320.0000.00613.23
7.3.310.0000.00716.26
7.3.300.0070.00016.39
7.3.290.0150.00316.42
7.3.280.0090.01016.39
7.3.270.0140.00717.40
7.3.260.0150.00316.39
7.3.250.0150.00316.40
7.3.240.0080.00816.72
7.3.230.0080.00816.57
7.3.210.0070.01016.36
7.3.200.0070.01419.39
7.3.190.0110.00616.38
7.3.180.0030.01316.54
7.3.170.0100.00716.54
7.3.160.0120.00316.45
7.3.130.0070.01014.68
7.3.120.0040.01514.64
7.3.110.0030.01614.98
7.3.100.0100.00314.80
7.3.90.0000.01514.81
7.3.80.0050.00315.01
7.3.70.0000.01415.01
7.3.60.0050.00314.82
7.3.50.0060.00614.68
7.3.40.0060.00814.63
7.3.30.0040.01114.65
7.3.20.0110.00716.88
7.3.10.0100.00716.64
7.3.00.0050.01016.76
7.2.330.0060.01016.59
7.2.320.0180.00016.71
7.2.310.0090.00916.79
7.2.300.0090.00916.80
7.2.290.0130.00416.69
7.2.260.0130.00615.09
7.2.250.0110.00815.00
7.2.240.0110.00315.02
7.2.230.0080.00815.21
7.2.220.0030.00614.97
7.2.210.0090.00015.18
7.2.200.0000.01514.89
7.2.190.0000.01415.11
7.2.180.0030.00615.04
7.2.170.0030.00615.15
7.2.160.0030.01414.60
7.2.150.0060.01017.02
7.2.140.0060.00317.08
7.2.130.0070.00316.98
7.2.120.0060.00816.91
7.2.110.0080.00817.01
7.2.100.0060.00616.95
7.2.90.0050.01217.02
7.2.80.0030.01416.95
7.2.70.0050.00516.71
7.2.60.0050.00916.86
7.2.50.0080.00816.93
7.2.40.0040.00717.01
7.2.30.0080.00716.83
7.2.20.0070.00516.95
7.2.10.0100.00316.91
7.2.00.0040.00817.77
7.1.330.0030.01315.93
7.1.320.0000.01415.84
7.1.310.0030.01015.80
7.1.300.0150.00015.84
7.1.290.0090.00615.71
7.1.280.0040.00815.83
7.1.270.0110.00715.74
7.1.260.0030.00615.86
7.1.250.0060.00915.74
7.1.240.0050.01015.72
7.1.230.0060.00615.78
7.1.220.0050.00715.54
7.1.210.0030.00915.75
7.1.200.0110.00515.84
7.1.190.0080.00715.77
7.1.180.0080.00615.65
7.1.170.0070.00515.70
7.1.160.0050.00715.67
7.1.150.0050.00815.78
7.1.140.0060.00615.74
7.1.130.0070.00315.75
7.1.120.0060.00315.80
7.1.110.0090.00315.77
7.1.100.0030.00816.58
7.1.90.0060.00715.94
7.1.80.0030.00615.92
7.1.70.0070.00716.28
7.1.60.0050.01117.02
7.1.50.0110.00716.27
7.1.40.0080.00615.71
7.1.30.0050.00615.66
7.1.20.0010.01015.63
7.1.10.0040.01115.82
7.1.00.0020.02918.08
7.0.330.0050.00815.47
7.0.320.0110.00315.55
7.0.310.0070.00515.51
7.0.300.0050.01015.35
7.0.290.0060.00715.45
7.0.280.0000.01115.36
7.0.270.0020.01415.34
7.0.260.0050.00715.40
7.0.250.0020.01115.33
7.0.240.0050.00715.33
7.0.230.0030.00715.45
7.0.220.0050.00615.31
7.0.210.0060.00615.55
7.0.200.0060.00615.91
7.0.190.0030.01015.52
7.0.180.0030.00715.39
7.0.170.0060.00515.38
7.0.160.0070.00515.43
7.0.150.0020.01115.39
7.0.140.0080.02717.68
7.0.130.0080.00515.33
7.0.120.0090.00415.50
7.0.110.0040.00715.27
7.0.100.0040.00815.40
7.0.90.0050.00815.49
7.0.80.0050.00915.34
7.0.70.0070.01015.47
7.0.60.0080.02416.98
7.0.50.0020.02316.26
7.0.40.0050.02515.72
7.0.30.0060.02315.65
7.0.20.0110.02715.76
7.0.10.0120.02715.80
7.0.00.0040.02315.75
5.6.400.0000.01214.45
5.6.390.0090.00613.91
5.6.380.0050.01114.52
5.6.370.0070.00314.51
5.6.360.0030.01114.38
5.6.350.0020.00814.38
5.6.340.0060.00814.30
5.6.330.0050.00714.44
5.6.320.0030.01014.46
5.6.310.0070.00814.23
5.6.300.0100.00314.53
5.6.290.0070.00414.51
5.6.280.0030.03216.73
5.6.270.0090.00714.50
5.6.260.0040.00914.60
5.6.250.0060.00814.45
5.6.240.0030.00814.21
5.6.230.0070.00714.40
5.6.220.0080.00514.37
5.6.210.0030.03316.50
5.6.200.0040.01715.53
5.6.190.0090.01516.34
5.6.180.0210.02916.42
5.6.170.0130.02516.35
5.6.160.0030.02716.52
5.6.150.0050.02115.72
5.6.140.0050.02715.72
5.6.130.0110.02615.62
5.6.120.0050.03116.82
5.6.110.0070.02816.55
5.6.100.0100.02916.50
5.6.90.0090.02416.44
5.6.80.0020.03516.14
5.6.70.0070.00314.22
5.6.60.0090.00314.16
5.6.50.0040.01114.39
5.6.40.0040.00614.31
5.6.30.0070.00514.25
5.6.20.0090.00314.29
5.6.10.0020.01114.18
5.6.00.0050.00814.32
5.5.380.0020.00812.77
5.5.370.0030.00812.60
5.5.360.0020.01112.90
5.5.350.0070.02415.32
5.5.340.0060.03214.59
5.5.330.0040.02615.38
5.5.320.0130.02915.34
5.5.310.0210.02215.37
5.5.300.0060.01714.61
5.5.290.0070.02714.51
5.5.280.0050.03315.26
5.5.270.0070.03115.44
5.5.260.0070.01815.36
5.5.250.0060.03115.27
5.5.240.0070.03015.31
5.5.230.0060.00612.81
5.5.220.0070.00912.56
5.5.210.0050.00712.69
5.5.200.0050.00512.53
5.5.190.0030.00812.58
5.5.180.0070.00312.58
5.5.170.0060.00312.65
5.5.160.0030.00712.74
5.5.150.0010.01112.67
5.5.140.0060.00712.78
5.5.130.0060.00412.62
5.5.120.0050.00712.68
5.5.110.0050.00612.37
5.5.100.0060.00412.52
5.5.90.0040.00512.74
5.5.80.0020.00812.58
5.5.70.0050.00612.87
5.5.60.0060.00812.65
5.5.50.0030.00612.76
5.5.40.0030.00812.56
5.5.30.0060.00212.83
5.5.20.0070.00712.65
5.5.10.0070.00412.47
5.5.00.0040.00612.52
5.4.450.0110.02213.90
5.4.440.0380.02313.91
5.4.430.0300.02113.80
5.4.420.0060.02313.79
5.4.410.0340.02213.88
5.4.400.0350.02213.70
5.4.390.0370.01913.71
5.4.380.0170.02613.50
5.4.370.0100.02313.52
5.4.360.0120.02113.61
5.4.350.0110.02613.58
5.4.340.0140.02113.63
5.4.330.0040.00611.06
5.4.320.0030.01511.48
5.4.310.0050.01611.53
5.4.300.0040.01611.60
5.4.290.0050.01511.56
5.4.280.0040.01711.37
5.4.270.0040.01611.55
5.4.260.0050.01611.37
5.4.250.0050.01511.38
5.4.240.0040.01611.32
5.4.230.0050.01711.42
5.4.220.0050.01511.41
5.4.210.0060.01411.39
5.4.200.0050.01511.53
5.4.190.0040.01411.44
5.4.180.0030.01711.45
5.4.170.0040.01611.56
5.4.160.0050.01311.38
5.4.150.0040.01611.40
5.4.140.0010.01611.43
5.4.130.0050.01711.33
5.4.120.0010.01811.24
5.4.110.0030.01611.29
5.4.100.0040.01611.31
5.4.90.0050.01611.37
5.4.80.0060.01511.32
5.4.70.0050.01611.38
5.4.60.0050.01311.25
5.4.50.0050.01411.28
5.4.40.0040.01811.26
5.4.30.0080.01611.12
5.4.20.0050.01811.24
5.4.10.0030.01711.41
5.4.00.0070.01611.22
5.3.290.0050.02411.85
5.3.280.0020.02411.80
5.3.270.0040.02511.81
5.3.260.0090.02011.81
5.3.250.0060.02111.81
5.3.240.0040.02411.81
5.3.230.0060.02511.80
5.3.220.0040.02511.79
5.3.210.0040.02211.79
5.3.200.0040.02511.79
5.3.190.0060.02511.79
5.3.180.0070.01911.78
5.3.170.0090.02011.78
5.3.160.0070.02111.78
5.3.150.0040.02211.79
5.3.140.0020.02111.78
5.3.130.0050.02211.78
5.3.120.0060.02111.78
5.3.110.0030.02511.78
5.3.100.0050.02111.51
5.3.90.0040.02211.51
5.3.80.0040.02111.50
5.3.70.0030.02111.50
5.3.60.0050.02011.49
5.3.50.0060.01811.46
5.3.40.0060.01911.46
5.3.30.0020.02211.45
5.3.20.0040.02111.33
5.3.10.0050.02111.32
5.3.00.0040.02111.31
5.2.170.0030.01810.06
5.2.160.0050.01810.06
5.2.150.0060.01910.06
5.2.140.0020.02110.06
5.2.130.0080.01710.04
5.2.120.0040.01710.04
5.2.110.0040.01910.05
5.2.100.0020.01710.04
5.2.90.0060.01410.04
5.2.80.0050.01710.04
5.2.70.0050.01610.04
5.2.60.0030.01710.01
5.2.50.0030.01810.00
5.2.40.0040.0169.99
5.2.30.0020.0189.98
5.2.20.0040.0189.98
5.2.10.0060.0139.93
5.2.00.0030.0179.86
5.1.60.0040.0129.50
5.1.50.0030.0139.50
5.1.40.0020.0169.49
5.1.30.0040.0139.66
5.1.20.0040.0149.67
5.1.10.0040.0139.54
5.1.00.0030.0159.53
5.0.50.0040.0128.78
5.0.40.0020.0148.70
5.0.30.0030.0178.61
5.0.20.0010.0148.60
5.0.10.0060.0108.59
5.0.00.0020.0188.58
4.4.90.0020.0127.84
4.4.80.0020.0107.83
4.4.70.0050.0077.83
4.4.60.0040.0127.83
4.4.50.0020.0127.84
4.4.40.0030.0137.80
4.4.30.0020.0107.83
4.4.20.0040.0087.87
4.4.10.0020.0117.87
4.4.00.0020.0157.83
4.3.110.0020.0097.79
4.3.100.0030.0077.78
4.3.90.0030.0087.77
4.3.80.0040.0127.74
4.3.70.0020.0107.76
4.3.60.0040.0077.76
4.3.50.0040.0107.76
4.3.40.0020.0137.72
4.3.30.0020.0117.10
4.3.20.0010.0117.09
4.3.10.0030.0107.07
4.3.00.0030.0158.82

preferences:
37.81 ms | 400 KiB | 5 Q