3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Some example variables: $alice_ecdh_secret = "Hallo"; $bob_ecdh_public = "Welt"; $message_keypair = sodium_crypto_box_keypair_from_secretkey_and_publickey( $alice_ecdh_secret, $bob_ecdh_public ); $plaintext = "This is a secret message for your eyes only."; $nonce = random_bytes(24); // And now for the actual public-key encryption step: $ciphertext = sodium_crypto_box($plaintext, $nonce, $message_keypair);

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.3.00.0000.01316.68
7.2.130.0070.00316.86
7.2.120.0030.01016.80
7.2.110.0040.00716.59
7.2.100.0000.01116.71
7.2.90.0000.01316.74
7.2.80.0040.00416.68
7.2.70.0040.00716.93
7.2.60.0080.00616.79
7.2.50.0030.00916.65
7.2.40.0040.01116.88
7.2.30.0080.00316.77
7.2.20.0050.01218.27
7.2.10.0090.00818.21
7.2.00.0060.01318.09
7.1.250.0030.00615.46
7.1.240.0060.00615.68
7.1.230.0030.00915.65
7.1.220.0030.00615.51
7.1.210.0070.00715.61
7.1.200.0130.00015.44
7.1.190.0000.01015.67
7.1.180.0060.00615.72
7.1.170.0000.00715.52
7.1.160.0030.00915.72
7.1.150.0060.00315.27
7.1.140.0080.00917.20
7.1.130.0060.00717.18
7.1.120.0060.01017.00
7.1.110.0070.00916.77
7.1.100.0050.01016.92
7.1.90.0090.01016.73
7.1.80.0060.01016.91
7.1.70.0080.00516.17
7.1.60.0180.00925.32
7.1.50.0170.00925.21
7.1.40.0180.01425.02
7.1.30.0140.01224.91
7.1.20.0240.00924.94
7.1.10.0070.01015.94
7.1.00.0100.00716.11
7.0.330.0030.00615.07
5.6.380.0100.00314.14

preferences:
35.76 ms | 401 KiB | 5 Q