3v4l.org

run code in 300+ PHP versions simultaneously
<?php $json = '{"str":true,"123":true}'; $arr1 = json_decode($json, true); $arr2 = (array)json_decode($json); var_export($arr1, $arr2); var_dump(isset($arr1['str']), isset($arr1['123']), isset($arr2['str']), isset($arr2['123']));

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.63
8.3.50.0150.00621.28
8.3.40.0140.00718.71
8.3.30.0090.00618.54
8.3.20.0050.00220.21
8.3.10.0040.00423.48
8.3.00.0040.00422.58
8.2.180.0150.00416.50
8.2.170.0040.01122.96
8.2.160.0100.00720.38
8.2.150.0000.00824.18
8.2.140.0070.00724.66
8.2.130.0050.00326.16
8.2.120.0040.00417.50
8.2.110.0090.00022.16
8.2.100.0080.00317.63
8.2.90.0030.00619.13
8.2.80.0030.00517.97
8.2.70.0050.00317.63
8.2.60.0000.00917.80
8.2.50.0050.00318.07
8.2.40.0030.00521.13
8.2.30.0090.00019.65
8.2.20.0050.00317.68
8.2.10.0040.00418.09
8.2.00.0030.00518.02
8.1.280.0070.00725.92
8.1.270.0040.00420.33
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0000.00923.87
8.1.230.0110.00017.42
8.1.220.0040.00417.74
8.1.210.0040.00418.77
8.1.200.0000.00917.00
8.1.190.0050.00317.23
8.1.180.0030.00518.10
8.1.170.0000.00818.56
8.1.160.0070.00321.95
8.1.150.0000.00718.82
8.1.140.0040.00417.34
8.1.130.0040.00417.50
8.1.120.0050.00317.38
8.1.110.0020.00517.45
8.1.100.0000.00817.33
8.1.90.0000.00717.34
8.1.80.0000.01017.43
8.1.70.0000.00717.44
8.1.60.0050.00317.48
8.1.50.0040.00417.50
8.1.40.0060.00317.52
8.1.30.0000.00817.69
8.1.20.0070.00017.68
8.1.10.0040.00417.61
8.1.00.0060.00317.55
8.0.300.0040.00418.77
8.0.290.0000.00816.63
8.0.280.0000.00718.33
8.0.270.0030.00317.06
8.0.260.0060.00017.23
8.0.250.0040.00416.93
8.0.240.0030.00316.91
8.0.230.0030.00316.91
8.0.220.0040.00416.82
8.0.210.0000.00716.84
8.0.200.0000.00616.83
8.0.190.0040.00416.95
8.0.180.0030.00516.94
8.0.170.0050.00216.91
8.0.160.0070.00016.86
8.0.150.0000.00716.86
8.0.140.0060.00316.82
8.0.130.0070.00213.31
8.0.120.0070.00016.87
8.0.110.0000.00816.75
8.0.100.0000.00716.94
8.0.90.0040.00416.70
8.0.80.0090.00616.84
8.0.70.0080.00017.00
8.0.60.0020.00516.72
8.0.50.0050.00216.87
8.0.30.0100.01217.16
8.0.20.0100.01017.40
8.0.10.0070.00016.95
8.0.00.0090.01116.68
7.4.330.0030.00315.08
7.4.320.0000.00616.62
7.4.300.0060.00016.63
7.4.290.0000.00716.57
7.4.280.0040.00416.59
7.4.270.0000.00616.56
7.4.260.0070.00016.58
7.4.250.0040.00416.55
7.4.240.0020.00516.40
7.4.230.0070.00016.61
7.4.220.0120.00616.69
7.4.210.0030.01216.70
7.4.200.0070.00016.66
7.4.160.0130.00716.72
7.4.150.0070.01017.40
7.4.140.0150.00517.86
7.4.130.0100.00816.52
7.4.120.0090.00916.57
7.4.110.0090.01316.43
7.4.100.0030.01416.53
7.4.90.0070.01016.53
7.4.80.0140.00619.39
7.4.70.0080.00816.50
7.4.60.0120.00916.51
7.4.50.0080.00016.65
7.4.40.0070.01016.39
7.4.30.0130.00316.57
7.4.00.0000.01614.69
7.3.330.0000.00613.30
7.3.320.0000.00613.23
7.3.310.0030.00316.45
7.3.300.0070.00016.21
7.3.290.0080.00616.31
7.3.280.0100.00616.33
7.3.270.0100.00717.40
7.3.260.0110.01216.50
7.3.250.0110.00616.24
7.3.240.0130.00316.54
7.3.230.0140.01116.39
7.3.210.0130.00316.21
7.3.200.0090.01319.39
7.3.190.0100.01016.23
7.3.180.0000.01616.32
7.3.170.0030.01416.27
7.3.160.0100.00716.25
7.2.330.0100.00716.67
7.2.320.0110.00716.46
7.2.310.0060.01516.48
7.2.300.0100.00716.68
7.2.290.0160.00616.47
7.2.80.0000.01216.75
7.2.60.0270.00416.54
7.1.200.0100.00315.82
7.1.100.0030.00918.05
7.1.70.0090.00317.08
7.1.60.0070.01020.03
7.1.50.0070.01716.99
7.1.00.0030.07022.27
7.0.200.0060.00914.97
7.0.60.0070.05319.84
7.0.50.0070.07017.72
7.0.40.0030.04720.20
7.0.30.0300.04720.17
7.0.20.0230.07320.30
7.0.10.0170.04720.01
7.0.00.0070.09020.03
5.6.280.0030.06720.81
5.6.210.0030.07020.68
5.6.200.0170.07018.21
5.6.190.0100.03720.44
5.6.180.0270.07720.57
5.6.170.0230.08020.51
5.6.160.0170.07720.37
5.6.150.0070.04018.16
5.6.140.0070.08018.07
5.6.130.0070.05718.17
5.6.120.0000.04321.11
5.6.110.0130.05321.00
5.6.100.0030.05021.10
5.6.90.0070.08320.99
5.6.80.0100.07320.41
5.5.350.0230.07720.40
5.5.340.0100.07317.98
5.5.330.0170.06720.13
5.5.320.0330.04320.30
5.5.310.0170.04720.31
5.5.300.0100.08317.88
5.5.290.0000.05317.96
5.5.280.0230.06720.68
5.5.270.0070.04320.86
5.5.260.0100.03720.74
5.5.250.0130.05020.54
5.5.240.2630.04320.15
5.4.450.0530.06019.10
5.4.440.0700.06319.09
5.4.430.0570.06019.40
5.4.420.0700.05319.39
5.4.410.0630.05719.36
5.4.400.0770.04319.04
5.4.390.0530.06319.04
5.4.380.0730.05019.04
5.4.370.0700.04719.07
5.4.360.0700.04719.29
5.4.350.0800.07319.21
5.4.340.0770.05719.21
5.4.320.1000.05718.89
5.4.310.0930.06719.04
5.4.300.0770.04319.14
5.4.290.0470.04719.00
5.4.280.0100.05719.07
5.4.270.0600.05318.87
5.4.260.1000.05319.23
5.4.250.0400.05019.30
5.4.240.0470.04019.23
5.4.230.0200.05319.20
5.4.220.0130.06718.87
5.4.210.0270.05018.98
5.4.200.0270.05316.52
5.4.190.0300.06019.23
5.4.180.0230.04319.04
5.4.170.0200.05718.78
5.4.160.0070.06019.25
5.4.150.0170.05019.07
5.4.140.0130.05316.26
5.4.130.0130.06316.49
5.4.120.0100.05316.41
5.4.110.0170.05016.37
5.4.100.0230.04316.59
5.4.90.0130.05716.45
5.4.80.0100.05716.45
5.4.70.0170.04716.31
5.4.60.0000.04016.20
5.4.50.0070.07016.21
5.4.40.0300.05716.36
5.4.30.0430.05316.04
5.4.20.0270.07016.19

preferences:
39.68 ms | 401 KiB | 5 Q