3v4l.org

run code in 300+ PHP versions simultaneously
<?php class foo { function get_flags($uid = NULL, $set=TRUE) { $flags = $this->get_metadata('flags', $uid); if($flags == FALSE){ return FALSE; } if($set){$this->flags = $flags;} return $flags; } function get_metadata($field, $uid) { return $field.$uid; } function __construct() { var_dump($this->get_flags(1, false)); } }

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.0170.00318.43
8.3.50.0120.00821.14
8.3.40.0040.01118.76
8.3.30.0140.00719.09
8.3.20.0040.00420.21
8.3.10.0020.00522.08
8.3.00.0050.00322.43
8.2.180.0110.00716.38
8.2.170.0120.00322.96
8.2.160.0100.01020.52
8.2.150.0180.00024.18
8.2.140.0110.00724.66
8.2.130.0050.00326.16
8.2.120.0000.00819.65
8.2.110.0040.00422.13
8.2.100.0000.01117.66
8.2.90.0000.00819.10
8.2.80.0000.00719.33
8.2.70.0060.00317.50
8.2.60.0000.00717.80
8.2.50.0040.00518.07
8.2.40.0040.00418.09
8.2.30.0040.00417.94
8.2.20.0040.00417.54
8.2.10.0050.00217.48
8.2.00.0000.00817.55
8.1.280.0030.01225.92
8.1.270.0130.00720.29
8.1.260.0080.00026.35
8.1.250.0050.00328.09
8.1.240.0060.00323.87
8.1.230.0080.00419.16
8.1.220.0030.00517.74
8.1.210.0090.00018.77
8.1.200.0000.01017.10
8.1.190.0080.00017.29
8.1.180.0040.00418.89
8.1.170.0060.00318.52
8.1.160.0000.00822.08
8.1.150.0000.00818.55
8.1.140.0050.00217.27
8.1.130.0070.00017.77
8.1.120.0040.00417.34
8.1.110.0070.00317.33
8.1.100.0040.00417.25
8.1.90.0030.00317.33
8.1.80.0000.00817.36
8.1.70.0030.00317.36
8.1.60.0050.00317.40
8.1.50.0000.00717.42
8.1.40.0000.00817.37
8.1.30.0000.00717.41
8.1.20.0030.00617.53
8.1.10.0080.00017.36
8.1.00.0000.01217.24
8.0.300.0060.00318.77
8.0.290.0000.00817.05
8.0.280.0030.00318.23
8.0.270.0000.00717.01
8.0.260.0040.00416.57
8.0.250.0070.00016.79
8.0.240.0040.00416.80
8.0.230.0000.00716.85
8.0.220.0030.00316.78
8.0.210.0000.00716.79
8.0.200.0000.00716.88
8.0.190.0000.00816.68
8.0.180.0000.00716.76
8.0.170.0060.00316.77
8.0.160.0030.00416.72
8.0.150.0000.00816.60
8.0.140.0040.00416.80
8.0.130.0060.00013.16
8.0.120.0040.00416.61
8.0.110.0000.00816.76
8.0.100.0030.00516.64
8.0.90.0000.00716.64
8.0.80.0060.01216.66
8.0.70.0000.00816.72
8.0.60.0040.00416.75
8.0.50.0050.00216.75
8.0.30.0090.01216.99
8.0.20.0100.00817.40
8.0.10.0000.00816.84
8.0.00.0080.01216.62
7.4.330.0000.00515.00
7.4.320.0060.00016.47
7.4.300.0030.00316.38
7.4.290.0030.00316.33
7.4.280.0000.00816.38
7.4.270.0030.00316.34
7.4.260.0070.00316.36
7.4.250.0070.00016.37
7.4.240.0040.00316.38
7.4.230.0000.00716.50
7.4.220.0110.00716.41
7.4.210.0070.01016.43
7.4.200.0000.00716.27
7.4.190.0040.00416.52
7.4.160.0030.01316.54
7.4.150.0090.01517.40
7.4.140.0070.01217.86
7.4.130.0130.00616.33
7.4.120.0070.01016.38
7.4.110.0100.00716.39
7.4.100.0160.00416.45
7.4.90.0110.00616.34
7.4.80.0070.01119.39
7.4.70.0100.00716.49
7.4.60.0090.00616.53
7.4.50.0040.00416.50
7.4.40.0030.00822.77
7.4.30.0060.01716.23
7.4.00.0050.00814.68
7.3.330.0020.00212.98
7.3.320.0030.00313.18
7.3.310.0000.00716.18
7.3.300.0030.00616.05
7.3.290.0110.00316.23
7.3.280.0100.00716.14
7.3.270.0100.00717.40
7.3.260.0070.01016.23
7.3.250.0100.00716.26
7.3.240.0120.01216.45
7.3.230.0070.01116.39
7.3.210.0110.00616.34
7.3.200.0100.00719.39
7.3.190.0030.01416.15
7.3.180.0030.01316.33
7.3.170.0120.00616.28
7.3.160.0070.01016.30
7.3.120.0030.01014.81
7.2.330.0100.00716.58
7.2.320.0070.01116.37
7.2.310.0190.00616.43
7.2.300.0040.01316.49
7.2.290.0030.01316.57
7.2.60.0060.00616.77
7.1.200.0070.00715.57
7.1.70.0000.00717.03
7.1.60.0040.00817.20
7.1.50.0030.01316.94
7.1.00.0030.03322.34
7.0.200.0170.00816.57
7.0.140.0030.07022.04
7.0.60.0170.07020.00
7.0.50.0030.08017.81
7.0.40.0070.06720.21
7.0.30.0530.06720.18
7.0.20.0270.06720.16
7.0.10.0030.04320.33
7.0.00.0030.04720.22
5.6.280.0030.07321.16
5.6.210.0030.07720.73
5.6.200.0130.07318.29
5.6.190.0030.04720.46
5.6.180.0230.07720.77
5.6.170.0330.07720.46
5.6.160.0070.04020.57
5.6.150.0130.07318.21
5.6.140.0130.07318.22
5.6.130.0030.05318.21
5.6.120.0070.04721.08
5.6.110.0100.03720.90
5.6.100.0070.08021.01
5.6.90.0070.05720.98
5.6.80.0070.04020.51
5.6.70.4230.04020.50
5.5.350.0130.07320.30
5.5.340.0030.05318.02
5.5.330.0170.03020.45
5.5.320.0430.06720.34
5.5.310.0170.05720.35
5.5.300.0030.06017.92
5.5.290.0130.07318.04
5.5.280.0130.07020.88
5.5.270.0230.07320.65
5.5.260.0000.07320.88
5.5.250.0070.04720.49
5.5.240.0370.06320.27
5.4.450.0700.06319.39
5.4.440.0830.05719.34
5.4.430.0770.05719.46
5.4.420.1030.06019.48
5.4.410.1030.04719.20
5.4.400.1200.05318.78
5.4.390.1500.06718.84
5.4.380.0170.06318.86
5.4.370.0130.05018.76
5.4.360.0070.06018.70
5.4.350.0140.05412.02
5.4.340.0130.04412.02
5.4.320.0080.03412.50
5.4.310.0040.04412.50
5.4.300.0030.04012.50
5.4.290.0070.04912.50
5.4.280.0070.03512.40
5.4.270.0080.03612.40
5.4.260.0050.03812.40
5.4.250.0170.07718.89
5.4.240.0030.06018.79
5.4.230.0200.05018.98
5.4.220.0070.06718.75
5.4.210.0100.05018.98
5.4.200.0100.05018.79
5.4.190.0100.07718.96
5.4.180.0170.05319.09
5.4.170.0130.07018.73
5.4.160.0100.05718.94
5.4.150.0130.06018.82
5.4.140.0100.06016.39
5.4.130.0070.05316.40
5.4.120.0170.05716.54
5.4.110.0130.04716.41
5.4.100.0170.04016.46
5.4.90.0100.05016.55
5.4.80.0100.06716.39
5.4.70.0070.05716.48
5.4.60.0130.05016.36
5.4.50.0070.06316.33
5.4.40.0000.06316.50
5.4.30.0070.05016.39
5.4.20.0030.05316.62
5.4.10.0070.05716.54
5.4.00.0100.04715.80
5.3.290.0060.05412.80
5.3.280.0100.05014.69
5.3.270.0000.06014.70
5.3.260.0070.05714.58
5.3.250.0030.05714.77
5.3.240.0130.04714.70
5.3.230.0000.06314.59
5.3.220.0100.07014.63
5.3.210.0130.06714.56
5.3.200.0130.06714.73
5.3.190.0070.05014.65
5.3.180.0070.06314.57
5.3.170.0130.06014.75
5.3.160.0100.05014.40
5.3.150.0130.05714.70
5.3.140.0030.06014.73
5.3.130.0100.04714.54
5.3.120.0100.06714.52
5.3.110.0130.04714.63
5.3.100.0000.06013.88
5.3.90.0130.07714.11
5.3.80.0100.04714.11
5.3.70.0130.05014.02
5.3.60.0130.04714.22
5.3.50.0030.05713.85
5.3.40.0030.05714.02
5.3.30.0100.05313.90
5.3.20.0070.05313.93
5.3.10.0100.04313.66
5.3.00.0100.06313.64
5.2.170.0030.06311.14
5.2.160.0130.04011.15
5.2.150.0030.05711.10
5.2.140.0000.05311.13
5.2.130.0070.04311.09
5.2.120.0100.05311.18
5.2.110.0070.04011.11
5.2.100.0100.06011.11
5.2.90.0130.05011.06
5.2.80.0130.05311.32
5.2.70.0030.05011.17
5.2.60.0030.06311.23
5.2.50.0100.04311.11
5.2.40.0170.03011.07
5.2.30.0070.04710.98
5.2.20.0200.03711.05
5.2.10.0070.04010.70
5.2.00.0030.04310.70
5.1.60.0030.03710.09
5.1.50.0100.03010.00
5.1.40.0070.03010.05
5.1.30.0030.03710.44
5.1.20.0070.04710.53
5.1.10.0070.03310.16
5.1.00.0100.03310.14
5.0.50.0030.0408.47
5.0.40.0070.0338.43
5.0.30.0070.0538.43
5.0.20.0000.0308.43
5.0.10.0070.0378.43
5.0.00.0030.0578.43
4.4.90.0000.0278.43
4.4.80.0000.0278.43
4.4.70.0030.0308.43
4.4.60.0030.0278.43
4.4.50.0030.0308.43
4.4.40.0070.0378.43
4.4.30.0000.0278.43
4.4.20.0070.0178.43
4.4.10.0030.0208.43
4.4.00.0000.0378.43
4.3.110.0030.0308.43
4.3.100.0000.0238.43
4.3.90.0070.0178.43
4.3.80.0000.0378.43
4.3.70.0030.0208.43
4.3.60.0000.0338.43
4.3.50.0070.0178.43
4.3.40.0070.0408.43
4.3.30.0000.0308.43
4.3.20.0000.0238.43
4.3.10.0170.0178.43
4.3.00.0170.0236.91

preferences:
47.31 ms | 401 KiB | 5 Q