3v4l.org

run code in 300+ PHP versions simultaneously
<?php // int isn't a reserved word, right? // So this should work fine! const asd = 7; // Let's try using it! var_dump(asd); /* Wait, what? A parse error? Why, you might ask? (int) is a special case in the lexer. Turns out that casts are lexed specially. Why? Probably to stop the type names being reserved words. That worked out spectacularly, didn't it. This has been around since at least PHP 3. */

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.0120.00316.38
8.3.50.0080.01222.03
8.3.40.0070.00718.38
8.3.30.0040.01118.82
8.3.20.0080.00020.04
8.3.10.0040.00423.42
8.3.00.0050.00320.75
8.2.180.0100.01018.03
8.2.170.0030.01022.96
8.2.160.0130.00720.22
8.2.150.0070.00024.18
8.2.140.0050.00324.66
8.2.130.0040.00426.16
8.2.120.0090.00019.23
8.2.110.0060.00321.04
8.2.100.0040.00817.78
8.2.90.0070.00317.66
8.2.80.0030.00618.09
8.2.70.0000.00817.63
8.2.60.0070.00317.48
8.2.50.0000.00817.63
8.2.40.0040.00417.80
8.2.30.0060.00318.18
8.2.20.0040.00417.71
8.2.10.0000.00718.04
8.2.00.0080.00017.68
8.1.280.0090.00925.92
8.1.270.0060.00323.97
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0050.00324.03
8.1.230.0040.00722.75
8.1.220.0030.00517.74
8.1.210.0080.00418.78
8.1.200.0040.00417.22
8.1.190.0060.00317.10
8.1.180.0000.00818.10
8.1.170.0040.00417.62
8.1.160.0000.00722.01
8.1.150.0040.00418.63
8.1.140.0040.00417.44
8.1.130.0080.00017.71
8.1.120.0000.00717.29
8.1.110.0000.00817.44
8.1.100.0030.00317.39
8.1.90.0030.00317.39
8.1.80.0040.00417.28
8.1.70.0000.00817.29
8.1.60.0030.00617.54
8.1.50.0050.00517.46
8.1.40.0040.00417.35
8.1.30.0000.00817.55
8.1.20.0040.00417.41
8.1.10.0000.00717.24
8.1.00.0040.00417.29
8.0.300.0040.00419.81
8.0.290.0040.00416.63
8.0.280.0030.00318.45
8.0.270.0030.00317.07
8.0.260.0030.00317.18
8.0.250.0000.00716.91
8.0.240.0050.00316.92
8.0.230.0000.00716.87
8.0.220.0030.00316.88
8.0.210.0030.00316.84
8.0.200.0040.00416.77
8.0.190.0000.00716.93
8.0.180.0030.00616.80
8.0.170.0080.00016.84
8.0.160.0050.00216.86
8.0.150.0040.00416.73
8.0.140.0000.00716.81
8.0.130.0030.00313.31
8.0.120.0050.00216.80
8.0.110.0040.00416.86
8.0.100.0040.00416.88
8.0.90.0030.00516.90
8.0.80.0090.00616.88
8.0.70.0040.00416.75
8.0.60.0040.00416.68
8.0.50.0070.00016.85
8.0.30.0100.00816.88
8.0.20.0150.00417.40
8.0.10.0080.00016.90
8.0.00.0130.00616.49
7.4.330.0050.00015.07
7.4.320.0030.00316.50
7.4.300.0030.00316.44
7.4.290.0080.00016.41
7.4.280.0000.00716.27
7.4.270.0040.00416.57
7.4.260.0050.00316.46
7.4.250.0070.00016.37
7.4.240.0030.00416.43
7.4.230.0000.00716.32
7.4.220.0180.01216.56
7.4.210.0060.00916.56
7.4.200.0030.00316.55
7.4.160.0150.00016.56
7.4.150.0100.01017.40
7.4.140.0070.01017.86
7.4.130.0090.00816.41
7.4.120.0080.00916.59
7.4.110.0110.00716.56
7.4.100.0090.00916.56
7.4.90.0100.00716.18
7.4.80.0070.01019.39
7.4.70.0100.01016.45
7.4.60.0070.01416.50
7.4.50.0000.00516.43
7.4.40.0100.00716.49
7.4.30.0070.00916.45
7.4.00.0070.00714.91
7.3.330.0000.00513.11
7.3.320.0050.00012.90
7.3.310.0000.00716.05
7.3.300.0000.00716.20
7.3.290.0100.00316.28
7.3.280.0070.00916.21
7.3.270.0070.01017.40
7.3.260.0090.00916.18
7.3.250.0080.01016.30
7.3.240.0110.00416.22
7.3.230.0130.01016.39
7.3.210.0140.00316.30
7.3.200.0110.00819.39
7.3.190.0150.00016.43
7.3.180.0100.00716.32
7.3.170.0120.00916.43
7.3.160.0060.01216.18
7.3.120.0120.00314.97
7.2.330.0140.00416.45
7.2.320.0060.01016.61
7.2.310.0060.01016.44
7.2.300.0040.01216.71
7.2.290.0060.01116.66
7.1.70.0040.00717.07
7.1.60.0030.00917.13
7.1.50.0000.01116.54
7.1.00.0070.07322.40
7.0.200.0070.00416.59
7.0.140.0000.07021.92
7.0.60.0070.07319.85
7.0.50.0130.05017.87
7.0.40.0100.08320.30
7.0.30.0270.05020.13
7.0.20.0300.06720.17
7.0.10.0270.09020.13
7.0.00.0030.04320.16
5.6.280.0030.07321.06
5.6.210.0000.04320.50
5.6.200.0100.04718.15
5.6.190.0100.03720.41
5.6.180.0000.06320.56
5.6.170.0400.06020.71
5.6.160.0030.04720.43
5.6.150.0070.05018.09
5.6.140.0100.07318.18
5.6.130.0070.09718.14
5.6.120.0170.07020.89
5.6.110.0070.08321.04
5.6.100.0030.07721.00
5.6.90.0200.06321.12
5.6.80.0070.05020.40
5.6.70.0270.07020.39
5.5.350.0130.07020.29
5.5.340.0100.07317.95
5.5.330.0130.05320.23
5.5.320.0100.04720.18
5.5.310.0400.06320.21
5.5.300.0070.03718.01
5.5.290.0070.08017.95
5.5.280.0070.08320.75
5.5.270.0170.08020.67
5.5.260.0100.08020.93
5.5.250.0030.07320.57
5.5.240.0100.07020.33
5.4.450.0530.04335.89
5.4.440.0130.05035.00
5.4.430.0300.03032.89
5.4.420.0370.04332.20
5.4.410.0200.03032.19
5.4.400.0670.04032.19
5.4.390.0600.04332.19
5.4.380.0130.05718.66
5.4.370.0200.04718.56
5.4.360.0170.05018.50
5.4.350.0100.06018.71
5.4.340.0070.05718.49
5.4.320.0030.03912.45
5.4.310.0040.05112.45
5.4.300.0080.05312.45
5.4.290.0080.05012.45
5.4.280.0030.04112.34
5.4.270.0080.03612.35
5.4.260.0090.03812.34
5.4.250.0110.04412.34
5.4.240.0080.04512.34
5.4.230.0120.06212.34
5.4.220.0110.08412.34
5.4.210.0120.06212.34
5.4.200.0130.06112.34
5.4.190.0090.05812.33
5.4.180.0100.04912.33
5.4.170.0130.05112.35
5.4.160.0140.07212.34
5.4.150.0090.05412.34
5.4.140.0070.05212.02
5.4.130.0110.04812.01
5.4.120.0090.03911.97
5.4.110.0030.04211.97
5.4.100.0080.03711.97
5.4.90.0090.03911.96
5.4.80.0110.04311.96
5.4.70.0090.03911.96
5.4.60.0060.03811.96
5.4.50.0070.04011.96
5.4.40.0100.03911.95
5.4.30.0130.05411.95
5.4.20.0070.04911.95
5.4.10.0080.05311.95
5.4.00.0110.05611.43
5.3.290.0060.04312.80
5.3.280.0130.06612.70
5.3.270.0160.06312.73
5.3.260.0090.05012.72
5.3.250.0130.04012.72
5.3.240.0110.04812.72
5.3.230.0160.07812.71
5.3.220.0070.05712.68
5.3.210.0090.05212.68
5.3.200.0070.06012.68
5.3.190.0080.05612.68
5.3.180.0080.05212.68
5.3.170.0100.06512.67
5.3.160.0140.04312.68
5.3.150.0070.06712.68
5.3.140.0090.04612.66
5.3.130.0100.04112.66
5.3.120.0110.04112.66
5.3.110.0070.04312.66
5.3.100.0090.03912.12
5.3.90.0100.03812.08
5.3.80.0090.04312.08
5.3.70.0110.03812.07
5.3.60.0250.05012.06
5.3.50.0110.06812.00
5.3.40.0110.05012.00
5.3.30.0100.04111.94
5.3.20.0090.04311.71
5.3.10.0080.04211.69
5.3.00.0060.04011.67
5.2.170.0080.0309.18
5.2.160.0070.0359.18
5.2.150.0130.0359.18
5.2.140.0150.0649.18
5.2.130.0070.0299.14
5.2.120.0080.0389.14
5.2.110.0110.0349.15
5.2.100.0060.0429.14
5.2.90.0080.0389.14
5.2.80.0040.0389.14
5.2.70.0080.0319.14
5.2.60.0060.0319.09
5.2.50.0080.0319.05
5.2.40.0090.0339.04
5.2.30.0070.0359.01
5.2.20.0040.0329.01
5.2.10.0060.0308.92
5.2.00.0090.0328.79
5.1.60.0040.0288.07
5.1.50.0080.0348.06
5.1.40.0040.0278.05
5.1.30.0060.0268.40
5.1.20.0050.0278.41
5.1.10.0060.0298.14
5.1.00.0070.0268.14
5.0.50.0040.0216.62
5.0.40.0050.0186.48
5.0.30.0030.0356.29
5.0.20.0020.0236.27
5.0.10.0030.0216.24
5.0.00.0040.0326.23
4.4.90.0030.0174.78
4.4.80.0060.0134.76
4.4.70.0040.0194.75
4.4.60.0040.0174.75
4.4.50.0080.0284.77
4.4.40.0040.0364.71
4.4.30.0060.0194.76
4.4.20.0050.0224.84
4.4.10.0040.0234.85
4.4.00.0050.0284.76
4.3.110.0020.0174.67
4.3.100.0010.0214.67
4.3.90.0040.0144.63
4.3.80.0040.0274.58
4.3.70.0050.0214.63
4.3.60.0060.0164.63
4.3.50.0050.0154.63
4.3.40.0030.0344.53
4.3.30.0030.0163.28
4.3.20.0020.0183.26
4.3.10.0010.0183.22
4.3.00.0030.01732.19

preferences:
47.29 ms | 401 KiB | 5 Q