3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test1() { $s = microtime(true); for($i = 0;$i < 1000000; $i++) { $a = 0b10010111100101001 + 0b11100101001100101; } return microtime(true) - $s; } function test2() { $s = microtime(true); for($i = 0;$i < 1000000; $i++) { $a = 0123123 + 023454; } return microtime(true) - $s; } function test3() { $s = microtime(true); for($i = 0;$i < 1000000; $i++) { $a = 0xFAC + 0x234; } return microtime(true) - $s; } echo 0b10010111100101001 . "\n"; echo 0b11100101001100101 . "\n"; echo test1() . "\n"; echo test2() . "\n"; echo test3() . "\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.0070.03719.61
7.1.70.0030.03917.25
7.1.60.0070.07919.46
7.1.50.0130.03517.04
7.1.00.0070.12322.36
7.0.200.0000.05516.85
7.0.140.0030.11722.07
7.0.60.0100.09319.96
7.0.50.0070.10717.94
7.0.40.0100.09719.96
7.0.30.0100.08720.20
7.0.20.0230.09020.06
7.0.10.0130.13020.12
7.0.00.0030.14020.23
5.6.280.0000.28020.79
5.6.210.0070.12720.63
5.6.200.0030.14718.16
5.6.190.0000.17020.41
5.6.180.0170.12020.52
5.6.170.0200.12720.58
5.6.160.0100.12320.52
5.6.150.0030.13718.18
5.6.140.0100.15018.18
5.6.130.0170.17318.20
5.6.120.0170.18021.00
5.6.110.0070.19021.01
5.6.100.0000.16321.05
5.6.90.0070.12321.01
5.6.80.0300.15320.44
5.6.70.4300.16720.40
5.5.350.0330.16320.50
5.5.340.0030.18018.05
5.5.330.0170.17320.27
5.5.320.0230.12320.32
5.5.310.0270.13020.25
5.5.300.0170.13018.05
5.5.290.0000.13018.04
5.5.280.0000.12720.73
5.5.270.0130.18720.68
5.5.260.0070.19320.84
5.5.250.0100.19320.78
5.5.240.0300.16720.25
5.4.450.0870.18019.55
5.4.440.0900.18719.48
5.4.430.0800.20019.52
5.4.420.0800.17719.44
5.4.410.0430.17719.39
5.4.400.0170.19718.86
5.4.390.0470.19019.27
5.4.380.0130.18318.57
5.4.370.0200.19018.80
5.4.360.0130.18318.63
5.4.350.0230.18018.76
5.4.340.0570.22018.75
5.4.320.0070.12712.51
5.4.310.0050.14112.50
5.4.300.0080.16612.51
5.4.290.0040.14812.48
5.4.280.0070.20312.39
5.4.270.0160.20612.39
5.4.260.0130.19812.39
5.4.250.0110.19212.38
5.4.240.0060.15312.39
5.4.230.0080.12812.38
5.4.220.0050.13512.38
5.4.210.0090.13612.38
5.4.200.0070.15912.38
5.4.190.0090.14612.38
5.4.180.0140.19612.37
5.4.170.0110.17712.38
5.4.160.0090.13512.38
5.4.150.0100.18812.37
5.4.140.0070.16412.06
5.4.130.0070.13912.05
5.4.120.0070.15712.01
5.4.110.0080.24312.00
5.4.100.0060.19312.00
5.4.90.0130.23412.00
5.4.80.0210.31012.00
5.4.70.0140.28611.99
5.4.60.0100.19412.00
5.4.50.0120.17712.00
5.4.40.0070.24811.98
5.4.30.0080.15711.98
5.4.20.0100.15411.98
5.4.10.0130.21311.98
5.4.00.0070.16111.47
5.3.290.0090.03712.80
5.3.280.0070.05912.71
5.3.270.0110.05412.72
5.3.260.0070.04412.72
5.3.250.0060.04012.72
5.3.240.0060.03912.72
5.3.230.0090.04012.71
5.3.220.0110.04012.68
5.3.210.0080.04112.68
5.3.200.0040.04412.68
5.3.190.0090.04112.68
5.3.180.0070.03912.67
5.3.170.0070.03912.67
5.3.160.0060.03812.68
5.3.150.0050.04012.67
5.3.140.0050.03812.66
5.3.130.0090.03712.66
5.3.120.0040.04512.66
5.3.110.0080.03912.66
5.3.100.0040.04012.13
5.3.90.0130.05512.11
5.3.80.0070.04812.09
5.3.70.0100.04512.09
5.3.60.0070.04812.08
5.3.50.0050.05612.02
5.3.40.0080.05012.02
5.3.30.0140.04211.99
5.3.20.0070.04311.76
5.3.10.0060.03511.74
5.3.00.0140.05011.73
5.2.170.0060.0329.22
5.2.160.0030.0439.22
5.2.150.0090.0359.22
5.2.140.0100.0399.21
5.2.130.0060.0289.18
5.2.120.0060.0309.18
5.2.110.0090.0319.18
5.2.100.0070.0269.18
5.2.90.0050.0299.18
5.2.80.0040.0359.17
5.2.70.0040.0339.17
5.2.60.0030.0329.13
5.2.50.0040.0319.09
5.2.40.0060.0319.07
5.2.30.0030.0349.05
5.2.20.0050.0289.04
5.2.10.0040.0288.95
5.2.00.0050.0288.81
5.1.60.0050.0248.09
5.1.50.0030.0278.09
5.1.40.0070.0288.07
5.1.30.0060.0278.42
5.1.20.0040.0278.44
5.1.10.0040.0268.17
5.1.00.0030.0268.16
5.0.50.0030.0236.64
5.0.40.0060.0256.50
5.0.30.0060.0576.32
5.0.20.0030.0316.29
5.0.10.0050.0326.26
5.0.00.0040.0446.26
4.4.90.0080.0224.78
4.4.80.0030.0164.75
4.4.70.0040.0174.76
4.4.60.0040.0184.75
4.4.50.0040.0194.77
4.4.40.0020.0314.71
4.4.30.0040.0154.76
4.4.20.0040.0234.84
4.4.10.0070.0524.85
4.4.00.0040.0344.75
4.3.110.0050.0384.67
4.3.100.0050.0204.66
4.3.90.0030.0174.64
4.3.80.0020.0274.58
4.3.70.0040.0144.63
4.3.60.0010.0204.63
4.3.50.0040.0164.63
4.3.40.0020.0264.54
4.3.30.0010.0183.30
4.3.20.0010.0173.27
4.3.10.0020.0163.25
4.3.00.0000.02010.54

preferences:
39.03 ms | 400 KiB | 5 Q