3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function insecureEncryptDoNotUse(string $plaintext, string $key): string { return \bin2hex( \openssl_encrypt( $plaintext, 'aes-128-ecb', $key, OPENSSL_RAW_DATA | OPENSSL_ZERO_PADDING ) ); } $key = str_repeat("3.14", 4); var_dump(insecureEncryptDoNotUse('YELLOW SUBMARINE', $key)); var_dump(insecureEncryptDoNotUse('ORANGE SUBMARINE', $key)); var_dump(insecureEncryptDoNotUse('YELLOW SUBMARINE' . 'ORANGE SUBMARINE', $key));
based on uq1BY

Here you find the average performance (time & memory) of each version. A greyed out version indicates it didn't complete successfully (based on exit-code).
Note: hhvm uses a JIT which only kicks in after a few runs. Since we run scripts only once, hhvm always runs slower.

VersionSystem time (s)User time (s)Memory (MiB)
7.1.70.0000.00917.26
7.1.60.0100.00717.27
7.1.50.0330.01732.90
7.1.40.0330.01032.43
7.1.30.0400.00732.71
7.1.20.0600.00732.95
7.1.10.0270.00714.61
7.1.00.0200.00714.64
7.0.200.0100.01016.77
7.0.190.0200.00714.86
7.0.180.0300.01314.41
7.0.170.0230.01014.48
7.0.160.0300.00014.51
7.0.150.0200.01014.28
7.0.140.0130.01314.39
7.0.130.0170.01014.60
7.0.120.0200.00714.56
7.0.110.0200.00714.46
7.0.100.0200.00714.46
7.0.90.0230.00314.61
7.0.80.0200.01014.55
7.0.70.0170.01014.44
7.0.60.0200.02014.25
7.0.50.0400.01014.68
7.0.40.0170.01014.50
7.0.30.0230.00714.52
7.0.20.0100.01314.53
7.0.10.0170.01014.63
7.0.00.0170.01014.57
hhvm-3.15.40.0330.16784.56
5.6.300.0130.05320.71
5.6.290.0000.06020.61
5.6.280.0170.04720.64
5.6.270.0170.06020.65
5.6.260.0130.07720.81
5.6.250.0030.06320.77
5.6.240.0030.06720.60
5.6.230.0030.06320.77
5.6.220.0100.06720.78
5.6.210.0130.05720.69
5.6.200.0070.06020.70
5.6.190.0130.05020.79
5.6.180.0030.06020.73
5.6.170.0170.04720.71
5.6.160.0070.06020.80
5.6.150.0100.05320.57
5.6.140.0170.04720.56
5.6.130.0130.05020.70
5.6.120.0000.06320.59
5.6.110.0100.05320.85
5.6.100.0030.06320.74
5.6.90.0170.04720.61
5.6.80.0230.04320.18
5.6.70.0100.05319.97
5.6.60.0070.06020.17
5.6.50.0030.05720.00
5.6.40.0230.04019.95
5.6.30.0070.06019.96
5.6.20.0130.05020.04
5.6.10.0000.06020.18
5.6.00.0030.06019.98