3v4l.org

run code in 300+ PHP versions simultaneously
<?php //require_once('./blowfish.php'); //$myfile = fopen("serial.txt", "r") or die("Unable to open file!"); $data='14700902370|0006|Renato Tarabella|renato@tarabella.it|||||'; $iv = '00000000'; // Show not be used anyway. $key = "0123456789ABCDEFF0E1D2C3B4A59687"; $encrypted=mcrypt_encrypt(MCRYPT_BLOWFISH, $key, $data, MCRYPT_MODE_CBC, $iv); $hex=str2hex($encrypted); //fclose($myfile); echo $hex; function crypted($plainText){ $cipher = mcrypt_module_open(MCRYPT_BLOWFISH, '', MCRYPT_MODE_ECB, ''); $iv = 'FEDCBA9876543210'; // Show not be used anyway. $key = "0123456789ABCDEFF0E1D2C3B4A59687"; $cipherText = ""; if (mcrypt_generic_init($cipher, $key, $iv) != -1) { $cipherText = mcrypt_generic($cipher, $plainText); mcrypt_generic_deinit($cipher); } echo str2hex($cipherText); } function str2hex($func_string) { $func_retVal = ''; $func_length = strlen($func_string); for($func_index = 0; $func_index < $func_length; ++$func_index) $func_retVal .= ((($c = dechex(ord($func_string{$func_index}))) && strlen($c) & 2) ? $c : "0{$c}"); return strtoupper($func_retVal); } function String2Hex($string){ $hex=''; for ($i=0; $i < strlen($string); $i++){ $hex .= dechex(ord($string[$i])); } return $hex; } function Hex2String($hex){ $string=''; for ($i=0; $i < strlen($hex)-1; $i+=2){ $string .= chr(hexdec($hex[$i].$hex[$i+1])); } return $string; }

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.0040.01116.50
8.3.50.0080.01021.96
8.3.40.0080.00818.67
8.3.30.0120.00318.71
8.3.20.0050.00318.83
8.3.10.0050.00223.61
8.3.00.0050.00320.84
8.2.180.0090.00916.50
8.2.170.0140.00722.96
8.2.160.0100.00320.52
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0070.00326.16
8.2.120.0040.00419.76
8.2.110.0050.00520.39
8.2.100.0000.01117.91
8.2.90.0040.00417.63
8.2.80.0030.00618.43
8.2.70.0000.00817.38
8.2.60.0080.00017.38
8.2.50.0100.00017.55
8.2.40.0050.00317.62
8.2.30.0050.00319.08
8.2.20.0040.00417.82
8.2.10.0000.00717.82
8.2.00.0000.00817.60
8.1.280.0110.00325.92
8.1.270.0040.00422.06
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0060.00323.92
8.1.230.0030.01019.16
8.1.220.0030.00517.74
8.1.210.0050.00318.77
8.1.200.0000.00917.23
8.1.190.0030.00517.13
8.1.180.0030.00518.10
8.1.170.0020.00518.88
8.1.160.0070.00020.55
8.1.150.0050.00220.18
8.1.140.0040.00419.50
8.1.130.0000.00717.58
8.1.120.0000.00717.36
8.1.110.0030.00517.30
8.1.100.0050.00317.22
8.1.90.0000.00817.22
8.1.80.0040.00417.27
8.1.70.0000.00717.33
8.1.60.0020.00517.47
8.1.50.0040.00417.31
8.1.40.0000.00817.24
8.1.30.0000.00817.58
8.1.20.0070.00017.40
8.1.10.0040.00417.29
8.1.00.0030.00617.21
8.0.300.0000.00719.55
8.0.290.0040.00416.75
8.0.280.0030.00318.27
8.0.270.0040.00417.14
8.0.260.0000.00717.14
8.0.250.0050.00316.82
8.0.240.0030.00316.91
8.0.230.0030.00316.91
8.0.220.0000.00716.88
8.0.210.0030.00316.83
8.0.200.0000.00716.87
8.0.190.0000.00716.88
8.0.180.0000.00716.88
8.0.170.0040.00416.84
8.0.160.0070.00016.81
8.0.150.0000.00716.77
8.0.140.0000.00716.74
8.0.130.0000.00613.28
8.0.120.0050.00316.73
8.0.110.0040.00416.78
8.0.100.0080.00016.88
8.0.90.0000.00716.90
8.0.80.0060.00916.84
8.0.70.0080.00016.87
8.0.60.0030.00516.84
8.0.50.0040.00416.88
8.0.30.0120.00717.07
8.0.20.0080.01117.40
8.0.10.0040.00416.93
8.0.00.0100.01016.59
7.4.330.0000.00615.55
7.4.320.0060.00016.41
7.4.300.0000.00616.52
7.4.290.0080.00016.56
7.4.280.0000.00816.62
7.4.270.0030.00316.49
7.4.260.0000.00716.66
7.4.250.0080.00016.40
7.4.240.0000.00816.68
7.4.230.0030.00316.52
7.4.220.0050.01516.64
7.4.210.0100.00816.67
7.4.200.0050.00216.42
7.4.160.0070.01116.58
7.4.150.0140.00417.40
7.4.140.0100.01117.86
7.4.130.0100.00716.55
7.4.120.0080.01116.51
7.4.110.0150.00016.46
7.4.100.0130.00416.52
7.4.90.0120.00616.43
7.4.80.0090.00619.39
7.4.70.0060.01116.53
7.4.60.0030.01916.40
7.4.50.0130.00316.61
7.4.40.0090.01316.44
7.4.30.0080.00816.46
7.4.00.0070.00715.18
7.3.330.0000.00913.30
7.3.320.0030.00313.27
7.3.310.0000.00716.34
7.3.300.0070.00016.31
7.3.290.0060.00316.16
7.3.280.0080.00916.34
7.3.270.0090.01217.40
7.3.260.0130.00716.53
7.3.250.0100.00616.44
7.3.240.0140.00716.56
7.3.230.0070.01016.58
7.3.210.0120.01216.33
7.3.200.0140.00316.46
7.3.190.0070.01416.48
7.3.180.0060.00916.34
7.3.170.0080.00816.37
7.3.160.0100.01016.36
7.3.10.0110.00416.64
7.3.00.0030.00916.52
7.2.330.0090.00916.29
7.2.320.0100.00716.53
7.2.310.0090.00816.35
7.2.300.0100.01316.61
7.2.290.0080.00816.42
7.2.130.0090.00616.59
7.2.120.0100.00716.84
7.2.110.0120.00316.48
7.2.100.0040.01116.73
7.2.90.0060.00916.64
7.2.80.0080.00416.80
7.2.70.0030.01216.74
7.2.60.0050.01016.75
7.2.50.0000.01516.44
7.2.40.0070.00816.82
7.2.30.0070.00716.76
7.2.20.0080.00416.76
7.2.10.0090.00616.69
7.2.00.0070.00316.85
7.1.250.0040.00815.69
7.1.200.0000.01415.22
7.1.100.0090.00617.63
7.1.70.0050.00217.00
7.1.60.0060.00617.26
7.1.50.0070.00316.71
7.1.40.0070.00416.48
7.1.30.0100.00316.61
7.1.20.0070.00316.66
7.1.10.0030.00716.31
7.1.00.0040.00416.50
7.0.200.0030.00516.70
7.0.190.0000.01016.66
7.0.180.0040.01116.14
7.0.170.0040.00416.20
7.0.160.0000.00816.07
7.0.150.0000.01015.91
7.0.140.0140.00316.27
7.0.130.0060.00316.24
7.0.120.0040.00416.51
7.0.110.0030.00616.19
7.0.100.0030.00616.07
7.0.90.0040.00416.25
7.0.80.0030.00516.17
7.0.70.0000.00816.30
7.0.60.0030.00515.78
7.0.50.0040.00416.36
7.0.40.0060.00615.78
7.0.30.0030.00615.78
7.0.20.0030.01015.78
7.0.10.0040.00815.78
7.0.00.0000.00715.78
5.6.300.0070.04120.79
5.6.290.0070.04320.61
5.6.280.0070.04321.02
5.6.270.0030.04120.95
5.6.260.0030.04120.99
5.6.250.0030.04321.05
5.6.240.0040.04620.98
5.6.230.0000.04520.87
5.6.220.0000.04520.88
5.6.210.0030.04820.64
5.6.200.0030.04420.83
5.6.190.0070.03720.91
5.6.180.0030.04720.84
5.6.170.0000.04320.99
5.6.160.0030.08120.96
5.6.150.0070.04020.98
5.6.140.0030.04320.99
5.6.130.0030.06120.97
5.6.120.0140.03820.77
5.6.110.0090.03820.97
5.6.100.0060.04120.82
5.6.90.0000.04520.85
5.6.80.0030.04020.29
5.6.70.0100.03520.21
5.6.60.0060.03720.39
5.6.50.0030.08220.36
5.6.40.0000.07020.12
5.6.30.0030.07820.36
5.6.20.0100.03620.20
5.6.10.0060.03920.27
5.6.00.0070.03920.35

preferences:
37.02 ms | 401 KiB | 5 Q