3v4l.org

run code in 300+ PHP versions simultaneously
<?php // MD5 print("\r -- MD5 --\r"); for ($i = 0; $i < 5; $i++) { var_dump(md5('teste')); } // SHA1 print("\r -- SHA1 --\r"); for ($i = 0; $i < 5; $i++) { var_dump(sha1('teste')); } // SHA256 print("\r -- SHA256 --\r"); for ($i = 0; $i < 5; $i++) { var_dump(hash('sha256', 'teste')); } // PASSWORD API print("\r -- PASSWORD API --\r"); for ($i = 0; $i < 5; $i++) { var_dump(password_hash('teste', PASSWORD_DEFAULT)); }

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.40.0170.48419.77
7.4.10.0130.32415.48
7.4.00.0050.32615.65
7.3.130.0050.33715.51
7.3.120.0120.32415.61
7.3.110.0070.32315.39
7.3.100.0100.31315.70
7.3.90.0050.31815.51
7.3.80.0070.30415.50
7.3.70.0050.31515.63
7.3.60.0030.31115.65
7.3.50.0080.30815.33
7.3.40.0110.30715.32
7.3.30.0070.31815.37
7.3.20.0040.31216.54
7.3.10.0080.30116.46
7.3.00.0040.30116.47
7.2.260.0080.32915.69
7.2.250.0080.31815.97
7.2.240.0030.32015.66
7.2.230.0050.31315.75
7.2.220.0070.32415.95
7.2.210.0000.31315.85
7.2.200.0030.31615.78
7.2.190.0020.31115.71
7.2.180.0030.30715.61
7.2.170.0090.30415.54
7.2.160.0080.30715.52
7.2.150.0060.31316.85
7.2.140.0090.30416.83
7.2.130.0080.31116.82
7.2.120.0180.31416.23
7.2.110.0110.31116.35
7.2.100.0120.31316.35
7.2.90.0160.31816.21
7.2.80.0150.31516.28
7.2.70.0160.31116.41
7.2.60.0150.30816.48
7.2.50.0170.30416.28
7.2.40.0160.31716.36
7.2.30.0140.32116.44
7.2.20.0150.31516.47
7.2.10.0110.31316.50
7.2.00.0140.31217.00
7.1.330.0020.32216.31
7.1.320.0020.31816.49
7.1.310.0070.30816.63
7.1.300.0050.31416.50
7.1.290.0100.30016.57
7.1.280.0100.30415.61
7.1.270.0370.30215.61
7.1.260.0110.30815.73
7.1.250.0070.31015.68
7.1.240.0150.31115.29
7.1.230.0200.30915.30
7.1.220.0150.31215.37
7.1.210.0150.31215.26
7.1.200.0180.31115.26
7.1.190.0140.31215.30
7.1.180.0090.31715.20
7.1.170.0150.31315.23
7.1.160.0310.31515.27
7.1.150.0100.31415.21
7.1.140.0110.31415.22
7.1.130.0210.30615.24
7.1.120.0140.31115.16
7.1.110.0150.30915.18
7.1.100.0630.33815.33
7.1.90.0660.34815.36
7.1.80.0730.33315.46
7.1.70.0580.33515.62
7.1.60.0500.33518.16
7.1.50.0490.33517.97
7.1.40.0500.33317.98
7.1.30.0830.33320.53
7.1.20.0530.33817.97
7.1.10.0390.33615.34
7.1.00.0370.33215.32
7.0.330.0200.32313.71
7.0.320.0270.32313.50
7.0.310.0230.32014.33
7.0.300.0250.31114.03
7.0.290.0360.31413.93
7.0.280.0210.31814.04
7.0.270.0140.31214.12
7.0.260.0160.32214.11
7.0.250.0210.31714.14
7.0.240.0930.34714.68
7.0.230.1070.34814.71
7.0.220.0790.35114.59
7.0.210.0750.34714.23
7.0.200.0920.34514.75
7.0.190.1190.34514.80
7.0.180.0490.34214.63
7.0.170.1010.33914.62
7.0.160.1250.33914.58
7.0.150.0500.34014.65
7.0.140.0750.34514.61
7.0.130.0460.33614.84
7.0.120.0680.35114.66
7.0.110.0670.34714.74
7.0.100.0560.34314.72
7.0.90.0480.34814.72
7.0.80.0500.35114.62
7.0.70.0160.33914.58
7.0.60.0180.35114.59
7.0.50.0480.34314.79
7.0.40.0700.34014.13
7.0.30.0170.35114.15
7.0.20.0130.34314.08
7.0.10.0230.33714.06
7.0.00.0230.33714.06
5.6.400.0190.30513.59
5.6.390.0100.30214.43
5.6.380.0120.31614.36
5.6.370.0150.30914.40
5.6.360.0150.31614.18
5.6.350.0150.31514.39
5.6.340.0100.31614.51
5.6.330.0150.31414.56
5.6.320.0170.31614.19
5.6.310.0160.32114.43
5.6.300.0100.36116.91
5.6.290.0160.36616.90
5.6.280.0100.36117.00
5.6.270.0110.35716.91
5.6.260.0120.35716.86
5.6.250.0120.36216.94
5.6.240.0150.36616.88
5.6.230.0160.37616.96
5.6.220.0130.36117.01
5.6.210.0140.36716.88
5.6.200.0110.37416.92
5.6.190.0180.36716.96
5.6.180.0140.36016.91
5.6.170.0130.36516.81
5.6.160.0110.35616.87
5.6.150.0110.37916.99
5.6.140.0150.36316.97
5.6.130.0100.35516.97
5.6.120.0120.37416.81
5.6.110.0110.36316.90
5.6.100.0120.36616.94
5.6.90.0130.35516.95
5.6.80.0090.36216.52
5.6.70.0130.36116.66
5.6.60.0390.36316.58
5.6.50.0130.35816.54
5.6.40.0140.36416.74
5.6.30.0170.36316.62
5.6.20.0160.36216.58
5.6.10.0160.36416.53
5.6.00.0120.35416.63
5.5.380.0100.36614.69
5.5.370.0120.36214.62
5.5.360.0130.36114.56
5.5.350.0090.35714.64
5.5.340.0090.36714.82
5.5.330.0100.35514.86
5.5.320.0130.38214.79
5.5.310.0120.36514.87
5.5.300.0130.35914.71
5.5.290.0110.36114.84
5.5.280.0100.36314.80
5.5.270.0140.35914.73
5.5.260.0110.35814.80
5.5.250.0070.35614.71
5.5.240.0120.37314.46
5.5.230.0070.35814.58
5.5.220.0160.35914.53
5.5.210.0110.35814.39
5.5.200.0230.35014.51
5.5.190.0200.34814.54
5.5.180.0080.36814.52
5.5.170.0130.31014.19
5.5.160.0070.36514.49
5.5.150.0080.36614.52
5.5.140.0160.35914.50
5.5.130.0140.36014.54
5.5.120.0120.35814.48
5.5.110.0140.36214.45
5.5.100.0160.36614.52
5.5.90.0060.36014.49
5.5.80.0150.36214.43
5.5.70.0140.35714.50
5.5.60.0090.36214.45
5.5.50.0080.35814.45
5.5.40.0070.36114.48
5.5.30.0100.36314.47
5.5.20.0310.35914.49
5.5.10.0070.35814.42
5.5.00.0090.35714.38

preferences:
27.13 ms | 403 KiB | 5 Q