3v4l.org

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

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.0070.00716.38
8.3.50.0130.00621.97
8.3.40.0070.00718.59
8.3.30.0100.00719.12
8.3.20.0050.00520.35
8.3.10.0050.00323.70
8.3.00.0060.00317.50
8.2.180.0070.00718.55
8.2.170.0110.00422.96
8.2.160.0100.00320.50
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0000.00726.16
8.2.120.0040.00422.21
8.2.110.0030.00622.30
8.2.100.0080.00417.84
8.2.90.0040.00419.23
8.2.80.0040.00418.05
8.2.70.0040.00417.75
8.2.60.0000.00817.93
8.2.50.0030.00518.07
8.2.40.0040.00418.16
8.2.30.0040.00418.04
8.2.20.0040.00417.67
8.2.10.0030.00517.77
8.2.00.0040.00417.63
8.1.280.0100.00725.92
8.1.270.0040.00423.79
8.1.260.0050.00526.35
8.1.250.0080.00028.09
8.1.240.0080.00023.96
8.1.230.0120.00019.21
8.1.220.0080.00017.74
8.1.210.0090.00018.77
8.1.200.0070.00317.35
8.1.190.0040.00417.41
8.1.180.0040.00418.10
8.1.170.0040.00718.66
8.1.160.0030.00621.91
8.1.150.0040.00418.49
8.1.140.0050.00217.37
8.1.130.0000.00717.79
8.1.120.0000.00717.41
8.1.110.0070.00017.41
8.1.100.0070.00017.43
8.1.90.0030.00517.30
8.1.80.0030.00317.25
8.1.70.0030.00317.37
8.1.60.0000.00817.61
8.1.50.0000.00817.48
8.1.40.0040.00417.50
8.1.30.0050.00317.59
8.1.20.0040.00417.55
8.1.10.0050.00317.55
8.1.00.0040.00417.48
8.0.300.0040.00418.77
8.0.290.0070.00017.18
8.0.280.0030.00318.44
8.0.270.0000.00717.22
8.0.260.0070.00016.89
8.0.250.0070.00016.93
8.0.240.0000.00817.05
8.0.230.0000.00716.96
8.0.220.0000.00716.80
8.0.210.0030.00316.94
8.0.200.0030.00316.98
8.0.190.0070.00016.94
8.0.180.0050.00216.81
8.0.170.0000.00716.87
8.0.160.0000.00716.84
8.0.150.0070.00016.80
8.0.140.0000.00716.73
8.0.130.0030.00613.31
8.0.120.0000.00816.75
8.0.110.0050.00316.80
8.0.100.0050.00216.84
8.0.90.0080.00016.73
8.0.80.0070.00716.93
8.0.70.0040.00417.00
8.0.60.0040.00416.90
8.0.50.0000.00716.88
8.0.30.0140.00817.10
8.0.20.0050.01317.40
8.0.10.0000.00717.05
8.0.00.0100.00916.69
7.4.330.0000.00515.00
7.4.320.0060.00016.56
7.4.300.0000.00616.55
7.4.290.0060.00316.63
7.4.280.0030.00616.60
7.4.270.0000.00716.40
7.4.260.0050.00316.51
7.4.250.0030.00616.48
7.4.240.0040.00316.49
7.4.230.0000.00716.63
7.4.220.0120.00616.58
7.4.210.0070.00916.50
7.4.200.0030.00316.57
7.4.190.0070.00016.57
7.4.160.0100.00516.47
7.4.150.0100.00717.40
7.4.140.0140.01617.86
7.4.130.0140.00416.53
7.4.120.0030.01416.57
7.4.110.0060.01016.43
7.4.100.0140.00716.45
7.4.90.0070.01116.48
7.4.80.0120.00419.39
7.4.70.0120.00416.57
7.4.60.0100.00716.58
7.4.50.0040.00016.30
7.4.40.0000.01322.77
7.4.30.0060.01016.58
7.4.00.0000.01415.04
7.3.330.0020.00213.25
7.3.320.0030.00313.11
7.3.310.0030.00316.28
7.3.300.0000.00716.34
7.3.290.0130.00316.31
7.3.280.0120.00716.25
7.3.270.0120.00417.40
7.3.260.0100.01316.23
7.3.250.0080.01116.52
7.3.240.0120.00916.53
7.3.230.0120.01216.39
7.3.210.0070.01016.44
7.3.200.0100.00719.39
7.3.190.0060.01516.54
7.3.180.0090.00616.41
7.3.170.0100.00616.27
7.3.160.0030.01316.54
7.3.120.0100.00714.95
7.2.330.0060.01016.49
7.2.320.0100.00616.80
7.2.310.0150.00316.85
7.2.300.0100.00716.55
7.2.290.0120.00616.64
7.2.60.0060.00916.66
7.1.200.0100.00315.78
7.1.70.0000.00717.22
7.1.60.0140.01019.31
7.1.50.0070.01716.98
7.1.00.0070.07322.35
7.0.200.0140.00016.22
7.0.140.0130.06322.22
7.0.60.0100.08019.88
7.0.50.0070.08317.86
7.0.40.0100.06719.96
7.0.30.0330.07320.26
7.0.20.0370.07020.16
7.0.10.0270.08320.26
7.0.00.0100.03720.25
5.6.280.0000.07721.11
5.6.210.0070.08320.48
5.6.200.0100.08318.18
5.6.190.0000.05720.48
5.6.180.0300.03720.67
5.6.170.0330.05020.50
5.6.160.0030.04320.61
5.6.150.0030.04318.17
5.6.140.0100.05318.21
5.6.130.0070.07318.15
5.6.120.0100.03721.03
5.6.110.0030.09021.14
5.6.100.0100.08021.11
5.6.90.0000.09020.95
5.6.80.0100.07020.37
5.5.350.0030.03720.43
5.5.340.0230.06717.99
5.5.330.0070.08720.47
5.5.320.0070.03720.30
5.5.310.0330.06720.34
5.5.300.0030.04017.95
5.5.290.0030.08717.98
5.5.280.0100.05020.87
5.5.270.0000.07020.79
5.5.260.0100.05320.75
5.5.250.0000.04320.61
5.5.240.0070.07320.36
5.4.450.0400.06019.64
5.4.440.0830.03319.31
5.4.430.0600.06019.54
5.4.420.0600.05319.31
5.4.410.0770.06019.20
5.4.400.0730.04019.07
5.4.390.0670.05719.32
5.4.380.0500.06018.74
5.4.370.0230.06018.80
5.4.360.0500.05718.79
5.4.350.0300.05318.84
5.4.340.0430.07018.51
5.4.320.0060.04312.50
5.4.310.0080.03612.49
5.4.300.0060.04012.50
5.4.290.0050.03812.50
5.4.280.0060.03412.39
5.4.270.0070.03412.39
5.4.260.0030.04012.39
5.4.250.0040.03812.39
5.4.240.0070.03512.40
5.4.230.0090.03612.39
5.4.220.0090.03212.38
5.4.210.0090.03112.39
5.4.200.0070.04512.39
5.4.190.0170.04312.38
5.4.180.0280.09012.38
5.4.170.0140.04312.39
5.4.160.0150.04312.38
5.4.150.0120.04612.38
5.4.140.0140.04312.06
5.4.130.0160.04212.05
5.4.120.0150.04112.01
5.4.110.0140.04212.00
5.4.100.0160.04212.01
5.4.90.0140.04312.01
5.4.80.0140.04212.00
5.4.70.0120.04512.00
5.4.60.0170.04012.00
5.4.50.0200.03812.00
5.4.40.0200.03611.98
5.4.30.0100.04711.99
5.4.20.0260.06111.99
5.4.10.0150.04111.99
5.4.00.0110.04411.47
5.3.290.0060.03912.80
5.3.280.0100.03912.71
5.3.270.0180.04212.72
5.3.260.0140.04612.72
5.3.250.0160.04212.71
5.3.240.0110.04812.72
5.3.230.0170.04512.70
5.3.220.0180.04212.68
5.3.210.0120.04812.68
5.3.200.0190.04012.68
5.3.190.0180.04312.68
5.3.180.0150.04412.67
5.3.170.0270.06212.67
5.3.160.0150.04512.67
5.3.150.0150.04612.67
5.3.140.0150.04512.66
5.3.130.0240.04012.66
5.3.120.0230.04312.66
5.3.110.0170.04912.66
5.3.100.0250.06712.13
5.3.90.0190.04312.11
5.3.80.0160.04312.09
5.3.70.0190.04312.09
5.3.60.0160.04612.07
5.3.50.0160.04412.02
5.3.40.0190.04312.03
5.3.30.0160.04511.99
5.3.20.0180.04011.77
5.3.10.0130.04411.73
5.3.00.0170.03911.71
5.2.170.0110.0369.22
5.2.160.0120.0349.22
5.2.150.0110.0359.22
5.2.140.0090.0379.22
5.2.130.0140.0329.18
5.2.120.0110.0359.18
5.2.110.0130.0359.18
5.2.100.0120.0349.18
5.2.90.0240.0529.18
5.2.80.0120.0349.17
5.2.70.0130.0349.17
5.2.60.0160.0329.13
5.2.50.0150.0349.09
5.2.40.0150.0349.07
5.2.30.0130.0349.05
5.2.20.0110.0359.04
5.2.10.0150.0308.95
5.2.00.0130.0318.79
5.1.60.0210.0488.08
5.1.50.0130.0278.08
5.1.40.0100.0298.06
5.1.30.0120.0308.41
5.1.20.0070.0358.44
5.1.10.0120.0298.16
5.1.00.0130.0308.16
5.0.50.0100.0246.64
5.0.40.0140.0176.50
5.0.30.0120.0326.32
5.0.20.0080.0246.28
5.0.10.0100.0206.26
5.0.00.0180.0586.25
4.4.90.0050.0194.78
4.4.80.0040.0204.76
4.4.70.0070.0184.75
4.4.60.0060.0194.75
4.4.50.0170.0384.77
4.4.40.0070.0314.70
4.4.30.0080.0184.76
4.4.20.0080.0184.84
4.4.10.0070.0184.85
4.4.00.0050.0324.76
4.3.110.0120.0164.67
4.3.100.0080.0164.67
4.3.90.0090.0154.63
4.3.80.0060.0294.58
4.3.70.0070.0184.63
4.3.60.0080.0164.63
4.3.50.0080.0164.63
4.3.40.0090.0254.54
4.3.30.0080.0163.30
4.3.20.0020.0213.29
4.3.10.0040.0193.25
4.3.00.0030.03315.63

preferences:
48.3 ms | 401 KiB | 5 Q