3v4l.org

run code in 300+ PHP versions simultaneously
<?php const FLAG_1 = 0b0001; // 1 const FLAG_2 = 0b0010; // 2 const FLAG_3 = 0b0100; // 4 const FLAG_4 = 0b1000; // 8 // Can you see the pattern? ;-) function show_flags ($flags) { if ($flags & FLAG_1) { echo "You passed flag 1!<br>\n"; } if ($flags & FLAG_2) { echo "You passed flag 2!<br>\n"; } if ($flags & FLAG_3) { echo "You passed flag 3!<br>\n"; } if ($flags & FLAG_4) { echo "You passed flag 4!<br>\n"; } } show_flags(2 | 1 | FLAG_3); echo 4 == FLAG_2;

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.0040.01118.52
8.3.50.0070.00716.34
8.3.40.0120.00318.66
8.3.30.0160.00318.57
8.3.20.0000.00820.34
8.3.10.0040.00423.58
8.3.00.0080.00017.89
8.2.180.0120.00318.13
8.2.170.0070.00722.96
8.2.160.0070.00719.16
8.2.150.0090.00024.18
8.2.140.0030.00624.66
8.2.130.0030.00726.16
8.2.120.0060.00317.63
8.2.110.0060.00321.00
8.2.100.0090.00317.50
8.2.90.0040.00419.21
8.2.80.0050.00317.97
8.2.70.0000.00817.50
8.2.60.0000.00818.04
8.2.50.0080.00018.07
8.2.40.0000.00719.52
8.2.30.0070.00020.70
8.2.20.0040.00417.61
8.2.10.0040.00418.04
8.2.00.0000.00718.03
8.1.280.0060.00925.92
8.1.270.0110.00423.82
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0060.00322.19
8.1.230.0090.00317.64
8.1.220.0000.00817.74
8.1.210.0060.00318.77
8.1.200.0090.00017.22
8.1.190.0040.00417.13
8.1.180.0000.00818.10
8.1.170.0000.00818.51
8.1.160.0040.00421.89
8.1.150.0000.00718.84
8.1.140.0000.00817.39
8.1.130.0040.00417.72
8.1.120.0030.00317.38
8.1.110.0040.00417.38
8.1.100.0050.00317.39
8.1.90.0000.00717.43
8.1.80.0070.00017.45
8.1.70.0040.00417.41
8.1.60.0000.00917.41
8.1.50.0020.00517.46
8.1.40.0040.00417.39
8.1.30.0030.00617.51
8.1.20.0030.00517.64
8.1.10.0000.00817.47
8.1.00.0040.00417.37
8.0.300.0000.00718.77
8.0.290.0060.00316.63
8.0.280.0050.00318.37
8.0.270.0030.00317.18
8.0.260.0030.00317.11
8.0.250.0000.00716.93
8.0.240.0030.00316.85
8.0.230.0050.00216.93
8.0.220.0000.00716.73
8.0.210.0050.00216.82
8.0.200.0060.00016.90
8.0.190.0050.00316.86
8.0.180.0040.00416.86
8.0.170.0030.00616.85
8.0.160.0000.00816.86
8.0.150.0000.00716.74
8.0.140.0040.00416.80
8.0.130.0030.00313.25
8.0.120.0030.00516.72
8.0.110.0000.00916.83
8.0.100.0040.00416.83
8.0.90.0000.00716.87
8.0.80.0090.00616.79
8.0.70.0040.00416.90
8.0.60.0000.00716.79
8.0.50.0030.00516.89
8.0.30.0110.00917.06
8.0.20.0120.00717.40
8.0.10.0040.00416.83
8.0.00.0130.01016.65
7.4.330.0060.00015.08
7.4.320.0000.00716.46
7.4.300.0030.00316.34
7.4.290.0030.00316.45
7.4.280.0000.00716.39
7.4.270.0070.00016.48
7.4.260.0080.00016.57
7.4.250.0000.00816.48
7.4.240.0030.00316.48
7.4.230.0030.00316.65
7.4.220.0110.00716.66
7.4.210.0060.00816.39
7.4.200.0000.00816.44
7.4.160.0090.00616.29
7.4.150.0130.00617.40
7.4.140.0060.01617.86
7.4.130.0090.00916.40
7.4.120.0100.00716.43
7.4.110.0040.02016.41
7.4.100.0060.01116.32
7.4.90.0090.00916.50
7.4.80.0120.01219.39
7.4.70.0030.01616.43
7.4.60.0090.00616.47
7.4.50.0060.00016.40
7.4.40.0060.01316.46
7.4.30.0090.01316.51
7.4.10.0070.00714.88
7.4.00.0030.01314.74
7.3.330.0000.00613.33
7.3.320.0040.00313.28
7.3.310.0070.00016.13
7.3.300.0030.00316.32
7.3.290.0090.00716.35
7.3.280.0110.00616.33
7.3.270.0160.00317.40
7.3.260.0140.01016.42
7.3.250.0110.00916.51
7.3.240.0110.00716.58
7.3.230.0060.01016.39
7.3.210.0030.01316.60
7.3.200.0090.01216.36
7.3.190.0000.01616.39
7.3.180.0180.00316.29
7.3.170.0130.00316.49
7.3.160.0140.00316.37
7.3.130.0090.00914.82
7.3.120.0070.01114.96
7.3.110.0040.00914.79
7.3.100.0060.00814.81
7.3.90.0100.00814.78
7.3.80.0020.01214.89
7.3.70.0110.00514.81
7.3.60.0010.01014.83
7.3.50.0070.00714.84
7.3.40.0070.00814.97
7.3.30.0060.00414.93
7.3.20.0040.00816.67
7.3.10.0080.00716.77
7.3.00.0100.00216.68
7.2.330.0100.00616.57
7.2.320.0110.01116.49
7.2.310.0110.00716.59
7.2.300.0110.00716.80
7.2.290.0120.00616.62
7.2.260.0080.00815.22
7.2.250.0050.01314.98
7.2.240.0050.01115.02
7.2.230.0090.00914.80
7.2.220.0130.00315.13
7.2.210.0110.00615.19
7.2.200.0060.00715.03
7.2.190.0100.00515.02
7.2.180.0070.00815.00
7.2.170.0090.00414.99
7.2.160.0070.01015.04
7.2.150.0040.01116.68
7.2.140.0050.00516.88
7.2.130.0060.00917.00
7.2.120.0090.00616.89
7.2.110.0070.01016.84
7.2.100.0030.00717.08
7.2.90.0090.00617.17
7.2.80.0030.00716.82
7.2.70.0140.00017.10
7.2.60.0060.00316.85
7.2.50.0030.00716.95
7.2.40.0030.01416.96
7.2.30.0110.00717.07
7.2.20.0080.00817.08
7.2.10.0110.00717.05
7.2.00.0050.00918.09
7.1.330.0030.01115.79
7.1.320.0050.01115.69
7.1.310.0070.00715.99
7.1.300.0070.00715.69
7.1.290.0030.00915.65
7.1.280.0070.00615.61
7.1.270.0080.00515.69
7.1.260.0090.00215.65
7.1.250.0030.00915.62
7.1.240.0000.01315.87
7.1.230.0070.01015.83
7.1.220.0030.01015.70
7.1.210.0000.01215.78
7.1.200.0000.01515.55
7.1.190.0030.01015.52
7.1.180.0000.01215.85
7.1.170.0060.00615.63
7.1.160.0070.00715.57
7.1.150.0160.00015.88
7.1.140.0030.01415.83
7.1.130.0060.00915.48
7.1.120.0040.00715.80
7.1.110.0070.00715.87
7.1.100.0000.01116.96
7.1.90.0100.00315.80
7.1.80.0040.01115.73
7.1.70.0050.00716.36
7.1.60.0120.00817.61
7.1.50.0120.01025.15
7.1.40.0100.00715.54
7.1.30.0030.01015.75
7.1.20.0030.01015.32
7.1.10.0110.00415.79
7.1.00.0080.03819.20
7.0.330.0070.00715.09
7.0.320.0090.00315.36
7.0.310.0060.01015.48
7.0.300.0030.01015.48
7.0.290.0030.00915.40
7.0.280.0060.01015.53
7.0.270.0040.00715.34
7.0.260.0040.01115.16
7.0.250.0030.01315.38
7.0.240.0100.00015.52
7.0.230.0080.00415.46
7.0.220.0070.00715.04
7.0.210.0040.00815.54
7.0.200.0040.00516.01
7.0.190.0030.01015.22
7.0.180.0000.01115.46
7.0.170.0030.01015.55
7.0.160.0090.00615.22
7.0.150.0070.00415.21
7.0.140.0040.00815.42
7.0.130.0060.00715.30
7.0.120.0100.00315.52
7.0.110.0060.00315.33
7.0.100.0040.00815.05
7.0.90.0100.00715.56
7.0.80.0060.00915.12
7.0.70.0100.00315.47
7.0.60.0080.02317.72
7.0.50.0030.04216.72
7.0.40.0060.04516.81
7.0.30.0120.03016.89
7.0.20.0200.03316.76
7.0.10.0030.02516.87
7.0.00.0080.04616.70
5.6.400.0000.01014.54
5.6.390.0000.00814.08
5.6.380.0000.00914.32
5.6.370.0070.00714.28
5.6.360.0060.00614.43
5.6.350.0080.00414.27
5.6.340.0090.00614.22
5.6.330.0000.01514.25
5.6.320.0060.00714.34
5.6.310.0100.00714.64
5.6.300.0000.01214.28
5.6.290.0030.01014.29
5.6.280.0050.01817.72
5.6.270.0100.00014.04
5.6.260.0000.01414.45
5.6.250.0080.00414.45
5.6.240.0140.00314.55
5.6.230.0000.01714.02
5.6.220.0100.00314.13
5.6.210.0060.02817.49
5.6.200.0030.04616.13
5.6.190.0080.04517.66
5.6.180.0130.03017.20
5.6.170.0150.03517.34
5.6.160.0100.04417.25
5.6.150.0070.03316.23
5.6.140.0070.04216.19
5.6.130.0070.04016.21
5.6.120.0020.05117.72
5.6.110.0010.02617.68
5.6.100.0070.03317.70
5.6.90.0040.03217.69
5.6.80.0050.04117.35
5.6.70.0130.00314.26
5.6.60.0000.01213.93
5.6.50.0090.00614.18
5.6.40.0100.00613.90
5.6.30.0060.00614.50
5.6.20.0000.01314.10
5.6.10.0030.01014.54
5.6.00.0120.00314.19
5.5.380.0060.00914.22
5.5.370.0030.00914.34
5.5.360.0000.01614.08
5.5.350.0160.02517.26
5.5.340.0100.03516.12
5.5.330.0070.04817.42
5.5.320.0140.04317.36
5.5.310.0180.03617.29
5.5.300.0100.02716.06
5.5.290.0030.04916.22
5.5.280.0040.02317.48
5.5.270.0090.02617.51
5.5.260.0080.04517.42
5.5.250.0100.03017.38
5.5.240.0050.02717.13
5.5.230.0070.01013.96
5.5.220.0100.00314.25
5.5.210.0060.00914.10
5.5.200.0090.00614.38
5.5.190.0060.01014.14
5.5.180.0070.00714.17
5.5.170.0040.00714.28
5.5.160.0080.00014.32
5.5.150.0030.00914.00
5.5.140.0030.01014.12
5.5.130.0060.00914.17
5.5.120.0040.00713.72
5.5.110.0030.01214.33
5.5.100.0040.01114.27
5.5.90.0000.00913.93
5.5.80.0070.00714.17
5.5.70.0070.00714.08
5.5.60.0060.00914.40
5.5.50.0040.00814.00
5.5.40.0070.00714.21
5.5.30.0070.00714.23
5.5.20.0000.01613.96
5.5.10.0090.00314.00
5.5.00.0040.00413.91
5.4.450.0070.02815.82
5.4.440.0130.02015.63
5.4.430.0080.02315.65
5.4.420.0130.02515.70
5.4.410.0100.02415.65
5.4.400.0160.03715.64
5.4.390.0160.04015.57
5.4.380.0140.03215.55
5.4.370.0170.03715.58
5.4.360.0170.04115.65
5.4.350.0150.02315.50
5.4.340.0100.02515.59
5.4.330.0110.00012.00
5.4.320.0110.03515.42
5.4.310.0160.04115.59
5.4.300.0150.03815.54
5.4.290.0150.04015.54
5.4.280.0180.03315.59
5.4.270.0150.03915.57
5.4.260.0180.03315.53
5.4.250.0140.02415.49
5.4.240.0100.02015.59
5.4.230.0100.02215.57
5.4.220.0130.02215.57
5.4.210.0100.03815.54
5.4.200.0120.03915.42
5.4.190.0200.03215.42
5.4.180.0130.03115.43
5.4.170.0180.02315.48
5.4.160.0160.02215.53
5.4.150.0270.01715.46
5.4.140.0170.03514.28
5.4.130.0140.03014.18
5.4.120.0120.03614.23
5.4.110.0200.02114.16
5.4.100.0150.03914.15
5.4.90.0120.02814.28
5.4.80.0130.02814.30
5.4.70.0000.01112.00
5.4.60.0000.01112.00
5.4.50.0000.01012.00
5.4.40.0060.00312.00
5.4.30.0110.00012.00
5.4.20.0110.00012.00
5.4.10.0050.00212.00
5.4.00.0060.00612.00

preferences:
57.52 ms | 400 KiB | 5 Q