3v4l.org

run code in 300+ PHP versions simultaneously
<?php $options = ['cost' => 7,'salt' => 'BCryptRequires22Chrcts']; $hash['hash'][] = password_hash("rasmuslerdorf", PASSWORD_BCRYPT, $options); //"$2y$07$BCryptRequires22Chrcte/VlQH0piJtjXl.0t1XkA8pw9dMXTpOq" $hash['hash'][] = password_hash("rasmuslerdorf", PASSWORD_DEFAULT); //"$2y$10$hHi0De9WN.HL6.Fz1ElvbOMIU5NA0tetwdJzNziKJvHFXFqOxsybi" $hash['info'][] = password_get_info($hash['hash'][0]); //array("algo" => 1 , "algoName" => "bcrypt" , "options" => array("cost" => 7 )) $hash['info'][] = password_get_info($hash['hash'][1]); //array("algo" => 1 , "algoName" => "bcrypt" , "options" => array("cost" => 10 )) $hash['rehash'][] = password_needs_rehash($hash['hash'][0],PASSWORD_BCRYPT,$options); //false $hash['rehash'][] = password_needs_rehash($hash['hash'][0],PASSWORD_DEFAULT); //true $hash['rehash'][] = password_needs_rehash($hash['hash'][1],PASSWORD_DEFAULT); //false $hash['pas_verify'][] = password_verify('rasmuslerdorf', $hash['hash'][0]); //true $hash['pas_verify'][] = password_verify('rasmuslerdorf', $hash['hash'][1]); //true $hash['pas_verify'][] = password_verify('rasmuslerdorff', $hash['hash'][0]); //false $hash['pas_verify'][] = password_verify('rasmuslerdorff', $hash['hash'][1]); //false var_dump($hash);

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)
7.4.10.0070.23015.15
7.4.00.0030.22014.91
7.3.130.0030.23014.93
7.3.120.0130.21314.79
7.3.110.0070.22714.81
7.3.100.0070.22514.90
7.3.90.0030.21815.00
7.3.80.0000.22515.05
7.3.70.0100.21514.89
7.3.60.0130.20614.97
7.3.50.0070.20914.85
7.3.40.0070.21214.70
7.3.30.0100.20214.80
7.3.20.0000.21916.70
7.3.10.0030.20616.48
7.3.00.0070.21416.69
7.2.260.0070.23015.11
7.2.250.0100.22514.75
7.2.240.0030.22215.12
7.2.230.0030.22915.05
7.2.220.0070.21615.11
7.2.210.0030.21615.01
7.2.200.0130.21814.97
7.2.190.0030.22714.89
7.2.180.0030.21115.00
7.2.170.0000.22414.91
7.2.160.0030.21915.14
7.2.150.0070.21616.76
7.2.140.0070.20616.61
7.2.130.0070.21717.07
7.2.120.0030.20916.88
7.2.110.0150.21216.64
7.2.100.0070.20716.76
7.2.90.0070.20616.92
7.2.80.0070.20316.87
7.2.70.0070.22416.92
7.2.60.0030.22216.78
7.2.50.0070.21016.91
7.2.40.0100.21116.50
7.2.30.0070.20716.96
7.2.20.0030.21716.72
7.2.10.0030.20816.68
7.2.00.0030.21818.05
7.1.330.0070.22115.80
7.1.320.0000.22515.68
7.1.310.0100.21615.60
7.1.300.0070.21315.64
7.1.290.0070.19915.96
7.1.280.0130.21715.66
7.1.270.0000.21815.77
7.1.260.0030.21715.81
7.1.250.0070.21315.55
7.1.240.0030.21215.69
7.1.230.0030.21515.77
7.1.220.0030.21515.80
7.1.210.0030.21615.71
7.1.200.0050.21415.72
7.1.190.0030.22115.88
7.1.180.0000.22415.91
7.1.170.0070.21215.79
7.1.160.0000.20915.62
7.1.150.0000.22215.83
7.1.140.0000.21515.77
7.1.130.0000.21715.71
7.1.120.0030.20915.46
7.1.110.0030.22515.66
7.1.100.0080.21517.08
7.1.90.0030.21615.81
7.1.80.0070.21115.87
7.1.70.0030.21216.53
7.1.60.0020.21717.41
7.1.50.0050.24416.17
7.1.40.0000.20915.93
7.1.30.0030.21715.97
7.1.20.0030.21315.62
7.1.10.0030.21215.68
7.1.00.0050.26019.00
7.0.330.0030.21815.44
7.0.320.0030.20915.34
7.0.310.0030.20715.22
7.0.300.0070.20215.53
7.0.290.0030.21215.34
7.0.280.0030.21315.49
7.0.270.0030.20515.30
7.0.260.0100.22015.22
7.0.250.0030.21215.30
7.0.240.0030.20615.41
7.0.230.0030.21015.48
7.0.220.0030.20815.40
7.0.210.0070.20315.57
7.0.200.0200.21116.19
7.0.190.0070.21215.43
7.0.180.0070.21315.44
7.0.170.0070.20915.37
7.0.160.0000.21615.32
7.0.150.0100.20415.41
7.0.140.0020.26118.84
7.0.130.0070.20615.52
7.0.120.0070.22315.53
7.0.110.0070.20615.36
7.0.100.0000.21215.58
7.0.90.0070.20715.46
7.0.80.0070.21215.31
7.0.70.0000.20815.23
7.0.60.0070.24717.55
7.0.50.0030.22416.65
7.0.40.0070.23116.81
7.0.30.0470.24216.78
7.0.20.0150.23516.76
7.0.10.0030.23416.81
7.0.00.0080.25116.85
5.6.400.0000.22614.36
5.6.390.0100.20814.62
5.6.380.0030.21914.67
5.6.370.0000.21514.54
5.6.360.0070.20614.19
5.6.350.0030.20914.46
5.6.340.0070.20514.61
5.6.330.0100.20214.37
5.6.320.0000.21314.43
5.6.310.0030.21614.61
5.6.300.0030.20614.59
5.6.290.0030.21014.52
5.6.280.0070.27117.81
5.6.270.0070.21014.42
5.6.260.0100.20414.47
5.6.250.0070.20714.38
5.6.240.0070.20514.29
5.6.230.0030.20714.17
5.6.220.0030.21014.43
5.6.210.0080.22917.40
5.6.200.0080.23316.33
5.6.190.0120.25517.41
5.6.180.0070.26217.37
5.6.170.0150.27017.36
5.6.160.0030.23717.36
5.6.150.0050.25416.33
5.6.140.0050.23316.31
5.6.130.0150.24716.19
5.6.120.0020.26317.73
5.6.110.0130.25017.71
5.6.100.0030.24417.77
5.6.90.0080.25517.84
5.6.80.0080.22617.32
5.6.70.2170.21917.29
5.6.60.0030.20914.32
5.6.50.0030.21514.21
5.6.40.0030.20714.34
5.6.30.0070.20214.43
5.6.20.0070.20314.55
5.6.10.0030.21214.38
5.6.00.0000.21814.18
5.5.380.0000.20814.19
5.5.370.0070.20214.19
5.5.360.0100.20914.11
5.5.350.0070.26317.49
5.5.340.0050.25916.25
5.5.330.0070.26217.29
5.5.320.0230.24717.44
5.5.310.0100.23317.34
5.5.300.0050.25316.21
5.5.290.0080.22416.06
5.5.280.0070.25717.55
5.5.270.0080.25617.60
5.5.260.0030.25917.54
5.5.250.0070.23517.43
5.5.240.0130.21017.24
5.5.230.0030.22614.00
5.5.220.0070.20314.43
5.5.210.0030.20914.16
5.5.200.0030.21214.37
5.5.190.0100.20014.41
5.5.180.0070.21214.20
5.5.170.0000.21114.49
5.5.160.0030.20814.29
5.5.150.0000.22014.37
5.5.140.0000.22014.38
5.5.130.0100.19714.21
5.5.120.0030.21114.46
5.5.110.0070.20414.39
5.5.100.0030.20814.39
5.5.90.0070.21114.35
5.5.80.0070.20114.38
5.5.70.0000.20914.47
5.5.60.0030.20914.38
5.5.50.0000.21814.52
5.5.40.0070.20814.10
5.5.30.0030.21214.42
5.5.20.0030.20814.33
5.5.10.0100.20014.18
5.5.00.0030.20613.99
5.4.450.0180.03515.21
5.4.440.0130.03815.16
5.4.430.0130.03515.15
5.4.420.0120.02814.97
5.4.410.0190.02315.01
5.4.400.0110.02115.06
5.4.390.0130.03814.93
5.4.380.0160.02115.07
5.4.370.0100.02415.07
5.4.360.0190.03214.90
5.4.350.0150.03715.05
5.4.340.0120.02714.95
5.4.330.0030.00610.86
5.4.320.0140.02514.98
5.4.310.0170.03514.97
5.4.300.0100.04015.05
5.4.290.0150.03314.78
5.4.280.0120.02414.92
5.4.270.0130.03014.96
5.4.260.0170.03414.85
5.4.250.0100.02315.13
5.4.240.0080.02214.87
5.4.230.0150.03114.73
5.4.220.0180.03614.74
5.4.210.0150.04015.01
5.4.200.0150.02714.91
5.4.190.0080.02815.01
5.4.180.0150.03914.87
5.4.170.0100.03314.90
5.4.160.0100.03214.88
5.4.150.0150.04014.91
5.4.140.0120.03213.71
5.4.130.0150.04013.62
5.4.120.0150.03013.59
5.4.110.0180.03013.63
5.4.100.0170.03513.63
5.4.90.0160.03813.56
5.4.80.0120.03513.63
5.4.70.0150.02713.67
5.4.60.0080.02313.50
5.4.50.0100.02113.49
5.4.40.0080.02213.59
5.4.30.0130.01813.65
5.4.20.0120.01813.60
5.4.10.0080.02513.61
5.4.00.0060.02413.18
5.3.290.0180.03712.37
5.3.280.0120.03912.31
5.3.270.0130.03912.46
5.3.260.0100.03412.29
5.3.250.0150.03212.42
5.3.240.0090.02512.31
5.3.230.0140.04212.42
5.3.220.0110.02612.29
5.3.210.0130.02412.34
5.3.200.0100.02812.29
5.3.190.0170.03012.34
5.3.180.0150.03512.33
5.3.170.0140.03112.40
5.3.160.0140.02112.38
5.3.150.0090.02512.35
5.3.140.0150.01712.28
5.3.130.0120.02012.30
5.3.120.0100.02212.37
5.3.110.0160.01712.32
5.3.100.0140.02312.09
5.3.90.0070.02112.14
5.3.80.0100.02012.01
5.3.70.0120.02012.03
5.3.60.0090.02012.18
5.3.50.0100.01711.97
5.3.40.0080.02212.04
5.3.30.0130.01811.92
5.3.20.0110.01611.90
5.3.10.0060.02211.89
5.3.00.0110.02011.82
5.2.170.0130.02712.12
5.2.160.0130.02712.12
5.2.150.0100.03012.12
5.2.140.0100.03312.12
5.2.130.0200.02012.12
5.2.120.0100.03312.12
5.2.110.0170.02312.12
5.2.100.0100.03012.12
5.2.90.0130.02712.12
5.2.80.0130.03312.12
5.2.70.0100.03312.12
5.2.60.0100.03012.12
5.2.50.0130.03312.12
5.2.40.0200.05012.12
5.2.30.0070.03712.12
5.2.20.0130.02312.12
5.2.10.0130.02312.12
5.2.00.0130.02312.12
5.1.60.0130.02312.12
5.1.50.0130.03712.12
5.1.40.0070.03012.12
5.1.30.0100.02312.12
5.1.20.0070.02712.12
5.1.10.0070.02712.12
5.1.00.0100.02312.12
5.0.50.0100.01312.12
5.0.40.0070.02312.12
5.0.30.0130.06012.12
5.0.20.0070.04012.12
5.0.10.0130.04012.12
5.0.00.0070.06712.12
4.4.90.0070.01312.12
4.4.80.0030.01712.12
4.4.70.0070.01712.12
4.4.60.0030.02312.12
4.4.50.0030.01312.12
4.4.40.0030.02312.12
4.4.30.0070.01312.12
4.4.20.0030.02012.12
4.4.10.0070.01312.12
4.4.00.0070.02712.12
4.3.110.0070.01712.12
4.3.100.0100.03312.12
4.3.90.0100.03312.12
4.3.80.0100.04312.12
4.3.70.0130.02712.12
4.3.60.0130.03012.12
4.3.50.0070.03712.12
4.3.40.0100.04712.12
4.3.30.0000.03312.12
4.3.20.0000.04012.12
4.3.10.0030.03312.12
4.3.00.0070.02712.12

preferences:
39.74 ms | 401 KiB | 5 Q