3v4l.org

run code in 300+ PHP versions simultaneously
<?php function signRequest($domain, $method, $public_key, $private_key, $data=array()){ $data = array_filter($data); // Normalise data if(array_key_exists('request_timestamp', $data)) { $data['request_timestamp'] = (int) $data['request_timestamp']; } ksort($data); $data = json_encode($data); $buffer = array($domain, $method, $data, $public_key); $buffer_str = implode(":", $buffer); return hash_hmac('sha256', $buffer_str, $private_key); } //echo signRequest("neom.dev", "products", "c7912e9a71d7208f", "767f791f93a272d3f4554116", []); echo time();

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.0060.01016.30
7.4.00.0050.00815.62
7.3.130.0030.01416.42
7.3.120.0050.01215.62
7.3.110.0070.00815.45
7.3.100.0020.00915.50
7.3.90.0020.00915.37
7.3.80.0040.00915.50
7.3.70.0020.01015.46
7.3.60.0100.00315.52
7.3.50.0060.00915.46
7.3.40.0040.00515.49
7.3.30.0050.01115.45
7.3.20.0050.00517.21
7.3.10.0070.01116.88
7.3.00.0030.01216.76
7.2.260.0090.00716.30
7.2.250.0080.01015.65
7.2.240.0070.01215.60
7.2.230.0050.01115.51
7.2.220.0080.00415.68
7.2.210.0070.00715.59
7.2.200.0050.00715.45
7.2.190.0050.01115.82
7.2.180.0030.01115.51
7.2.170.0060.00615.54
7.2.160.0030.00716.23
7.2.150.0060.01218.30
7.2.140.0070.01018.08
7.2.130.0080.01017.22
7.2.120.0110.00517.15
7.2.110.0080.01017.21
7.2.100.0090.00917.29
7.2.90.0100.00917.21
7.2.80.0120.00817.36
7.2.70.0100.00917.30
7.2.60.0120.00817.24
7.2.50.0070.01017.36
7.2.40.0120.00317.35
7.2.30.0090.00817.45
7.2.20.0070.00817.16
7.2.10.0080.01117.20
7.2.00.0180.00817.59
7.1.330.0030.01016.40
7.1.320.0050.00716.37
7.1.310.0040.00916.32
7.1.300.0090.00416.37
7.1.290.0060.00616.39
7.1.280.0080.00516.46
7.1.270.0030.00916.49
7.1.260.0060.00916.30
7.1.250.0090.00516.08
7.1.240.0040.00717.21
7.1.230.0070.00717.20
7.1.220.0070.01116.96
7.1.210.0090.00617.18
7.1.200.0080.00616.42
7.1.190.0090.00617.19
7.1.180.0080.00417.28
7.1.170.0040.00717.13
7.1.160.0030.01017.20
7.1.150.0030.00617.20
7.1.140.0110.00317.24
7.1.130.0130.00717.20
7.1.120.0090.00917.11
7.1.110.0000.01017.16
7.1.100.0070.00717.32
7.1.90.0810.00817.57
7.1.80.0030.01317.57
7.1.70.0090.00717.16
7.1.60.0110.00826.08
7.1.50.0140.00725.95
7.1.40.0120.00925.68
7.1.30.0130.00825.75
7.1.20.0150.00625.88
7.1.10.0060.01016.83
7.1.00.0080.00317.00
7.0.330.0040.01216.98
7.0.320.0060.00316.78
7.0.310.0070.00716.71
7.0.300.0000.01416.70
7.0.290.0030.00916.98
7.0.280.0100.00316.83
7.0.270.0070.01016.96
7.0.260.0080.00816.88
7.0.250.0030.01016.99
7.0.240.0040.01216.92
7.0.230.0740.00916.28
7.0.220.0550.01017.21
7.0.210.0110.00316.59
7.0.200.0040.00916.76
7.0.190.0060.00616.82
7.0.180.0060.00816.52
7.0.170.0080.00616.54
7.0.160.0070.00716.54
7.0.150.0020.01216.41
7.0.140.0030.00916.57
7.0.130.0050.01116.59
7.0.120.0090.00516.62
7.0.110.0050.00916.60
7.0.100.0050.01016.50
7.0.90.0070.00516.48
7.0.80.0000.01216.50
7.0.70.0040.00916.52
7.0.60.0060.00816.46
7.0.50.0020.01016.58
7.0.40.0050.00615.69
7.0.30.0030.00915.68
7.0.20.0020.00915.54
7.0.10.0060.00815.62
7.0.00.0080.00615.56
5.6.400.0040.01515.46
5.6.390.0070.00715.96
5.6.380.0060.00315.59
5.6.370.0030.01515.59
5.6.360.0100.00715.77
5.6.350.0080.00815.87
5.6.340.0040.00715.72
5.6.330.0130.00615.84
5.6.320.0070.00715.70
5.6.310.0040.00715.76
5.6.300.0030.00715.63
5.6.290.0000.01415.66
5.6.280.0000.01515.66
5.6.270.0040.00415.67
5.6.260.0030.00715.76
5.6.250.0030.01215.68
5.6.240.0000.01115.70
5.6.230.0030.01015.68
5.6.220.0030.01015.83
5.6.210.0110.00015.85
5.6.200.0040.00715.74
5.6.190.0100.00715.61
5.6.180.0100.00615.64
5.6.170.0120.00616.09
5.6.160.0070.00315.83
5.6.150.0070.00415.87
5.6.140.0090.00015.67
5.6.130.0090.00615.76
5.6.120.0120.00415.49
5.6.110.0040.01115.74
5.6.100.0070.00715.68
5.6.90.0030.00715.76
5.6.80.0070.00715.70
5.6.70.0030.01015.63
5.6.60.0000.01315.73
5.6.50.0120.00015.76
5.6.40.0060.00615.68
5.6.30.0000.01415.63
5.6.20.0060.00315.48
5.6.10.0100.00315.60
5.6.00.0030.01215.59

preferences:
36.77 ms | 401 KiB | 5 Q