3v4l.org

run code in 300+ PHP versions simultaneously
<?php declare(strict_types=1); $foo = new stdClass(); $foo->{"0"} = false; $foo->{0} = true; $foo = (array)$foo; echo json_encode($foo); // {"0":false,"0":true}

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.40.0140.00718.97
8.3.30.0040.01118.75
8.3.20.0050.00220.13
8.3.10.0040.00421.78
8.3.00.0080.00023.53
8.2.170.0110.00422.96
8.2.160.0070.00720.35
8.2.150.0040.00424.18
8.2.140.0070.00024.66
8.2.130.0000.00821.18
8.2.120.0070.00026.35
8.2.110.0060.00319.30
8.2.100.0040.00717.92
8.2.90.0040.00419.06
8.2.80.0080.00017.97
8.2.70.0000.00917.38
8.2.60.0000.00817.89
8.2.50.0000.00818.09
8.2.40.0000.00822.34
8.2.30.0030.00619.48
8.2.20.0040.00417.67
8.2.10.0000.00818.06
8.2.00.0060.00317.92
8.1.270.0040.00422.19
8.1.260.0000.00728.09
8.1.250.0000.00828.09
8.1.240.0060.00322.53
8.1.230.0070.00317.83
8.1.220.0040.00417.74
8.1.210.0000.00918.77
8.1.200.0000.01017.23
8.1.190.0080.00017.10
8.1.180.0050.00318.10
8.1.170.0000.00818.51
8.1.160.0070.00020.61
8.1.150.0000.00820.60
8.1.140.0000.00819.50
8.1.130.0070.00317.68
8.1.120.0030.00317.41
8.1.110.0000.00717.37
8.1.100.0000.00717.39
8.1.90.0080.00017.36
8.1.80.0080.00417.45
8.1.70.0030.00317.35
8.1.60.0080.00017.46
8.1.50.0000.00817.51
8.1.40.0060.00617.40
8.1.30.0030.00517.74
8.1.20.0040.00417.61
8.1.10.0000.00817.47
8.1.00.0080.00017.42
8.0.300.0020.00518.77
8.0.290.0000.00816.63
8.0.280.0000.00818.43
8.0.270.0070.00017.17
8.0.260.0000.00617.20
8.0.250.0030.00316.91
8.0.240.0070.00016.96
8.0.230.0000.00816.82
8.0.220.0030.00616.89
8.0.210.0050.00316.82
8.0.200.0040.00416.89
8.0.190.0070.00316.91
8.0.180.0080.00016.90
8.0.170.0030.00516.85
8.0.160.0030.00316.85
8.0.150.0050.00316.77
8.0.140.0000.00716.66
8.0.130.0000.00513.20
8.0.120.0050.00316.83
8.0.110.0040.00416.86
8.0.100.0000.00716.77
8.0.90.0030.00316.77
8.0.80.0100.00716.79
8.0.70.0030.00516.79
8.0.60.0000.00816.85
8.0.50.0000.00816.76
8.0.30.0120.00616.99
8.0.20.0110.00917.40
8.0.10.0040.00416.84
8.0.00.0060.01116.80
7.4.330.0030.00316.80
7.4.320.0030.00316.60
7.4.300.0070.00016.53
7.4.290.0000.00816.51
7.4.280.0000.01016.61
7.4.270.0070.00016.60
7.4.260.0000.00716.40
7.4.250.0050.00316.46
7.4.240.0050.00216.54
7.4.230.0000.00716.50
7.4.220.0200.01016.56
7.4.210.0060.01116.52
7.4.200.0050.00316.63
7.4.160.0080.00816.63
7.4.150.0090.00917.40
7.4.140.0080.01617.86
7.4.130.0080.00916.52
7.4.120.0080.01016.50
7.4.110.0090.00916.56
7.4.100.0060.01616.37
7.4.90.0150.00416.51
7.4.80.0100.01019.39
7.4.70.0040.01216.61
7.4.60.0100.00716.54
7.4.50.0040.01116.34
7.4.40.0130.00616.69
7.4.30.0110.01116.71
7.4.00.0110.00415.07
7.3.330.0000.00513.14
7.3.320.0050.00013.00
7.3.310.0000.00616.05
7.3.300.0050.00216.25
7.3.290.0000.00716.30
7.3.280.0140.00516.28
7.3.270.0070.01017.40
7.3.260.0070.01016.33
7.3.250.0110.01116.35
7.3.240.0100.00616.33
7.3.230.0110.00516.39
7.3.210.0060.00916.27
7.3.200.0070.01119.39
7.3.190.0110.00716.61
7.3.180.0170.00316.29
7.3.170.0120.00816.48
7.3.160.0060.00916.46
7.2.330.0060.01916.75
7.2.320.0100.00716.57
7.2.310.0000.01616.66
7.2.300.0070.01016.68
7.2.290.0140.00716.71
7.2.60.0080.00516.82
7.2.00.0030.00919.54
7.1.200.0030.00315.68
7.1.100.0150.00418.11
7.1.70.0030.00517.19
7.1.60.0090.01319.40
7.1.50.0070.01417.00
7.1.00.0100.07022.43
7.0.200.0100.00016.98
7.0.90.0530.06720.00
7.0.80.0530.08719.90
7.0.70.0170.08719.88
7.0.60.0530.04319.93
7.0.50.0400.08320.30
7.0.40.0300.06720.18
7.0.30.0000.07020.11
7.0.20.0130.07320.14
7.0.10.0030.04720.17
7.0.00.0170.06720.14
5.6.280.0000.05320.99
5.6.240.0130.07720.66
5.6.230.0100.04720.75
5.6.220.0070.09020.70
5.6.210.0170.06020.47
5.6.200.0100.04321.08
5.6.190.0000.09321.17
5.6.180.0100.04021.09
5.6.170.0370.06020.93
5.6.160.0100.07021.08
5.6.150.0170.07020.93
5.6.140.0000.05721.04
5.6.130.0030.07320.96
5.6.120.0000.08721.01
5.6.110.0130.03721.04
5.6.100.0100.07321.10
5.6.90.0100.04020.99
5.6.80.0100.04020.43
5.6.70.0100.06320.48
5.6.60.0000.05320.43
5.6.50.0070.07720.46
5.6.40.0070.09020.37
5.6.30.0100.06320.41
5.6.20.0000.06020.42
5.6.10.0130.07020.37
5.6.00.0100.05720.27
5.5.380.0070.06720.42
5.5.370.0100.05020.42
5.5.360.0030.07020.36
5.5.350.0130.06320.46
5.5.340.0130.08720.88
5.5.330.0170.07020.86
5.5.320.0100.07720.77
5.5.310.0130.06320.87
5.5.300.0030.06720.90
5.5.290.0070.07720.83
5.5.280.0200.03320.79
5.5.270.0070.05320.72
5.5.260.0030.05720.77
5.5.250.0030.06020.54
5.5.240.0000.05020.03
5.5.230.0070.04720.17
5.5.220.0130.06320.21
5.5.210.0170.06320.26
5.5.200.0030.07720.18
5.5.190.0100.05720.27
5.5.180.0070.08020.24
5.5.160.0000.08020.18
5.5.150.0170.07020.26
5.5.140.0070.05720.10
5.5.130.0000.06319.95
5.5.120.0070.05020.24
5.5.110.0070.05020.22
5.5.100.0070.08019.98
5.5.90.0070.05320.09
5.5.80.0200.06320.06
5.5.70.0100.07020.14
5.5.60.0070.07720.15
5.5.50.0000.07720.09
5.5.40.0130.07020.05
5.5.30.0070.05020.04
5.5.20.0070.08019.99
5.5.10.0070.08020.02
5.5.00.0070.08320.06

preferences:
48.94 ms | 400 KiB | 5 Q