3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start = microtime(true); for($i = 1; $i <= 10000; $i++) { if(function_exists('mcrypt_encrypt')) { $bool = true; } else { $bool = false; } } $end = microtime(true); echo 'function_exists: '.($end - $start); echo PHP_EOL; $start = microtime(true); for($i = 1; $i <= 10000; $i++) { if(extension_loaded('mcrypt')) { $bool = true; } else { $bool = false; } } $end = microtime(true); echo 'extension_loaded: '.($end - $start);

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.1.100.0070.00617.36
8.0.00.0040.00618.05
7.4.330.0060.00319.52
7.4.70.0090.01216.45
7.4.60.0080.01116.36
7.4.50.0090.00916.38
7.4.40.0110.00916.40
7.4.30.0100.01016.43
7.4.20.0100.01016.35
7.4.10.0130.00916.39
7.4.00.0060.01416.49
7.3.190.0070.01416.65
7.3.180.0060.01316.33
7.3.170.0090.01116.31
7.3.160.0080.01416.38
7.3.150.0120.00816.36
7.3.140.0100.01116.35
7.3.130.0120.00816.32
7.3.120.0090.01416.32
7.3.110.0070.01416.31
7.3.100.0090.01316.32
7.3.90.0090.01116.34
7.3.80.0080.01116.37
7.3.70.0100.01116.09
7.3.60.0100.01016.07
7.3.50.0070.01216.08
7.3.40.0100.01016.10
7.3.30.0150.00616.10
7.3.20.0130.00716.05
7.3.10.0090.01016.26
7.3.00.0080.01016.20
7.2.340.0060.00616.45
7.2.310.0060.02816.66
7.2.300.0080.01116.52
7.2.290.0080.01216.72
7.2.280.0120.01116.52
7.2.270.0080.01116.55
7.2.260.0090.01316.59
7.2.250.0090.01416.58
7.2.240.0100.01216.54
7.2.230.0100.01216.55
7.2.220.0080.01316.59
7.2.210.0120.00916.56
7.2.200.0110.00916.36
7.2.190.0080.01216.39
7.2.180.0090.01016.35
7.2.170.0100.01116.35
7.2.160.0100.01016.30
7.2.150.0110.01216.39
7.2.140.0100.00916.33
7.2.130.0120.01216.51
7.2.120.0100.01016.51
7.2.110.0110.01116.48
7.2.100.0090.01016.57
7.2.90.0090.01116.52
7.2.80.0080.01216.49
7.2.70.0100.01216.48
7.2.60.0090.01116.53
7.2.50.0120.01016.51
7.2.40.0130.00916.50
7.2.30.0110.01116.53
7.2.20.0100.00916.45
7.2.10.0120.01016.52
7.2.00.0090.00916.80
7.1.330.0170.01215.59
7.1.320.0220.01215.52
7.1.310.0170.01015.56
7.1.300.0140.01115.35
7.1.290.0160.00915.25
7.1.280.0220.00915.28
7.1.270.0160.00915.24
7.1.260.0150.01215.27
7.1.250.0150.00915.42
7.1.240.0240.01215.26
7.1.230.0170.00915.29
7.1.220.0160.01115.19
7.1.210.0160.01015.27
7.1.200.0130.01415.28
7.1.190.0170.01215.19
7.1.180.0180.00915.24
7.1.170.0140.01115.22
7.1.160.0160.01115.21
7.1.150.0170.01115.21
7.1.140.0170.00815.26
7.1.130.0140.01015.30
7.1.120.0140.01115.26
7.1.110.0150.01015.20
7.1.100.0140.01015.17
7.1.90.0160.01015.27
7.1.80.0140.01215.18
7.1.70.0210.01015.25
7.1.60.0230.00815.31
7.1.50.0600.00815.31
7.1.40.0150.01315.27
7.1.30.0190.01215.28
7.1.20.0220.01015.25
7.1.10.0170.00815.41
7.1.00.0150.01215.37
7.0.330.0180.00915.01
7.0.320.0200.00914.92
7.0.310.0200.01014.94
7.0.300.0180.01014.85
7.0.290.0150.01014.96
7.0.280.0160.00914.96
7.0.270.0170.00814.97
7.0.260.0190.01014.91
7.0.250.0140.01014.94
7.0.240.0130.01114.97
7.0.230.0130.01214.96
7.0.220.0140.00915.07
7.0.210.0150.00914.85
7.0.200.0210.01115.07
7.0.190.0220.00915.03
7.0.180.0190.00915.09
7.0.170.0240.00815.12
7.0.160.0200.01215.14
7.0.150.0160.00815.16
7.0.140.0170.00915.11
7.0.130.0160.00915.20
7.0.120.0140.01115.18
7.0.110.0190.00615.17
7.0.100.0170.00715.18
7.0.90.0190.00915.23
7.0.80.0200.01015.15
7.0.70.0150.00915.12
7.0.60.0150.01015.14
7.0.50.0170.00915.22
7.0.40.0160.00915.05
7.0.30.0180.00915.00
7.0.20.0160.01115.01
7.0.10.0160.00915.01
7.0.00.0150.00815.05
5.6.400.0140.01515.55
5.6.390.0140.01615.55
5.6.380.0150.01615.60
5.6.370.0140.01615.56
5.6.360.0170.01315.59
5.6.350.0140.01515.62
5.6.340.0120.01715.63
5.6.330.0140.01315.62
5.6.320.0130.01715.71
5.6.310.0140.01515.66
5.6.300.0140.01916.17
5.6.290.0130.02216.27
5.6.280.0140.01816.31
5.6.270.0160.02216.28
5.6.260.0150.01916.33
5.6.250.0120.02016.25
5.6.240.0110.02216.20
5.6.230.0170.01716.34
5.6.220.0110.02016.25
5.6.210.0150.01916.26
5.6.200.0120.02216.29
5.6.190.0170.01716.31
5.6.180.0160.01816.38
5.6.170.0150.01716.27
5.6.160.0140.01916.17
5.6.150.0150.02116.24
5.6.140.0140.01916.21
5.6.130.0130.02116.21
5.6.120.0140.01916.25
5.6.110.0140.02016.29
5.6.100.0120.01916.24
5.6.90.0140.01716.21
5.6.80.0160.01716.22
5.6.70.0110.01916.08
5.6.60.0120.01916.16
5.6.50.0160.01616.13
5.6.40.0130.01916.08
5.6.30.0130.01916.15
5.6.20.0140.01916.04
5.6.10.0110.02016.09
5.6.00.0130.01916.19

preferences:
27.51 ms | 403 KiB | 5 Q