3v4l.org

run code in 300+ PHP versions simultaneously
<?php $times = 1000*100*10; $var = null; $var = 10; $var2 = '10'; $time1 = microtime(true); for ($i = 0; $i <= $times; $i++) { if ($var != $var2) {} } $time1 = microtime(true) - $time1; //echo "Time using '!': $time1\n"; $time2 = microtime(true); for ($i = 0; $i <= $times; $i++) { if ($var !== $var2) {} } $time2 = microtime(true) - $time2; //echo "Time using '===': $time2\n"; if ($time1 > $time2){ $p = (($time1-$time2)/$time2) * 100; //printf("'===' was faster by %.2f percent.", $p); printf("'!==' was faster"); } else { $p = (($time2-$time1)/$time1) * 100; //printf("'==' was faster by %.2f percent.", $p); printf("'!=' was faster"); }

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.4.00.0070.07114.73
7.3.120.0100.10714.86
7.3.110.0030.11314.82
7.3.100.0100.10814.86
7.3.90.0030.06114.49
7.3.80.0030.06414.92
7.3.70.0100.09614.93
7.3.60.0100.05914.77
7.3.50.0030.07314.92
7.3.40.0070.06314.78
7.3.30.0030.07214.73
7.3.20.0030.07716.69
7.3.10.0060.07116.49
7.3.00.0110.06716.48
7.2.250.0130.09315.18
7.2.240.0160.05815.03
7.2.230.0070.07215.01
7.2.220.0030.05615.23
7.2.210.0100.07714.84
7.2.200.0070.09714.99
7.2.190.0100.05715.00
7.2.180.0030.08714.90
7.2.170.0070.08514.98
7.2.160.0100.05715.04
7.2.150.0030.06316.88
7.2.140.0000.06116.67
7.2.130.0080.06516.68
7.2.120.0040.07516.64
7.2.110.0100.08016.67
7.2.100.0110.06616.78
7.2.90.0080.06316.68
7.2.80.0150.06716.79
7.2.70.0070.06216.67
7.2.60.0110.08116.79
7.2.50.0050.07716.60
7.2.40.0100.08016.83
7.2.30.0090.06016.58
7.2.20.0090.07916.56
7.2.10.0090.06316.75
7.2.00.0100.06116.86
7.1.330.0030.14715.86
7.1.320.0030.16115.96
7.1.310.0100.15815.84
7.1.300.0000.12515.87
7.1.290.0070.12915.87
7.1.280.0030.12015.67
7.1.270.0030.11915.88
7.1.260.0000.12115.79
7.1.250.0060.12915.65
7.1.240.0070.15615.86
7.1.230.0000.15915.46
7.1.220.0000.13415.95
7.1.210.0030.13315.80
7.1.200.0000.13415.73
7.1.190.0030.13115.96
7.1.180.0130.16115.76
7.1.170.0000.13515.75
7.1.160.0070.15115.98
7.1.150.0070.12315.71
7.1.140.0030.16015.74
7.1.130.0030.11215.77
7.1.120.0000.13115.45
7.1.110.0070.11115.94
7.1.100.0100.12215.96
7.1.90.0000.17815.76
7.1.80.0070.13715.92
7.1.70.0030.08816.40
7.1.60.0050.11917.63
7.1.50.0120.08116.43
7.1.40.0030.17215.66
7.1.30.0000.12515.91
7.1.20.0030.11116.02
7.1.10.0070.12515.80
7.1.00.0050.17119.00
7.0.330.0070.12615.51
7.0.320.0070.12915.43
7.0.310.0030.14615.27
7.0.300.0070.12115.33
7.0.290.0030.13215.46
7.0.280.0030.15915.47
7.0.270.0100.13815.63
7.0.260.0070.12415.51
7.0.250.0030.17515.34
7.0.240.0030.16915.29
7.0.230.0070.13115.29
7.0.220.0000.11215.50
7.0.210.0030.11815.37
7.0.200.0020.09215.96
7.0.190.0000.14915.22
7.0.180.0030.12815.60
7.0.170.0000.11415.51
7.0.160.0030.12715.21
7.0.150.0070.16115.30
7.0.140.0050.13618.86
7.0.130.0070.10615.19
7.0.120.0000.15215.45
7.0.110.0000.15215.47
7.0.100.0070.14815.48
7.0.90.0030.15315.45
7.0.80.0000.11115.46
7.0.70.0030.12115.32
7.0.60.0050.12417.75
7.0.50.0080.10616.58
7.0.40.0080.14515.59
7.0.30.0080.13815.52
7.0.20.0070.14915.58
7.0.10.0050.11515.57
7.0.00.0050.13115.58
5.6.400.0000.29614.51
5.6.390.0030.32014.23
5.6.380.0070.26914.51
5.6.370.0030.28114.19
5.6.360.0030.25914.41
5.6.350.0100.25314.58
5.6.340.0030.26614.47
5.6.330.0070.31913.92
5.6.320.0100.28514.19
5.6.310.0030.30114.62
5.6.300.0030.32914.61
5.6.290.0030.28014.52
5.6.280.0050.24317.65
5.6.270.0070.25114.21
5.6.260.0070.30314.16
5.6.250.0070.26214.25
5.6.240.0030.29414.11
5.6.230.0030.26814.17
5.6.220.0030.32914.43
5.6.210.0030.23617.43
5.6.200.0080.25216.17
5.6.190.0050.20416.29
5.6.180.0050.22416.25
5.6.170.0070.22116.31
5.6.160.0070.21616.32
5.6.150.0030.21316.27
5.6.140.0070.21016.15
5.6.130.0080.23416.05
5.6.120.0050.23816.37
5.6.110.0100.27016.36
5.6.100.0070.25116.29
5.6.90.0120.22216.06
5.6.80.0050.25215.91
5.6.70.0080.22216.01
5.6.60.0080.22615.86
5.6.50.0050.25016.02
5.6.40.0030.24015.85
5.6.30.0030.21215.91
5.6.20.0050.21015.81
5.6.10.0070.23915.74
5.6.00.0050.24615.88
5.5.380.0030.27414.20
5.5.370.0030.29314.25
5.5.360.0030.32514.23
5.5.350.0130.24917.36
5.5.340.0100.24615.96
5.5.330.0070.21616.06
5.5.320.0100.22116.18
5.5.310.0080.23016.07
5.5.300.0070.24016.07
5.5.290.0030.20515.95
5.5.280.0020.25916.04
5.5.270.0080.25616.26
5.5.260.0030.21716.03
5.5.250.0050.21515.89
5.5.240.0050.24215.75
5.5.230.0070.21615.65
5.5.220.0030.22615.70
5.5.210.0080.23615.80
5.5.200.0070.24515.56
5.5.190.0100.23115.86
5.5.180.0050.26315.71
5.5.170.0030.27714.40
5.5.160.0030.23615.63
5.5.150.0070.22615.66
5.5.140.0020.22215.90
5.5.130.0050.20615.63
5.5.120.0100.23115.71
5.5.110.0050.23615.76
5.5.100.0050.25615.66
5.5.90.0070.24115.76
5.5.80.0030.25815.68
5.5.70.0070.24015.77
5.5.60.0070.20915.57
5.5.50.0030.21515.64
5.5.40.0030.20915.57
5.5.30.0070.25515.67
5.5.20.0070.22415.60
5.5.10.0130.20815.62
5.5.00.0070.24915.65
5.4.450.0120.25415.23
5.4.440.0030.23315.20
5.4.430.0000.23115.06
5.4.420.0070.22115.16
5.4.410.0020.23614.95
5.4.400.0020.21514.99
5.4.390.0030.23014.88
5.4.380.0050.24014.75
5.4.370.0430.22114.98
5.4.360.0080.19714.85
5.4.350.0080.23314.91
5.4.340.0000.23415.00
5.4.330.0030.30210.94
5.4.320.0050.20414.80
5.4.310.0050.21614.79
5.4.300.0050.26714.98
5.4.290.0020.19614.84
5.4.280.0050.24614.96
5.4.270.0050.21914.81
5.4.260.0070.21814.92
5.4.250.0050.24714.94
5.4.240.0030.25014.98
5.4.230.0050.18614.86
5.4.220.0080.24014.93
5.4.210.0050.24214.93
5.4.200.0020.21414.75
5.4.190.0050.23815.19
5.4.180.0050.22914.92
5.4.170.0050.22214.84
5.4.160.0050.25614.95
5.4.150.0080.25714.79
5.4.140.0020.26113.68
5.4.130.0050.22013.51
5.4.120.0030.22613.73
5.4.110.0050.20213.60
5.4.100.0080.19613.61
5.4.90.0020.21113.73
5.4.80.0030.20813.66
5.4.70.0020.22013.62
5.4.60.0020.20713.59
5.4.50.0020.20113.55
5.4.40.0070.22013.61
5.4.30.0030.19813.63
5.4.20.0030.23113.44
5.4.10.0050.20713.48
5.4.00.0050.22713.32
5.3.290.0030.27412.49
5.3.280.0070.24512.52
5.3.270.0030.24212.55
5.3.260.0070.21612.54
5.3.250.0070.23212.53
5.3.240.0020.26512.41
5.3.230.0070.21312.35
5.3.220.0050.21812.48
5.3.210.0030.24312.39
5.3.200.0020.23112.37
5.3.190.0050.22712.49
5.3.180.0020.24712.53
5.3.170.0030.24512.52
5.3.160.0000.25612.52
5.3.150.0050.25312.50
5.3.140.0070.21512.35
5.3.130.0020.24112.51
5.3.120.0030.24712.45
5.3.110.0030.24912.40
5.3.100.0050.24312.11
5.3.90.0000.22212.31
5.3.80.0000.20811.99
5.3.70.0030.20212.04
5.3.60.0020.23912.22
5.3.50.0080.22212.14
5.3.40.0100.26812.00
5.3.30.0070.24612.06
5.3.20.0120.25111.98
5.3.10.0050.25811.90
5.3.00.0050.23911.89
5.2.170.0000.21711.08
5.2.160.0000.23311.15
5.2.150.0030.17711.09
5.2.140.0000.17011.11
5.2.130.0030.24010.88
5.2.120.0070.23711.08
5.2.110.0030.19711.07
5.2.100.0030.21310.93
5.2.90.0070.21311.06
5.2.80.0000.17711.01
5.2.70.0030.20711.03
5.2.60.0030.23310.95
5.2.50.0100.17011.05
5.2.40.0100.22710.98
5.2.30.0100.22010.89
5.2.20.0030.18710.89
5.2.10.0000.21010.75
5.2.00.0000.17310.68
5.1.60.0100.17710.03
5.1.50.0030.2139.82
5.1.40.0030.2239.95
5.1.30.0070.20310.25
5.1.20.0030.22310.36
5.1.10.0030.16710.11
5.1.00.0030.23310.09
5.0.50.0030.4409.03
5.0.40.0030.4309.03
5.0.30.0000.3679.03
5.0.20.0030.4379.03
5.0.10.0000.3609.03
5.0.00.0030.4109.03
4.4.90.0000.3979.03
4.4.80.0070.4139.03
4.4.70.0030.4509.03
4.4.60.0030.4239.03
4.4.50.1000.3539.03
4.4.40.0070.4109.03
4.4.30.0070.4279.03
4.4.20.0000.4279.03
4.4.10.0030.3779.03
4.4.00.0030.4239.03
4.3.110.0000.3439.03
4.3.100.0070.4009.03
4.3.90.0030.4039.03
4.3.80.0000.3809.03
4.3.70.0000.4079.03
4.3.60.0000.4279.03
4.3.50.0100.3909.03
4.3.40.0030.3679.03
4.3.30.0000.3539.03
4.3.20.0000.3439.03
4.3.10.0000.3509.03
4.3.00.0000.3309.03

preferences:
29.58 ms | 401 KiB | 5 Q