3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test1() { $s = microtime(true); $a = 15484; for ($i = 0; $i < 1000000; $i++) { $b = $a / 2; } return microtime(true) - $s; } function test2() { $s = microtime(true); $a = 15484; for ($i = 0; $i < 1000000; $i++) { $b = $a / 2; } return microtime(true) - $s; } echo test1()."\n"; echo test2()."\n";

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.2.00.0000.09219.38
7.1.70.0000.08217.34
7.1.60.0100.13719.46
7.1.50.0130.07434.80
7.1.00.0030.17722.35
7.0.200.0030.08316.83
7.0.140.0000.19721.91
7.0.100.0300.14319.97
7.0.90.0000.12019.95
7.0.80.0030.14319.98
7.0.70.0100.10719.90
7.0.60.0130.16020.07
7.0.50.0130.12720.32
7.0.40.0070.14720.17
7.0.30.0170.16319.95
7.0.20.0000.09720.09
7.0.10.0070.13020.12
7.0.00.0300.07320.07
5.6.250.0130.18320.54
5.6.240.0070.14720.55
5.6.230.0070.19320.60
5.6.220.0030.20020.50
5.6.210.0030.17720.50
5.6.200.0070.20320.96
5.6.190.0070.16021.02
5.6.180.0070.17321.09
5.6.170.0070.23321.11
5.6.160.0130.16021.02
5.6.150.0030.14021.04
5.6.140.0030.20321.12
5.6.130.0000.14721.03
5.6.120.0000.15321.05
5.6.110.0100.19321.00
5.6.100.0030.15721.01
5.6.90.0070.20020.98
5.6.80.0100.12720.39
5.6.70.0070.18720.40
5.6.60.0100.11720.43
5.6.50.0100.15020.41
5.6.40.0130.19320.47
5.6.30.0030.18020.54
5.6.20.0030.14720.46
5.6.10.0030.20720.30
5.6.00.0100.20720.28
5.5.380.0030.21720.50
5.5.370.0070.14020.52
5.5.360.0030.17320.35
5.5.350.0100.21020.38
5.5.340.0100.15020.89
5.5.330.0030.21720.77
5.5.320.0030.12720.80
5.5.310.0030.17720.93
5.5.300.0130.15020.80
5.5.290.0030.13020.83
5.5.280.0070.22720.89
5.5.270.0230.11320.75
5.5.260.0070.12320.75
5.5.250.0100.18320.62
5.5.240.0030.19020.27
5.5.230.0000.13020.18
5.5.220.0070.20720.23
5.5.210.0030.20020.14
5.5.200.0130.19020.26
5.5.190.0070.18320.26
5.5.180.0030.18720.27
5.5.160.0030.18320.13
5.5.150.0070.14020.19
5.5.140.0000.14020.27
5.5.130.0100.12719.96
5.5.120.0030.11720.13
5.5.110.0000.11720.27
5.5.100.0070.11320.11
5.5.90.0030.12020.02
5.5.80.0030.11320.10
5.5.70.0070.11320.15
5.5.60.0030.13020.09
5.5.50.0030.11320.09
5.5.40.0030.11720.09
5.5.30.0100.11720.07
5.5.20.0270.12720.15
5.5.10.0070.11320.06
5.5.00.0030.12320.09
5.4.450.0070.17319.38
5.4.440.0070.13719.38
5.4.430.0000.12319.54
5.4.420.0070.17019.19
5.4.410.0000.20319.11
5.4.400.0030.12719.17
5.4.390.0030.17719.05
5.4.380.0130.18718.94
5.4.370.0130.18318.88
5.4.360.0070.20019.20
5.4.350.0030.16718.85
5.4.340.0030.12019.16
5.4.320.0000.15719.05
5.4.310.0070.14019.10
5.4.300.0030.11319.20
5.4.290.0130.12719.14
5.4.280.0030.11019.04
5.4.270.0030.11019.02
5.4.260.0000.11718.88
5.4.250.0070.10718.87
5.4.240.0000.12019.15
5.4.230.0000.12019.04
5.4.220.0070.11019.11
5.4.210.0000.11719.13
5.4.200.0070.10719.08
5.4.190.0030.11018.98
5.4.180.0100.17719.11
5.4.170.0100.17719.11
5.4.160.0000.12318.89
5.4.150.0000.12019.14
5.4.140.0070.20716.55
5.4.130.0000.17316.46
5.4.120.0070.18716.46
5.4.110.0030.17316.59
5.4.100.0130.17716.46
5.4.90.0000.17716.55
5.4.80.0000.19716.51
5.4.70.0030.13316.57
5.4.60.0070.19016.32
5.4.50.0100.19016.40
5.4.40.0200.11016.46
5.4.30.0200.18316.31
5.4.20.0070.11716.40
5.4.10.0300.16316.47
5.4.00.0070.18715.85
5.3.290.0030.21714.72
5.3.280.0000.13014.61
5.3.270.0000.16314.53
5.3.260.0030.13714.53
5.3.250.0070.17714.75
5.3.240.0070.14714.72
5.3.230.0070.20314.61
5.3.220.0100.15714.49
5.3.210.0100.19314.68
5.3.200.0030.21014.50
5.3.190.0100.23014.51
5.3.180.0030.22314.55
5.3.170.0100.15314.53
5.3.160.0030.13714.58
5.3.150.0270.15014.49
5.3.140.0070.13714.69
5.3.130.0130.20014.59
5.3.120.0070.18714.57
5.3.110.0130.20014.52
5.3.100.0030.20314.01
5.3.90.0400.13714.08
5.3.80.0030.23314.08
5.3.70.0000.18014.10
5.3.60.0130.21714.04
5.3.50.0030.15713.96
5.3.40.0100.20713.86
5.3.30.0030.17313.97
5.3.20.0070.22713.84
5.3.10.0070.20713.58
5.3.00.0070.20013.55
5.2.170.0000.23011.25
5.2.160.0000.24011.16
5.2.150.0130.22311.08
5.2.140.0030.17711.20
5.2.130.0000.23711.01
5.2.120.0030.16011.01
5.2.110.0000.23311.14
5.2.100.0100.19310.99
5.2.90.0000.16711.17
5.2.80.0000.22311.20
5.2.70.0000.15711.00
5.2.60.0000.22311.05
5.2.50.0000.17011.02
5.2.40.0000.17311.06
5.2.30.0070.20310.95
5.2.20.0100.14011.08
5.2.10.0000.21710.93
5.2.00.0000.22010.58
5.1.60.0100.21310.05
5.1.50.0030.2479.84
5.1.40.0030.2139.97
5.1.30.0000.14310.29
5.1.20.0070.23310.44
5.1.10.0000.17010.17
5.1.00.0000.16010.15
5.0.50.0000.4038.66
5.0.40.0000.3338.51
5.0.30.0000.2908.47
5.0.20.0030.3678.47
5.0.10.0030.3778.47
5.0.00.0000.3538.47
4.4.90.0000.3278.47
4.4.80.0000.3138.47
4.4.70.0070.3478.47
4.4.60.0000.3478.47
4.4.50.0000.3008.47
4.4.40.0030.3878.47
4.4.30.0000.2778.47
4.4.20.0000.3478.47
4.4.10.0030.3738.47
4.4.00.0030.3808.47
4.3.110.0070.3678.47
4.3.100.0030.2738.47
4.3.90.0070.3378.47
4.3.80.0030.3438.47
4.3.70.0030.3708.47
4.3.60.0000.3478.47
4.3.50.0000.3838.47
4.3.40.0000.3008.47
4.3.30.0030.3378.47
4.3.20.0030.2778.47
4.3.10.0000.3478.47
4.3.00.0000.2708.47

preferences:
34.54 ms | 400 KiB | 5 Q