3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Connection { public $server, $username, $password, $db; public function __sleep() { return array('server', 'username', 'password', 'db'); } public function a(){ echo $this->server; echo $this->username; echo $this->password; echo $this->db; } } /*$server="server1"; $username="username1"; $password="password1"; $db="db1";*/ $conect= new Connection("server1", "username1", "password1", "db1"); $conect->a(); ?>

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.0150.00618.43
8.3.50.0110.00721.21
8.3.40.0070.00718.71
8.3.30.0040.01119.08
8.3.20.0040.00420.13
8.3.10.0050.00322.09
8.3.00.0040.00422.47
8.2.180.0120.00916.50
8.2.170.0150.00622.96
8.2.160.0170.00319.04
8.2.150.0080.00024.18
8.2.140.0030.00524.66
8.2.130.0110.00326.16
8.2.120.0090.00019.36
8.2.110.0190.00322.28
8.2.100.0040.00819.51
8.2.90.0040.00419.27
8.2.80.0000.00917.97
8.2.70.0050.00317.50
8.2.60.0000.00817.80
8.2.50.0060.00318.07
8.2.40.0050.00218.34
8.2.30.0050.00318.13
8.2.20.0000.00817.64
8.2.10.0000.00717.62
8.2.00.0000.00817.63
8.1.280.0180.00025.92
8.1.270.0060.00322.01
8.1.260.0050.00226.35
8.1.250.0040.00428.09
8.1.240.0050.00523.96
8.1.230.0080.00319.08
8.1.220.0040.00417.74
8.1.210.0060.00318.77
8.1.200.0040.00417.10
8.1.190.0040.00417.41
8.1.180.0000.00818.67
8.1.170.0000.00818.43
8.1.160.0000.00721.87
8.1.150.0040.00418.50
8.1.140.0070.00017.40
8.1.130.0030.00317.80
8.1.120.0080.00017.40
8.1.110.0000.00817.34
8.1.100.0080.00017.44
8.1.90.0040.00417.32
8.1.80.0070.00017.29
8.1.70.0000.00717.37
8.1.60.0040.00417.57
8.1.50.0040.00417.43
8.1.40.0040.00417.44
8.1.30.0050.00217.53
8.1.20.0030.00517.71
8.1.10.0000.00717.48
8.1.00.0040.00417.39
8.0.300.0030.00518.77
8.0.290.0000.00717.18
8.0.280.0070.00018.45
8.0.270.0020.00517.27
8.0.260.0030.00316.70
8.0.250.0030.00316.86
8.0.240.0040.00416.89
8.0.230.0000.00716.89
8.0.220.0070.00016.72
8.0.210.0000.00716.75
8.0.200.0040.00416.89
8.0.190.0000.00816.92
8.0.180.0040.00416.71
8.0.170.0040.00416.79
8.0.160.0000.00716.77
8.0.150.0000.00816.77
8.0.140.0040.00416.83
8.0.130.0000.00613.17
8.0.120.0040.00416.70
8.0.110.0070.00016.80
8.0.100.0040.00416.70
8.0.90.0040.00416.78
8.0.80.0060.01016.89
8.0.70.0070.00016.90
8.0.60.0030.00516.78
8.0.50.0000.00716.85
8.0.30.0150.00417.25
8.0.20.0080.01017.40
8.0.10.0000.00816.96
8.0.00.0080.01016.77
7.4.330.0020.00215.00
7.4.320.0040.00416.35
7.4.300.0030.00316.52
7.4.290.0030.00316.46
7.4.280.0000.00816.57
7.4.270.0000.00716.61
7.4.260.0040.00416.63
7.4.250.0040.00416.62
7.4.240.0040.00316.54
7.4.230.0000.00716.68
7.4.220.0150.00316.58
7.4.210.0100.00716.64
7.4.200.0000.00716.50
7.4.190.0040.00416.78
7.4.160.0070.01016.33
7.4.150.0160.00617.40
7.4.140.0150.00417.86
7.4.130.0090.00916.42
7.4.120.0120.00516.50
7.4.110.0040.01316.57
7.4.100.0100.01016.56
7.4.90.0120.00616.55
7.4.80.0160.00019.39
7.4.70.0100.00716.50
7.4.60.0000.01616.46
7.4.50.0040.00416.48
7.4.40.0090.00622.77
7.4.30.0180.00316.71
7.4.00.0000.01514.81
7.3.330.0060.00013.26
7.3.320.0000.00513.18
7.3.310.0000.00616.21
7.3.300.0040.00416.21
7.3.290.0040.00916.25
7.3.280.0090.00716.22
7.3.270.0040.01417.40
7.3.260.0080.00816.32
7.3.250.0080.00816.18
7.3.240.0030.01616.28
7.3.230.0110.00816.39
7.3.210.0170.00016.44
7.3.200.0100.00619.39
7.3.190.0120.00916.28
7.3.180.0040.01116.30
7.3.170.0130.00316.41
7.3.160.0050.01016.43
7.3.120.0030.01414.41
7.3.10.0000.01516.34
7.3.00.0040.00816.48
7.2.330.0100.00816.56
7.2.320.0080.00916.29
7.2.310.0160.00016.72
7.2.300.0090.00616.75
7.2.290.0060.01216.78
7.2.130.0060.00616.45
7.2.120.0130.00316.57
7.2.110.0100.00316.87
7.2.100.0100.00316.61
7.2.90.0030.00617.00
7.2.80.0060.01216.93
7.2.70.0070.00716.53
7.2.60.0120.00616.51
7.2.50.0040.00816.81
7.2.40.0220.00016.83
7.2.30.0070.00716.54
7.2.20.0030.01016.82
7.2.10.0060.00616.62
7.2.00.0150.00916.82
7.1.250.0000.00815.59
7.1.200.0060.00615.44
7.1.100.0100.00617.67
7.1.70.0060.00317.15
7.1.60.0040.02119.82
7.1.50.0040.01916.53
7.1.00.0100.07022.35
7.0.200.0070.00316.66
7.0.140.0070.07022.01
7.0.100.0030.07019.87
7.0.90.0270.06719.91
7.0.80.0170.07019.86
7.0.70.0100.04719.90
7.0.60.0000.05319.98
7.0.50.0330.08320.27
7.0.40.0100.06720.13
7.0.30.0200.05320.13
7.0.20.0070.09720.04
7.0.10.0130.04320.11
7.0.00.0000.06719.97
5.6.280.0070.07020.91
5.6.250.0130.07320.63
5.6.240.0030.08720.61
5.6.230.0030.08320.68
5.6.220.0070.08320.49
5.6.210.0000.05320.62
5.6.200.0070.08021.07
5.6.190.0100.07021.05
5.6.180.0130.07721.11
5.6.170.0100.05021.10
5.6.160.0030.08320.94
5.6.150.0100.08021.02
5.6.140.0130.07720.93
5.6.130.0130.07721.06
5.6.120.0030.05321.05
5.6.110.0100.07020.98
5.6.100.0100.04721.03
5.6.90.0100.07720.93
5.6.80.0070.06020.38
5.6.70.0130.07320.43
5.6.60.0100.03320.48
5.6.50.0070.08720.47
5.6.40.0030.07320.43
5.6.30.0100.07720.38
5.6.20.0100.07720.39
5.6.10.0200.06720.39
5.6.00.0130.04020.42
5.5.380.0170.06720.34
5.5.370.0100.07720.54
5.5.360.0070.04720.50
5.5.350.0100.07720.45
5.5.340.0100.07720.93
5.5.330.0100.04320.84
5.5.320.0070.08720.76
5.5.310.0130.07720.83
5.5.300.0030.05020.92
5.5.290.0130.05320.93
5.5.280.0070.08320.87
5.5.270.0030.05020.89
5.5.260.0070.05320.85
5.5.250.0070.08320.70
5.5.240.0070.04320.18
5.5.230.0070.04720.26
5.5.220.0200.06320.20
5.5.210.0030.08720.14
5.5.200.0070.04320.20
5.5.190.0070.08020.18
5.5.180.0070.09020.11
5.5.160.0100.08320.21
5.5.150.0030.05320.24
5.5.140.0130.07020.21
5.5.130.0100.04320.08
5.5.120.0130.07320.22
5.5.110.0030.08320.27
5.5.100.0070.08020.09
5.5.90.0100.07720.06
5.5.80.0030.06720.14
5.5.70.0030.08320.15
5.5.60.0030.04320.04
5.5.50.0130.08720.05
5.5.40.0130.07320.08
5.5.30.0100.05720.09
5.5.20.0100.04020.09
5.5.10.0030.08320.02
5.5.00.0030.04320.02
5.4.450.0100.08319.38
5.4.440.0100.07719.41
5.4.430.0030.07019.37
5.4.420.0100.08019.20
5.4.410.0030.06019.32
5.4.400.0100.05719.13
5.4.390.0070.04719.23
5.4.380.0070.04718.82
5.4.370.0070.07019.00
5.4.360.0000.08319.05
5.4.350.0100.07319.21
5.4.340.0170.07019.05
5.4.320.0070.08719.03
5.4.310.0030.08319.16
5.4.300.0130.06018.84
5.4.290.0100.07719.03
5.4.280.0070.07719.13
5.4.270.0100.06319.04
5.4.260.0130.05018.90
5.4.250.0130.06719.04
5.4.240.0130.03319.04
5.4.230.0030.06719.02
5.4.220.0030.08318.99
5.4.210.0070.07718.87
5.4.200.0130.06319.08
5.4.190.0070.04319.11
5.4.180.0100.07018.84
5.4.170.0000.04319.12
5.4.160.0130.07319.00
5.4.150.0070.04719.13
5.4.140.0100.06316.25
5.4.130.0100.07016.38
5.4.120.0030.07716.46
5.4.110.0070.07316.38
5.4.100.0100.06316.34
5.4.90.0000.05016.27
5.4.80.0070.04016.41
5.4.70.0100.04716.36
5.4.60.0070.06016.48
5.4.50.0070.06016.36
5.4.40.0100.03716.54
5.4.30.0130.07016.35
5.4.20.0130.06016.46
5.4.10.0070.04316.43
5.4.00.0070.06315.63
5.3.290.0030.04014.66
5.3.280.0200.06714.72
5.3.270.0030.05314.58
5.3.260.0170.03014.75
5.3.250.0030.07714.68
5.3.240.0070.05714.56
5.3.230.0030.07014.71
5.3.220.0100.05714.58
5.3.210.0130.03714.52
5.3.200.0030.07014.53
5.3.190.0000.04714.71
5.3.180.0030.06314.57
5.3.170.0070.06714.71
5.3.160.0070.07014.66
5.3.150.0070.07014.69
5.3.140.0070.06714.63
5.3.130.0070.05314.62
5.3.120.0070.07014.66
5.3.110.0100.06714.59
5.3.100.0070.04014.15
5.3.90.0000.05313.95
5.3.80.0000.04013.95
5.3.70.0030.03713.94
5.3.60.0070.03313.98
5.3.50.0030.03714.00
5.3.40.0070.03713.98
5.3.30.0030.03313.89
5.3.20.0100.02713.74
5.3.10.0070.03013.71
5.3.00.0070.03013.64
5.2.170.0030.02712.36
5.2.160.0030.03012.36
5.2.150.0000.03012.36
5.2.140.0000.03312.36
5.2.130.0000.03012.36
5.2.120.0000.02712.36
5.2.110.0070.02312.36
5.2.100.0000.03012.36
5.2.90.0000.03012.36
5.2.80.0070.02712.36
5.2.70.0000.03012.36
5.2.60.0030.03312.36
5.2.50.0000.02712.36
5.2.40.0000.02712.36
5.2.30.0070.02712.36
5.2.20.0070.03712.36
5.2.10.0070.02312.36
5.2.00.0070.02312.36
5.1.60.0030.02312.36
5.1.50.0070.05012.36
5.1.40.0000.04712.36
5.1.30.0070.05712.36
5.1.20.0000.05712.36
5.1.10.0100.05012.36
5.1.00.0030.03012.36
5.0.50.0000.03712.36
5.0.40.0030.02012.36
5.0.30.0000.04312.36
5.0.20.0000.01712.36
5.0.10.0030.01712.36
5.0.00.0000.03012.36
4.4.90.0000.01712.36
4.4.80.0000.01712.36
4.4.70.0000.01712.36
4.4.60.0000.03012.36
4.4.50.0000.02012.36
4.4.40.0000.02312.36
4.4.30.0030.01712.36
4.4.20.0000.03012.36
4.4.10.0000.02312.36
4.4.00.0000.02712.36
4.3.110.0070.01312.36
4.3.100.0000.01712.36
4.3.90.0000.01312.36
4.3.80.0030.02312.36
4.3.70.0000.02012.36
4.3.60.0000.01712.36
4.3.50.0000.01712.36
4.3.40.0030.03312.36
4.3.30.0000.02012.36
4.3.20.0030.02012.36
4.3.10.0000.01312.36
4.3.00.0030.01312.36

preferences:
43.9 ms | 400 KiB | 5 Q