3v4l.org

run code in 300+ PHP versions simultaneously
<?php function api_encode_uid($uid) { $sid = ($uid & 0x0000ff00)<< 16; $sid += (($uid & 0xff000000)>> 8)& 0x00ff0000; $sid += ($uid & 0x000000ff)<< 8; $sid += ($uid & 0x00ff0000)>> 16; $sid ^= 282335; return $sid; }

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.0070.00718.21
8.3.50.0140.00320.96
8.3.40.0180.00018.67
8.3.30.0110.00719.04
8.3.20.0000.00720.34
8.3.10.0040.00423.48
8.3.00.0080.00019.25
8.2.180.0130.00318.29
8.2.170.0090.00622.96
8.2.160.0110.00320.38
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0000.00726.16
8.2.120.0080.00022.05
8.2.110.0060.00320.15
8.2.100.0090.00317.78
8.2.90.0000.00719.09
8.2.80.0040.00417.97
8.2.70.0050.00317.50
8.2.60.0060.00317.68
8.2.50.0040.00418.07
8.2.40.0040.00419.82
8.2.30.0050.00217.94
8.2.20.0030.00517.57
8.2.10.0050.00217.86
8.2.00.0040.00417.61
8.1.280.0100.00725.92
8.1.270.0060.00321.95
8.1.260.0000.00826.35
8.1.250.0070.00028.09
8.1.240.0060.00324.02
8.1.230.0070.00319.09
8.1.220.0040.00417.74
8.1.210.0050.00318.77
8.1.200.0050.00517.10
8.1.190.0050.00217.10
8.1.180.0050.00218.10
8.1.170.0000.00818.51
8.1.160.0000.00921.92
8.1.150.0040.00418.73
8.1.140.0040.00417.35
8.1.130.0080.00017.78
8.1.120.0000.00717.34
8.1.110.0040.00417.28
8.1.100.0000.00717.33
8.1.90.0000.00717.23
8.1.80.0000.00717.34
8.1.70.0070.00017.36
8.1.60.0000.00817.43
8.1.50.0000.00817.40
8.1.40.0040.00417.41
8.1.30.0000.00817.53
8.1.20.0070.00017.48
8.1.10.0040.00417.34
8.1.00.0040.00417.33
8.0.300.0040.00418.77
8.0.290.0040.00416.63
8.0.280.0000.00718.32
8.0.270.0060.00317.19
8.0.260.0000.00617.19
8.0.250.0040.00416.86
8.0.240.0030.00316.77
8.0.230.0030.00316.87
8.0.220.0030.00316.71
8.0.210.0030.00316.82
8.0.200.0030.00316.74
8.0.190.0080.00016.86
8.0.180.0000.00716.70
8.0.170.0000.00816.88
8.0.160.0050.00216.81
8.0.150.0030.00316.71
8.0.140.0000.00716.79
8.0.130.0050.00013.16
8.0.120.0070.00016.65
8.0.110.0000.00716.71
8.0.100.0070.00016.60
8.0.90.0000.00716.58
8.0.80.0030.01316.71
8.0.70.0040.00416.82
8.0.60.0080.00016.78
8.0.50.0000.00716.73
8.0.30.0100.01017.08
8.0.20.0110.00717.40
8.0.10.0070.00016.84
8.0.00.0090.01016.77
7.4.330.0000.00515.07
7.4.320.0030.00616.38
7.4.300.0000.00716.48
7.4.290.0030.00316.39
7.4.280.0000.00816.30
7.4.270.0030.00316.29
7.4.260.0070.00316.44
7.4.250.0040.00416.50
7.4.240.0030.00516.45
7.4.230.0050.00216.20
7.4.220.0120.00616.57
7.4.210.0140.00016.43
7.4.200.0040.00416.59
7.4.160.0090.00616.27
7.4.150.0080.01117.40
7.4.140.0120.00717.86
7.4.130.0070.01016.31
7.4.120.0100.00716.38
7.4.110.0130.01016.52
7.4.100.0100.00716.46
7.4.90.0100.01016.37
7.4.80.0130.00719.39
7.4.70.0070.01016.41
7.4.60.0060.01216.34
7.4.50.0050.00316.29
7.4.40.0070.01016.42
7.4.30.0130.00316.59
7.4.00.0000.01714.86
7.3.330.0050.00013.19
7.3.320.0050.00013.14
7.3.310.0080.00016.17
7.3.300.0070.00016.14
7.3.290.0100.00816.22
7.3.280.0080.00916.18
7.3.270.0070.01717.40
7.3.260.0140.00716.42
7.3.250.0130.00516.37
7.3.240.0150.00616.17
7.3.230.0100.01316.39
7.3.210.0030.01616.23
7.3.200.0090.01019.39
7.3.190.0060.01116.33
7.3.180.0100.00616.08
7.3.170.0030.01316.27
7.3.160.0090.00916.38
7.3.120.0120.00614.55
7.3.110.0110.00414.61
7.3.100.0030.00714.57
7.3.90.0060.00914.65
7.3.80.0030.00614.79
7.3.70.0040.00414.75
7.3.60.0030.01214.77
7.3.50.0070.00714.36
7.3.40.0030.00614.68
7.3.30.0130.00314.71
7.3.20.0030.00616.59
7.3.10.0120.00316.68
7.3.00.0100.00316.59
7.2.330.0070.01116.16
7.2.320.0090.01216.30
7.2.310.0100.00716.24
7.2.300.0110.00716.20
7.2.290.0130.01016.21
7.2.250.0070.01314.83
7.2.240.0060.01214.86
7.2.230.0070.01114.63
7.2.220.0080.00814.67
7.2.210.0000.01214.70
7.2.200.0030.01414.68
7.2.190.0100.00014.69
7.2.180.0000.01314.77
7.2.170.0070.00714.68
7.2.80.0070.00716.02
7.2.00.0000.01318.82
7.1.330.0080.00815.67
7.1.320.0090.00615.81
7.1.310.0120.00015.76
7.1.300.0030.01015.43
7.1.290.0090.00315.63
7.1.280.0030.01015.63
7.1.270.0070.00715.26
7.1.260.0100.00315.66
7.1.200.0040.00815.63
7.1.100.0030.00517.80
7.1.70.0000.00816.97
7.1.60.0110.01119.11
7.1.50.0150.00616.82
7.1.00.0030.07722.56
7.0.200.0040.00416.61
7.0.140.0070.07022.09
7.0.60.0170.08020.06
7.0.50.0030.04017.87
7.0.40.0100.08720.02
7.0.30.0270.05020.25
7.0.20.0170.04320.09
7.0.10.0030.04720.25
7.0.00.0030.08320.24
5.6.280.0030.07321.10
5.6.210.0130.07720.70
5.6.200.0130.07718.18
5.6.190.0030.07020.57
5.6.180.0130.07320.57
5.6.170.0100.05320.56
5.6.160.0000.04320.57
5.6.150.0070.07318.18
5.6.140.0030.04018.28
5.6.130.0100.07318.15
5.6.120.0130.07320.97
5.6.110.0070.08721.05
5.6.100.0030.06320.98
5.6.90.0000.05020.99
5.6.80.0100.08020.45
5.6.70.4370.04720.38
5.5.350.0100.08020.41
5.5.340.0200.07017.96
5.5.330.0130.07320.32
5.5.320.0370.06020.24
5.5.310.0270.04720.27
5.5.300.0100.08018.04
5.5.290.0000.08317.93
5.5.280.0130.03320.85
5.5.270.0070.08320.87
5.5.260.0130.07720.84
5.5.250.0100.04720.66
5.5.240.0270.07020.27
5.4.450.0800.06019.32
5.4.440.0830.05019.55
5.4.430.0400.06019.45
5.4.420.0030.06019.44
5.4.410.0900.04719.50
5.4.400.0900.04319.01
5.4.390.0770.05719.30
5.4.380.0630.05719.02
5.4.370.0670.06019.06
5.4.360.1000.05019.04
5.4.350.0900.05719.15
5.4.340.0090.04512.02
5.4.320.0070.03912.51
5.4.310.0060.04312.50
5.4.300.0120.04012.50
5.4.290.0070.04512.50
5.4.280.0020.04412.40
5.4.270.0060.04212.40
5.4.260.0080.04812.40
5.4.250.0080.05012.39
5.4.240.0080.05012.40
5.4.230.0090.05012.39
5.4.220.0080.03912.39
5.4.210.0080.04212.39
5.4.200.0100.05112.39
5.4.190.0060.04812.39
5.4.180.0110.04812.39
5.4.170.0060.04312.40
5.4.160.0060.03812.39
5.4.150.0100.03612.39
5.4.140.0050.04212.07
5.4.130.0080.04012.06
5.4.120.0050.04412.02
5.4.110.0040.05112.01
5.4.100.0070.04012.01
5.4.90.0110.04512.01
5.4.80.0070.03812.01
5.4.70.0040.04012.00
5.4.60.0070.04312.01
5.4.50.0030.04012.01
5.4.40.0060.03712.00
5.4.30.0110.03511.99
5.4.20.0090.04012.00
5.4.10.0090.04112.00
5.4.00.0090.04711.48
5.3.290.0100.05212.80
5.3.280.0040.04212.71
5.3.270.0070.05212.72
5.3.260.0080.05312.72
5.3.250.0090.05112.72
5.3.240.0080.05312.72
5.3.230.0060.04512.71
5.3.220.0040.03912.68
5.3.210.0060.04412.68
5.3.200.0060.04512.68
5.3.190.0050.04012.68
5.3.180.0080.04112.68
5.3.170.0050.03912.67
5.3.160.0070.04812.67
5.3.150.0080.03612.68
5.3.140.0060.03612.66
5.3.130.0110.05012.66
5.3.120.0130.04612.66
5.3.110.0080.05112.66
5.3.100.0080.04712.12
5.3.90.0070.04112.10
5.3.80.0060.03812.09
5.3.70.0060.03812.08
5.3.60.0070.03612.07
5.3.50.0090.04712.02
5.3.40.0110.04512.02
5.3.30.0060.03911.97
5.3.20.0070.03311.76
5.3.10.0060.03511.73
5.3.00.0060.03611.71
5.2.170.0070.0289.21
5.2.160.0050.0299.21
5.2.150.0050.0309.21
5.2.140.0070.0289.21
5.2.130.0070.0269.17
5.2.120.0050.0299.17
5.2.110.0050.0309.18
5.2.100.0060.0289.17
5.2.90.0070.0289.17
5.2.80.0070.0309.16
5.2.70.0050.0319.16
5.2.60.0020.0359.12
5.2.50.0070.0299.09
5.2.40.0060.0309.07
5.2.30.0040.0339.04
5.2.20.0050.0309.03
5.2.10.0070.0288.95
5.2.00.0090.0318.80
5.1.60.0060.0278.08
5.1.50.0020.0278.08
5.1.40.0030.0278.05
5.1.30.0030.0318.41
5.1.20.0040.0288.43
5.1.10.0050.0268.16
5.1.00.0050.0258.15
5.0.50.0040.0226.63
5.0.40.0030.0226.49
5.0.30.0050.0386.31
5.0.20.0050.0226.28
5.0.10.0040.0196.25
5.0.00.0030.0326.25
4.4.90.0030.0164.78
4.4.80.0050.0134.75
4.4.70.0030.0164.75
4.4.60.0060.0134.76
4.4.50.0080.0104.77
4.4.40.0030.0264.71
4.4.30.0050.0144.76
4.4.20.0030.0154.84
4.4.10.0020.0164.84
4.4.00.0050.0234.76
4.3.110.0090.0154.67
4.3.100.0030.0214.66
4.3.90.0040.0144.64
4.3.80.0040.0284.59
4.3.70.0080.0154.63
4.3.60.0010.0154.63
4.3.50.0010.0184.63
4.3.40.0030.0264.53
4.3.30.0020.0203.30
4.3.20.0010.0203.27
4.3.10.0020.0173.24
4.3.00.0200.0177.03

preferences:
40.02 ms | 401 KiB | 5 Q