3v4l.org

run code in 300+ PHP versions simultaneously
<?php /** * var hash = System.Security.Cryptography.SHA256.Create(); * hash.ComputeHash(System.Text.Encoding.Unicode.GetBytes(secretKey + guid)); * aCookie.Values[""signatur""] = Convert.ToBase64String(hash.Hash); */ // Make sure we have the same encoding on both strings. $guid = mb_convert_encoding('36a75830-be27-e111-a4dc-0050568b2fc3', 'UTF-8'); $secret = mb_convert_encoding('R3loadN3tcompanyIda', 'UTF-8'); // Generate raw/byte hash. $hash = hash('sha256', $secret . $guid, TRUE); // Get the base64 value. $signature = base64_encode($hash); print 'Hash: ' . $hash; print '<br />'; print 'Signature: ' . $signature;

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.0130.00718.18
8.3.50.0110.00521.93
8.3.40.0150.00018.58
8.3.30.0090.00618.92
8.3.20.0060.00320.16
8.3.10.0000.00821.89
8.3.00.0060.00320.69
8.2.180.0070.00716.38
8.2.170.0140.00722.96
8.2.160.0070.00719.26
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0000.00826.16
8.2.120.0080.00019.36
8.2.110.0050.00520.25
8.2.100.0070.00617.91
8.2.90.0040.00419.22
8.2.80.0080.00017.97
8.2.70.0060.00317.38
8.2.60.0000.00817.93
8.2.50.0030.00518.10
8.2.40.0030.00620.55
8.2.30.0040.00418.00
8.2.20.0000.00717.65
8.2.10.0050.00217.55
8.2.00.0080.00017.68
8.1.280.0070.01125.92
8.1.270.0050.00321.93
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0060.00323.97
8.1.230.0040.00717.70
8.1.220.0000.00717.74
8.1.210.0030.00618.77
8.1.200.0100.00017.35
8.1.190.0040.00419.32
8.1.180.0050.00318.10
8.1.170.0090.00018.43
8.1.160.0000.00722.01
8.1.150.0040.00418.59
8.1.140.0090.00317.39
8.1.130.0030.00317.84
8.1.120.0030.00317.46
8.1.110.0070.00017.33
8.1.100.0000.00717.32
8.1.90.0040.00417.33
8.1.80.0030.00317.46
8.1.70.0050.00317.41
8.1.60.0080.00017.59
8.1.50.0040.00417.37
8.1.40.0000.00817.48
8.1.30.0000.00817.63
8.1.20.0000.00817.60
8.1.10.0000.00717.44
8.1.00.0030.00617.52
8.0.300.0000.00718.77
8.0.290.0080.00016.58
8.0.280.0030.00318.50
8.0.270.0030.00317.20
8.0.260.0060.00016.88
8.0.250.0070.00016.98
8.0.240.0040.00416.88
8.0.230.0030.00517.06
8.0.220.0030.00317.00
8.0.210.0000.00717.00
8.0.200.0000.00717.05
8.0.190.0000.00817.00
8.0.180.0000.00717.02
8.0.170.0000.00816.99
8.0.160.0040.00417.04
8.0.150.0030.00316.93
8.0.140.0000.00716.84
8.0.130.0060.00013.45
8.0.120.0000.00816.92
8.0.110.0050.00216.94
8.0.100.0050.00316.75
8.0.90.0040.00416.86
8.0.80.0120.00316.95
8.0.70.0040.00416.97
8.0.60.0050.00217.07
8.0.50.0000.00716.96
8.0.30.0130.00817.15
8.0.20.0120.01017.40
8.0.10.0050.00316.82
8.0.00.0090.00916.84
7.4.330.0050.00015.00
7.4.320.0030.00316.52
7.4.300.0000.00616.57
7.4.290.0040.00416.61
7.4.280.0030.00316.48
7.4.270.0030.00316.61
7.4.260.0000.00716.51
7.4.250.0040.00416.57
7.4.240.0020.00516.53
7.4.230.0030.00316.63
7.4.220.0070.01016.46
7.4.210.0100.00616.58
7.4.200.0000.00716.48
7.4.190.0040.00416.73
7.4.160.0100.00516.41
7.4.150.0070.01017.40
7.4.140.0140.00717.86
7.4.130.0120.00516.49
7.4.120.0080.01016.49
7.4.110.0060.01016.58
7.4.100.0120.01116.30
7.4.90.0100.01316.47
7.4.80.0190.00319.39
7.4.70.0160.00316.55
7.4.60.0030.01316.38
7.4.50.0000.01016.46
7.4.40.0000.01522.77
7.4.30.0060.01016.50
7.4.00.0060.01014.90
7.3.330.0000.00613.11
7.3.320.0000.00613.16
7.3.310.0070.00016.31
7.3.300.0000.00716.22
7.3.290.0070.00716.29
7.3.280.0080.00716.27
7.3.270.0040.01217.40
7.3.260.0080.01216.51
7.3.250.0130.00316.30
7.3.240.0060.01216.42
7.3.230.0060.01516.40
7.3.210.0030.01416.55
7.3.200.0080.00819.39
7.3.190.0090.00916.38
7.3.180.0120.00816.22
7.3.170.0060.01616.29
7.3.160.0080.00816.09
7.3.120.0000.01614.78
7.3.10.0180.00316.15
7.3.00.0030.01216.43
7.2.330.0100.00716.74
7.2.320.0130.00916.66
7.2.310.0060.01116.42
7.2.300.0030.01416.48
7.2.290.0130.00316.61
7.2.130.0110.01116.57
7.2.120.0080.01216.68
7.2.110.0120.01816.73
7.2.100.0100.01316.69
7.2.90.0070.01416.67
7.2.80.0080.00816.87
7.2.70.0210.00516.80
7.2.60.0100.01016.73
7.2.50.0160.00816.97
7.2.40.0000.01816.77
7.2.30.0110.00416.49
7.2.20.0130.00616.50
7.2.10.0060.01016.63
7.2.00.0070.00716.58
7.1.250.0090.01415.73
7.1.200.0000.01415.95
7.1.70.0000.01117.20
7.1.60.0070.01719.82
7.1.50.0150.00716.99
7.1.00.0000.08022.35
7.0.200.0080.00416.82
7.0.140.0030.07322.16
7.0.60.0230.05319.86
7.0.50.0030.04017.92
7.0.40.0100.08319.91
7.0.30.0130.04720.00
7.0.20.0300.05320.04
7.0.10.0270.08020.01
7.0.00.0030.06719.99
5.6.280.0100.06721.02
5.6.210.0100.08720.64
5.6.200.0030.05318.09
5.6.190.0100.08720.57
5.6.180.4300.03020.45
5.6.170.0300.06320.41
5.6.160.0100.06320.41
5.6.150.0070.08018.18
5.6.140.0130.03318.20
5.6.130.0100.06018.21
5.6.120.0070.03720.98
5.6.110.0070.08321.04
5.6.100.0100.06320.98
5.6.90.0030.06320.94
5.6.80.0100.07720.41
5.6.70.0200.07720.33
5.5.350.0030.06720.46
5.5.340.0070.08017.92
5.5.330.0000.07320.23
5.5.320.0170.07720.24
5.5.310.0270.07720.30
5.5.300.0170.07017.92
5.5.290.0030.08017.96
5.5.280.0030.04320.64
5.5.270.0130.07720.85
5.5.260.0070.04720.86
5.5.250.0100.07720.77
5.5.240.0100.08020.14
5.4.450.2900.04319.46
5.4.440.3170.04019.48
5.4.430.4870.03319.57
5.4.420.0130.06719.37
5.4.410.3900.04019.26
5.4.400.3300.04318.89
5.4.390.3570.04319.06
5.4.380.3600.04019.09
5.4.370.3130.03318.80
5.4.360.3300.04319.18
5.4.350.3570.03319.24
5.4.340.4000.03318.75
5.4.320.4000.04019.13
5.4.310.3370.03319.16
5.4.300.3630.04319.13
5.4.290.4070.04319.06
5.4.280.4070.04019.23
5.4.270.3300.03719.13
5.4.260.3800.03719.09
5.4.250.3430.04319.04
5.4.240.3530.04319.13
5.4.230.3000.03719.12
5.4.220.3170.03018.80
5.4.210.3330.03319.21
5.4.200.3100.04018.80
5.4.190.3170.03318.78
5.4.180.3470.04018.78
5.4.170.4130.04019.09
5.4.160.4130.03719.20
5.4.150.3870.04019.06
5.4.140.3900.03316.34
5.4.130.3300.03316.54
5.4.120.3430.03316.29
5.4.110.3430.03316.38
5.4.100.3200.03316.21
5.4.90.3100.03316.21
5.4.80.3930.03316.44
5.4.70.4130.03716.38
5.4.60.3870.04016.32
5.4.50.4000.04016.41
5.4.40.3700.04016.36
5.4.30.3670.03716.46
5.4.20.3800.03316.45
5.4.10.3300.03316.04
5.4.00.4100.03315.89
5.3.290.3770.03714.54
5.3.280.3970.03714.54
5.3.270.4130.03014.63
5.3.260.3770.03714.65
5.3.250.4130.03314.65
5.3.240.3600.04014.65
5.3.230.3430.03014.55
5.3.220.3370.04014.56
5.3.210.3300.03014.52
5.3.200.3500.04014.43
5.3.190.3670.03714.47
5.3.180.3570.04314.49
5.3.170.3670.03714.59
5.3.160.4000.04014.51
5.3.150.4000.03314.40
5.3.140.3730.04314.51
5.3.130.4000.03314.39
5.3.120.4100.04314.40
5.3.110.3430.04014.50
5.3.100.3500.03714.12
5.3.90.2970.03313.97
5.3.80.3970.03314.08
5.3.70.3130.03713.82
5.3.60.3130.03713.84
5.3.50.3630.03713.99
5.3.40.3330.03713.89
5.3.30.2830.04013.85
5.3.20.3330.03313.67
5.3.10.3130.03313.55
5.3.00.3130.03313.58
5.2.170.2670.02711.00
5.2.160.2800.02710.98
5.2.150.2570.03311.29
5.2.140.2970.03310.98
5.2.130.2630.03010.94
5.2.120.2570.02711.19
5.2.110.2530.03310.94
5.2.100.2870.02011.04
5.2.90.3200.03011.25
5.2.80.2700.01711.14
5.2.70.3300.03011.18
5.2.60.2530.03010.89
5.2.50.2930.03010.95
5.2.40.2630.02710.85
5.2.30.2500.02711.06
5.2.20.2370.04010.80
5.2.10.2730.03010.77
5.2.00.2870.03310.74
5.1.60.2900.02010.07
5.1.50.2800.0239.94
5.1.40.2570.0209.91
5.1.30.0130.02310.44
5.1.20.0130.05010.30
5.1.10.0100.05310.08
5.1.00.0100.0339.94
5.0.50.0030.0338.44
5.0.40.1600.0208.40
5.0.30.1500.0308.40
5.0.20.1370.0238.40
5.0.10.1270.0178.40
5.0.00.1430.0378.40
4.4.90.1030.0208.40
4.4.80.1330.0178.40
4.4.70.1070.0138.40
4.4.60.0970.0178.40
4.4.50.1270.0178.40
4.4.40.1600.0278.40
4.4.30.1470.0238.40
4.4.20.0030.0178.40
4.4.10.0070.0308.40
4.4.00.1670.0278.40
4.3.110.1270.0178.40
4.3.100.1430.0138.40
4.3.90.1400.0138.40
4.3.80.1500.0308.40
4.3.70.1500.0178.40
4.3.60.1100.0138.40
4.3.50.1370.0208.40
4.3.40.1430.0308.40
4.3.30.0670.0208.40
4.3.20.0730.0208.40
4.3.10.0770.0178.40
4.3.00.0900.0208.40

preferences:
43.17 ms | 401 KiB | 5 Q