3v4l.org

run code in 300+ PHP versions simultaneously
<?php function _bin16dec($bin) { $num = intval($bin,2); if (0x8000 & $num) { $num = - (0x010000 - $num); } return $num; } $b = "1111111111111110"; echo _bin16dec($b);

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.0100.00718.18
8.3.50.0130.00722.90
8.3.40.0110.00418.68
8.3.30.0090.00618.62
8.3.20.0070.00020.10
8.3.10.0080.00020.36
8.3.00.0070.00320.18
8.2.180.0070.00718.29
8.2.170.0120.00322.96
8.2.160.0090.00522.26
8.2.150.0050.00324.18
8.2.140.0030.00524.66
8.2.130.0080.00020.54
8.2.120.0050.00326.35
8.2.110.0090.00021.12
8.2.100.0090.00317.80
8.2.90.0000.00819.08
8.2.80.0030.00517.97
8.2.70.0030.00517.63
8.2.60.0030.00618.03
8.2.50.0030.00518.09
8.2.40.0000.00820.64
8.2.30.0000.00719.54
8.2.20.0050.00217.67
8.2.10.0080.00018.17
8.2.00.0040.00418.01
8.1.280.0040.01125.92
8.1.270.0040.00423.73
8.1.260.0070.00028.09
8.1.250.0100.00028.09
8.1.240.0090.00024.02
8.1.230.0040.00817.76
8.1.220.0030.00517.74
8.1.210.0080.00018.77
8.1.200.0090.00017.23
8.1.190.0050.00317.23
8.1.180.0040.00418.10
8.1.170.0000.00818.66
8.1.160.0040.00420.61
8.1.150.0080.00018.73
8.1.140.0000.00819.41
8.1.130.0070.00017.68
8.1.120.0000.00717.39
8.1.110.0070.00017.34
8.1.100.0000.00717.31
8.1.90.0000.00817.44
8.1.80.0000.00817.29
8.1.70.0080.00317.27
8.1.60.0070.00017.46
8.1.50.0040.00417.40
8.1.40.0090.00017.48
8.1.30.0080.00017.66
8.1.20.0040.00417.59
8.1.10.0050.00317.36
8.1.00.0000.00717.27
8.0.300.0000.00818.77
8.0.290.0070.00016.63
8.0.280.0000.00718.34
8.0.270.0000.00717.27
8.0.260.0030.00317.18
8.0.250.0000.00716.96
8.0.240.0070.00016.92
8.0.230.0040.00416.77
8.0.220.0000.00716.70
8.0.210.0050.00216.88
8.0.200.0070.00016.89
8.0.190.0070.00016.79
8.0.180.0040.00416.75
8.0.170.0000.00716.91
8.0.160.0000.00816.91
8.0.150.0000.00716.65
8.0.140.0000.00716.75
8.0.130.0030.00313.13
8.0.120.0030.00616.82
8.0.110.0040.00416.73
8.0.100.0000.00816.62
8.0.90.0000.00716.93
8.0.80.0110.00416.81
8.0.70.0000.00716.93
8.0.60.0040.00416.67
8.0.50.0040.00416.69
8.0.30.0110.00917.20
8.0.20.0060.01217.40
8.0.10.0040.00416.84
8.0.00.0070.01116.73
7.4.330.0050.00016.66
7.4.320.0000.00616.52
7.4.300.0000.00616.56
7.4.290.0070.00016.46
7.4.280.0020.00516.48
7.4.270.0000.00616.62
7.4.260.0060.00316.39
7.4.250.0040.00416.50
7.4.240.0000.00716.64
7.4.230.0000.00716.40
7.4.220.0130.01316.66
7.4.210.0110.00616.69
7.4.200.0030.00316.62
7.4.160.0120.00316.41
7.4.150.0100.00717.40
7.4.140.0160.00817.86
7.4.130.0080.00816.50
7.4.120.0090.00916.46
7.4.110.0040.01216.46
7.4.100.0130.01016.44
7.4.90.0110.00616.63
7.4.80.0070.01519.39
7.4.70.0170.00616.44
7.4.60.0100.00716.34
7.4.50.0130.00316.37
7.4.40.0130.00316.57
7.4.30.0070.01016.52
7.4.00.0070.01015.02
7.3.330.0000.00513.13
7.3.320.0000.00513.26
7.3.310.0030.00316.32
7.3.300.0030.00316.23
7.3.290.0060.00916.27
7.3.280.0080.01116.37
7.3.270.0180.00317.40
7.3.260.0140.00316.41
7.3.250.0080.01216.31
7.3.240.0070.01016.36
7.3.230.0070.01116.45
7.3.210.0060.01016.69
7.3.200.0060.00916.29
7.3.190.0060.01216.31
7.3.180.0140.00616.59
7.3.170.0070.01016.43
7.3.160.0060.00916.31
7.2.330.0100.00616.52
7.2.320.0130.01616.77
7.2.310.0090.00916.70
7.2.300.0140.01016.80
7.2.290.0000.01716.52
7.2.60.0030.00816.75
7.2.00.0040.00719.41
7.1.200.0030.00715.90
7.1.100.0110.00417.75
7.1.70.0000.00717.07
7.1.60.0100.01419.25
7.1.50.0090.00916.93
7.1.00.0000.08022.37
7.0.200.0050.00216.70
7.0.60.0230.08021.74
7.0.50.0030.09017.82
7.0.40.0100.08720.26
7.0.30.0230.05720.07
7.0.20.0300.07320.08
7.0.10.0130.04020.34
7.0.00.0030.06320.20
5.6.280.0030.07321.03
5.6.210.0030.04320.66
5.6.200.0100.08018.24
5.6.190.0100.08720.42
5.6.180.0170.04720.33
5.6.170.0330.04320.77
5.6.160.0000.08720.52
5.6.150.0100.04318.14
5.6.140.0100.07718.28
5.6.130.0070.08018.15
5.6.120.0100.06721.14
5.6.110.0070.03720.96
5.6.100.0100.07020.94
5.6.90.0030.06021.00
5.6.80.0130.07320.29
5.5.350.0430.06020.49
5.5.340.0000.04717.98
5.5.330.0130.07320.27
5.5.320.0230.05020.24
5.5.310.0230.05720.41
5.5.300.0000.06317.97
5.5.290.0000.06717.98
5.5.280.0200.07020.88
5.5.270.0130.07720.93
5.5.260.0030.07720.97
5.5.250.0130.07020.68
5.5.240.0300.05720.36

preferences:
58.01 ms | 401 KiB | 5 Q