3v4l.org

run code in 300+ PHP versions simultaneously
<?php function generateRandomString() { return 4; } class Connection { public function execute($query) { return true; } } class ConnectionFactory { public static function CreateConnection() { return new Connection; } } function pg_escape($data) { return $data; } class LocalAuth { protected $login; protected $pass; protected $salt; function Store(){ $db = ConnectionFactory::CreateConnection(); $q = "insert into localauth (login, pass, salt) values ('".$this->login."','".$this->pass."','".$this->salt."');"; $db->execute($q); } } $auth= new LocalAuth(); $auth->login= pg_escape($_POST['login']); $auth->pass= pg_escape($_POST['pass']); $auth->salt = generateRandomString(); $auth->Store();

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.01118.40
8.3.50.0060.01522.11
8.3.40.0150.00018.81
8.3.30.0180.00018.79
8.3.20.0080.00018.90
8.3.10.0080.00020.40
8.3.00.0000.00823.51
8.2.180.0080.00816.62
8.2.170.0070.01522.96
8.2.160.0100.00722.11
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0110.00726.16
8.2.120.0040.00419.48
8.2.110.0060.00320.94
8.2.100.0000.01217.84
8.2.90.0050.00319.39
8.2.80.0040.00417.97
8.2.70.0050.00317.75
8.2.60.0040.00417.93
8.2.50.0040.00418.07
8.2.40.0030.00518.21
8.2.30.0060.00319.97
8.2.20.0000.00717.72
8.2.10.0030.00517.84
8.2.00.0040.00417.89
8.1.280.0130.00325.92
8.1.270.0100.00323.99
8.1.260.0090.00626.35
8.1.250.0000.00928.09
8.1.240.0030.00622.55
8.1.230.0110.00020.89
8.1.220.0000.00818.77
8.1.210.0080.00018.77
8.1.200.0030.00717.48
8.1.190.0040.00417.40
8.1.180.0000.00818.10
8.1.170.0050.00318.65
8.1.160.0030.00518.82
8.1.150.0080.00018.59
8.1.140.0000.00817.53
8.1.130.0000.00717.86
8.1.120.0000.00717.47
8.1.110.0000.00817.51
8.1.100.0040.00417.41
8.1.90.0000.00717.38
8.1.80.0040.00417.48
8.1.70.0050.00317.51
8.1.60.0030.00517.61
8.1.50.0000.00817.40
8.1.40.0000.00717.41
8.1.30.0060.00317.65
8.1.20.0000.00817.64
8.1.10.0000.00717.59
8.1.00.0090.00017.50
8.0.300.0040.00419.89
8.0.290.0070.00016.63
8.0.280.0030.00318.35
8.0.270.0040.00417.34
8.0.260.0030.00316.96
8.0.250.0000.00716.93
8.0.240.0040.00716.94
8.0.230.0000.00716.93
8.0.220.0000.00716.87
8.0.210.0030.00316.98
8.0.200.0030.00317.05
8.0.190.0040.00417.08
8.0.180.0000.00717.02
8.0.170.0080.00016.95
8.0.160.0030.00316.88
8.0.150.0080.00016.98
8.0.140.0000.01016.92
8.0.130.0030.00313.37
8.0.120.0040.00416.85
8.0.110.0000.00816.92
8.0.100.0000.00716.81
8.0.90.0000.00716.94
8.0.80.0040.01117.03
8.0.70.0030.00617.09
8.0.60.0000.00817.02
8.0.50.0060.00316.78
8.0.30.0090.00917.19
8.0.20.0110.00917.40
8.0.10.0000.00817.22
8.0.00.0140.00716.99
7.4.330.0050.00014.88
7.4.320.0000.00616.62
7.4.300.0030.00316.43
7.4.290.0000.00716.60
7.4.280.0040.00416.48
7.4.270.0080.00016.64
7.4.260.0060.00013.35
7.4.250.0040.00416.45
7.4.240.0060.00316.52
7.4.230.0040.00416.41
7.4.220.0030.01316.52
7.4.210.0080.00816.55
7.4.200.0070.00016.72
7.4.190.0040.00416.50
7.4.160.0210.00016.59
7.4.150.0140.00417.40
7.4.140.0080.01217.86
7.4.130.0080.00916.59
7.4.120.0110.00716.60
7.4.110.0140.00716.48
7.4.100.0130.00316.61
7.4.90.0030.01516.50
7.4.80.0060.01019.37
7.4.70.0090.01216.66
7.4.60.0160.00016.38
7.4.50.0040.00416.66
7.4.40.0100.00722.27
7.4.30.0130.00916.50
7.4.00.0060.01015.06
7.3.330.0060.00013.20
7.3.320.0030.00313.36
7.3.310.0030.00316.27
7.3.300.0000.00716.34
7.3.290.0100.01016.39
7.3.280.0060.01316.38
7.3.270.0060.01217.40
7.3.260.0140.00418.24
7.3.250.0120.00916.36
7.3.240.0220.00016.46
7.3.230.0040.01916.61
7.3.210.0100.00716.58
7.3.200.0190.00319.39
7.3.190.0090.00916.52
7.3.180.0100.00616.48
7.3.170.0120.01116.45
7.3.160.0100.01416.40
7.3.120.0050.01214.67
7.3.110.0040.01414.83
7.3.100.0000.01414.71
7.3.90.0030.00714.81
7.3.80.0140.00314.66
7.3.70.0100.00714.85
7.3.60.0070.00714.95
7.3.50.0120.00314.86
7.3.40.0090.00314.99
7.3.30.0060.00614.84
7.3.20.0070.00716.49
7.3.10.0090.00316.31
7.3.00.0040.00816.45
7.2.330.0160.00316.53
7.2.320.0000.01716.74
7.2.310.0060.01516.73
7.2.300.0090.01216.66
7.2.290.0070.01016.56
7.2.250.0030.01215.14
7.2.240.0030.01714.90
7.2.230.0070.01115.09
7.2.220.0100.00315.14
7.2.210.0100.00715.15
7.2.200.0030.01015.17
7.2.190.0070.01014.73
7.2.180.0060.00914.97
7.2.170.0070.00314.72
7.2.60.0000.01216.95
7.2.00.0070.01319.48
7.1.330.0070.00715.88
7.1.320.0040.00815.46
7.1.310.0040.00715.46
7.1.300.0070.01015.45
7.1.290.0060.01015.77
7.1.280.0060.00615.66
7.1.270.0060.01015.74
7.1.260.0030.00615.79
7.1.200.0040.00815.73
7.1.100.0030.01318.25
7.1.70.0030.00617.05
7.1.60.0040.02119.40
7.1.50.0070.00416.86
7.1.00.0070.06022.44
7.0.200.0030.00516.87
7.0.140.0000.07722.12
7.0.60.0070.06721.72
7.0.50.0030.07322.11
7.0.40.0030.08320.06
7.0.30.0100.07320.12
7.0.20.0030.08320.03
7.0.10.0070.08020.05
7.0.00.0070.08720.07
5.6.280.0100.06721.04
5.6.210.0030.07720.46
5.6.200.0070.07320.89
5.6.190.0030.05721.03
5.6.180.0000.09021.15
5.6.170.0000.08021.10
5.6.160.0030.07721.15
5.6.150.0130.07321.05
5.6.140.0170.08020.97
5.6.130.0100.05321.00
5.6.120.0030.08021.01
5.6.110.0070.07321.05
5.6.100.0070.05020.96
5.6.90.0070.06721.06
5.6.80.0030.07720.41
5.6.70.0100.07020.44
5.6.60.0070.08020.53
5.6.50.0130.06720.53
5.6.40.0030.08320.38
5.6.30.0070.07020.49
5.6.20.0100.04020.38
5.6.10.0070.03720.39
5.6.00.0030.04020.49
5.5.350.0030.07720.34
5.5.340.0030.08320.74
5.5.330.0070.07020.66
5.5.320.0070.07720.65
5.5.310.0070.07720.78
5.5.300.0100.07320.88
5.5.290.0030.07020.81
5.5.280.0000.07320.87
5.5.270.0030.07720.98
5.5.260.0100.07020.67
5.5.250.0000.08020.67
5.5.240.0000.07720.27
5.5.230.0030.08320.29
5.5.220.0170.06720.28
5.5.210.0030.08020.34
5.5.200.0100.06720.23
5.5.190.0070.07720.16
5.5.180.0070.07320.34
5.5.160.0070.03720.09
5.5.150.0000.04020.16
5.5.140.0000.04020.25
5.5.130.0000.03320.13
5.5.120.0030.03020.16
5.5.110.0000.04020.03
5.5.100.0000.07320.24
5.5.90.0000.04720.00
5.5.80.0070.03020.02
5.5.70.0070.03020.11
5.5.60.0000.04720.21
5.5.50.0070.02720.21
5.5.40.0030.02720.01
5.5.30.0000.03320.00
5.5.20.0000.04020.00
5.5.10.0030.03020.04
5.5.00.0000.03720.06
5.4.450.0030.07319.38
5.4.440.0030.08319.23
5.4.430.0070.07019.54
5.4.420.0170.07019.24
5.4.410.0030.08019.36
5.4.400.0030.07319.00
5.4.390.0070.04319.07
5.4.380.0070.07319.01
5.4.370.0000.07719.07
5.4.360.0030.07319.04
5.4.350.0030.06018.91
5.4.340.0030.06319.05
5.4.320.0000.04018.91
5.4.310.0000.03719.12
5.4.300.0000.04019.16
5.4.290.0000.03718.91
5.4.280.0000.03319.07
5.4.270.0000.03319.01
5.4.260.0000.04019.12
5.4.250.0030.03719.11
5.4.240.0070.04319.16
5.4.230.0070.03019.00
5.4.220.0030.04018.91
5.4.210.0000.03019.02
5.4.200.0000.03018.90
5.4.190.0030.03019.02
5.4.180.0000.03019.05
5.4.170.0030.03018.90
5.4.160.0030.03019.05
5.4.150.0070.03319.18
5.4.140.0000.03016.38
5.4.130.0030.02716.31
5.4.120.0000.03316.30
5.4.110.0000.03016.52
5.4.100.0000.03016.40
5.4.90.0030.02716.43
5.4.80.0000.03016.55
5.4.70.0000.03016.41
5.4.60.0000.07716.37
5.4.50.0000.06016.41
5.4.40.0000.07316.57
5.4.30.0100.06716.35
5.4.20.0030.04316.22
5.4.10.0130.06716.51
5.4.00.0000.07715.86
5.3.290.0030.03714.64
5.3.280.0000.03014.67
5.3.270.0000.03014.66
5.3.260.0000.03314.66
5.3.250.0000.03014.66
5.3.240.0030.02714.61
5.3.230.0000.03014.66
5.3.220.0000.03014.62
5.3.210.0000.03014.53
5.3.200.0000.03314.63
5.3.190.0000.03714.63
5.3.180.0030.03014.63
5.3.170.0030.03014.61
5.3.160.0070.02714.62
5.3.150.0000.05714.68
5.3.140.0130.05314.62
5.3.130.0030.04714.41
5.3.120.0070.06714.60
5.3.110.0030.04314.52
5.3.100.0070.07014.15
5.3.90.0030.07714.04
5.3.80.0030.07713.94
5.3.70.0070.07014.11
5.3.60.0030.07314.00
5.3.50.0030.07013.97
5.3.40.0170.05314.00
5.3.30.0000.07313.96
5.3.20.0000.07313.60
5.3.10.0030.07313.74
5.3.00.0070.06313.70
5.2.170.0070.05711.21
5.2.160.0030.05711.04
5.2.150.0000.05711.13
5.2.140.0000.05711.18
5.2.130.0030.05711.10
5.2.120.0070.06011.11
5.2.110.0030.05710.96
5.2.100.0000.05711.15
5.2.90.0070.04711.19
5.2.80.0030.06310.97
5.2.70.0000.05711.15
5.2.60.0030.04011.10
5.2.50.0130.06010.89
5.2.40.0000.04311.01
5.2.30.0030.05010.96
5.2.20.0030.06011.05
5.2.10.0030.05710.93
5.2.00.0030.04710.77
5.1.60.0030.04010.07
5.1.50.0030.0539.84
5.1.40.0030.0339.89
5.1.30.0030.05310.44
5.1.20.0000.06010.45
5.1.10.0000.06010.16
5.1.00.0100.03710.07
5.0.50.0030.0438.60
5.0.40.0000.0478.60
5.0.30.0070.0608.60
5.0.20.0000.0408.60
5.0.10.0000.0438.60
5.0.00.0000.0678.60
4.4.90.0030.0308.60
4.4.80.0000.0338.60
4.4.70.0030.0278.60
4.4.60.0000.0278.60
4.4.50.0000.0178.60
4.4.40.0030.0378.60
4.4.30.0000.0338.60
4.4.20.0000.0278.60
4.4.10.0070.0238.60
4.4.00.0000.0538.60
4.3.110.0000.0378.60
4.3.100.0000.0338.60
4.3.90.0030.0308.60
4.3.80.0030.0538.60
4.3.70.0030.0338.60
4.3.60.0000.0338.60
4.3.50.0000.0378.60
4.3.40.0000.0538.60
4.3.30.0030.0278.60
4.3.20.0030.0278.60
4.3.10.0000.0338.60
4.3.00.0030.0338.60

preferences:
43.83 ms | 401 KiB | 5 Q