3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array( 'foo' => 'bar', 'b' => array('a','b','c','d'), 'loa', 1000 => 'm', ); $obj = json_decode(json_encode($a)); var_dump($a); var_dump(json_decode(json_encode($obj), false));

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.0110.00718.05
8.3.50.0110.00521.86
8.3.40.0090.00918.55
8.3.30.0030.01018.92
8.3.20.0000.00720.07
8.3.10.0080.00021.90
8.3.00.0040.00417.68
8.2.180.0120.00916.75
8.2.170.0090.00622.96
8.2.160.0090.00620.39
8.2.150.0050.00324.18
8.2.140.0070.00024.66
8.2.130.0070.01126.16
8.2.120.0080.00021.15
8.2.110.0090.00022.10
8.2.100.0080.00417.97
8.2.90.0080.00019.22
8.2.80.0000.00817.97
8.2.70.0050.00317.63
8.2.60.0000.00917.91
8.2.50.0000.00818.07
8.2.40.0000.00917.91
8.2.30.0050.00517.98
8.2.20.0040.00417.56
8.2.10.0040.00417.93
8.2.00.0080.00017.78
8.1.280.0120.00325.92
8.1.270.0090.00023.66
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0050.00523.96
8.1.230.0030.00919.14
8.1.220.0050.00317.74
8.1.210.0050.00318.77
8.1.200.0030.00617.23
8.1.190.0040.00417.23
8.1.180.0000.00818.10
8.1.170.0040.00418.59
8.1.160.0020.00521.84
8.1.150.0050.00218.77
8.1.140.0080.00017.29
8.1.130.0030.00317.73
8.1.120.0000.00717.26
8.1.110.0070.00017.34
8.1.100.0070.00017.45
8.1.90.0070.00017.25
8.1.80.0000.00717.38
8.1.70.0070.00017.27
8.1.60.0000.00817.49
8.1.50.0080.00017.44
8.1.40.0030.00617.45
8.1.30.0040.00417.55
8.1.20.0000.00717.49
8.1.10.0000.00717.45
8.1.00.0070.00017.34
8.0.300.0000.00818.77
8.0.290.0000.00716.63
8.0.280.0000.00718.45
8.0.270.0000.00717.14
8.0.260.0030.00317.18
8.0.250.0030.00316.88
8.0.240.0030.00316.86
8.0.230.0040.00416.93
8.0.220.0030.00316.84
8.0.210.0030.00316.75
8.0.200.0000.00816.88
8.0.190.0000.00716.85
8.0.180.0030.00516.72
8.0.170.0030.00516.72
8.0.160.0000.00816.82
8.0.150.0000.00716.79
8.0.140.0030.00416.73
8.0.130.0000.00613.22
8.0.120.0040.00416.75
8.0.110.0080.00016.84
8.0.100.0000.00716.88
8.0.90.0080.00016.71
8.0.80.0090.00616.75
8.0.70.0000.00716.88
8.0.60.0040.00416.70
8.0.50.0020.00516.71
8.0.30.0120.00916.96
8.0.20.0090.01117.40
8.0.10.0040.00416.79
8.0.00.0060.01416.69
7.4.330.0060.00015.13
7.4.320.0060.00016.57
7.4.300.0070.00316.45
7.4.290.0040.00416.45
7.4.280.0050.00216.33
7.4.270.0040.00416.54
7.4.260.0070.00016.39
7.4.250.0040.00416.25
7.4.240.0060.00216.37
7.4.230.0040.00416.46
7.4.220.0060.01216.54
7.4.210.0040.01116.33
7.4.200.0040.00416.26
7.4.160.0140.00316.59
7.4.150.0090.00917.40
7.4.140.0120.00917.86
7.4.130.0110.00716.55
7.4.120.0110.00716.57
7.4.110.0090.00916.49
7.4.100.0180.00016.27
7.4.90.0150.00316.38
7.4.80.0100.00719.39
7.4.70.0120.00616.32
7.4.60.0150.00916.34
7.4.50.0060.00016.20
7.4.40.0000.01616.20
7.4.30.0110.00516.23
7.4.00.0070.00715.02
7.3.330.0030.00313.12
7.3.320.0030.00312.98
7.3.310.0070.00016.20
7.3.300.0000.00716.09
7.3.290.0030.01716.19
7.3.280.0110.00916.13
7.3.270.0090.00917.40
7.3.260.0090.01016.40
7.3.250.0100.00816.16
7.3.240.0090.00916.15
7.3.230.0130.00516.39
7.3.210.0110.00716.02
7.3.200.0030.01619.39
7.3.190.0150.00616.06
7.3.180.0160.00816.26
7.3.170.0120.00416.27
7.3.160.0100.01416.49
7.3.120.0000.01714.89
7.3.10.0100.00516.34
7.3.00.0080.00416.38
7.2.330.0120.00816.54
7.2.320.0140.00816.30
7.2.310.0110.00716.49
7.2.300.0120.00616.14
7.2.290.0120.00616.29
7.2.130.0170.00316.80
7.2.120.0050.00516.68
7.2.110.0050.00516.82
7.2.100.0100.00316.83
7.2.90.0060.00516.63
7.2.80.0090.00516.85
7.2.70.0070.00716.69
7.2.60.0080.00716.77
7.2.50.0050.00916.93
7.2.40.0030.00816.85
7.2.30.0030.00816.84
7.2.20.0070.00416.84
7.2.10.0060.00516.72
7.2.00.0090.00717.47
7.1.250.0040.00815.67
7.1.240.0080.00815.79
7.1.230.0070.00715.79
7.1.220.0110.00415.73
7.1.210.0030.01015.73
7.1.200.0090.00615.71
7.1.190.0070.00715.31
7.1.180.0080.00315.84
7.1.170.0070.00715.56
7.1.160.0060.00615.75
7.1.150.0070.00415.82
7.1.140.0100.00315.85
7.1.130.0130.00615.61
7.1.120.0060.01015.52
7.1.110.0130.00015.62
7.1.100.0070.00416.89
7.1.90.0030.00715.88
7.1.80.0030.01015.42
7.1.70.0060.00316.46
7.1.60.0050.01317.35
7.1.50.0070.00816.45
7.1.40.0060.00615.56
7.1.30.0100.00315.63
7.1.20.0080.00315.61
7.1.10.0030.00715.60
7.1.00.0020.04419.07
7.0.330.0070.00715.25
7.0.320.0000.00915.10
7.0.310.0090.00615.42
7.0.300.0030.00715.04
7.0.290.0140.00315.45
7.0.280.0080.00415.24
7.0.270.0070.01014.94
7.0.260.0030.00615.23
7.0.250.0000.01015.30
7.0.240.0070.00315.16
7.0.230.0090.00415.11
7.0.220.0120.00615.23
7.0.210.0000.01115.07
7.0.200.0060.00415.95
7.0.190.0000.00915.14
7.0.180.0110.00315.32
7.0.170.0000.01114.80
7.0.160.0040.00815.21
7.0.150.0050.00514.98
7.0.140.0030.04218.62
7.0.130.0100.00315.28
7.0.120.0030.00615.47
7.0.110.0060.00615.04
7.0.100.0070.00715.21
7.0.90.0270.02217.65
7.0.80.0240.02517.53
7.0.70.0250.03217.53
7.0.60.0250.02017.67
7.0.50.0230.02217.90
7.0.40.0020.02716.59
7.0.30.0050.02216.76
7.0.20.0080.01816.68
7.0.10.0050.02316.74
7.0.00.0050.02216.55
5.6.380.0070.00313.70
5.6.370.0000.00814.38
5.6.360.0000.00914.08
5.6.350.0030.00714.25
5.6.340.0030.00714.04
5.6.330.0070.00314.36
5.6.320.0060.00314.24
5.6.310.0000.01213.87
5.6.300.0030.00914.30
5.6.290.0030.00714.38
5.6.280.0050.03817.59
5.6.270.0060.00314.20
5.6.260.0060.00614.31
5.6.250.0030.01013.79
5.6.240.0020.02917.36
5.6.230.0090.02017.18
5.6.220.0080.02217.32
5.6.210.0000.02817.19
5.6.200.0050.02417.56
5.6.190.0090.02117.55
5.6.180.0060.02517.62
5.6.170.0120.03717.47
5.6.160.0000.02917.50
5.6.150.0030.02717.70
5.6.140.0050.02317.46
5.6.130.0030.02717.58
5.6.120.0070.02217.55
5.6.110.0020.02717.53
5.6.100.0080.02517.56
5.6.90.0050.02917.53
5.6.80.0010.03617.31
5.6.70.0050.02217.38
5.6.60.0040.04417.41
5.6.50.0050.03517.40
5.6.40.0250.01017.28
5.6.30.0090.03817.21
5.6.20.0080.03017.29
5.6.10.0030.04917.20
5.6.00.0120.04017.30
5.5.380.0080.03515.68
5.5.370.0030.02015.65
5.5.360.0040.02315.68
5.5.350.0070.04015.60
5.5.340.0050.02515.78
5.5.330.0060.01815.69
5.5.320.0020.02315.90
5.5.310.0070.02715.78
5.5.300.0030.02515.96
5.5.290.0040.02215.90
5.5.280.0030.03015.88
5.5.270.0060.03315.95
5.5.260.0030.02315.98
5.5.250.0090.01615.84
5.5.240.0030.02515.49
5.5.230.0020.02515.52
5.5.220.0050.02615.58
5.5.210.0050.02515.56
5.5.200.0110.03615.65
5.5.190.0050.04115.54
5.5.180.0090.04415.55
5.5.170.0040.00410.59
5.5.160.0070.03915.43
5.5.150.0120.03115.58
5.5.140.0070.03515.51
5.5.130.0120.02215.50
5.5.120.0070.03515.39
5.5.110.0030.02515.39
5.5.100.0070.03915.33
5.5.90.0070.04015.43
5.5.80.0080.03515.46
5.5.70.0030.02215.40
5.5.60.0020.03515.39
5.5.50.0060.03815.51
5.5.40.0030.02815.21
5.5.30.0040.04315.45
5.5.20.0050.04115.33
5.5.10.0000.02915.52
5.5.00.0050.02615.48
5.4.450.0030.02215.12
5.4.440.0050.02215.13
5.4.430.0050.04215.06
5.4.420.0000.02315.10
5.4.410.0030.02815.08
5.4.400.0030.01914.94
5.4.390.0030.02214.89
5.4.380.0050.03514.90
5.4.370.0070.03715.07
5.4.360.0020.03414.92
5.4.350.0070.03114.84
5.4.340.0060.04314.85
5.4.330.0040.00410.79
5.4.320.0070.03614.86
5.4.310.0130.03214.99
5.4.300.0050.02314.78
5.4.290.0020.03015.05
5.4.280.0090.04014.77
5.4.270.0080.03614.86
5.4.260.0080.03514.86
5.4.250.0030.04014.96
5.4.240.0030.03314.70
5.4.230.0070.02214.79
5.4.220.0050.03214.78
5.4.210.0030.03814.86
5.4.200.0030.03714.86
5.4.190.0090.03414.97
5.4.180.0080.03514.68
5.4.170.0050.02314.87
5.4.160.0030.03414.98
5.4.150.0060.03814.84
5.4.140.0020.04313.52
5.4.130.0020.02913.55
5.4.120.0060.03613.40
5.4.110.0060.03813.63
5.4.100.0030.02413.63
5.4.90.0040.03013.53
5.4.80.0060.03113.62
5.4.70.0080.01713.42
5.4.60.0060.03813.46
5.4.50.0050.03213.42
5.4.40.0030.03513.56
5.4.30.0090.03713.39
5.4.20.0050.02513.56
5.4.10.0030.04213.53
5.4.00.0030.04013.27
5.3.290.0050.03012.61
5.3.280.0030.02212.48
5.3.270.0030.02312.41
5.3.260.0030.02812.57
5.3.250.0080.03712.47
5.3.240.0090.03712.40
5.3.230.0050.03712.39
5.3.220.0070.03812.40
5.3.210.0020.03312.50
5.3.200.0100.02912.35
5.3.190.0030.04012.48
5.3.180.0030.02812.38
5.3.170.0040.02312.38
5.3.160.0050.04312.54
5.3.150.0070.03712.46
5.3.140.0080.03312.45
5.3.130.0030.04312.36
5.3.120.0080.03512.45
5.3.110.0050.03712.47
5.3.100.0030.04112.26
5.3.90.0030.03012.12
5.3.80.0040.02512.07
5.3.70.0030.02012.05
5.3.60.0030.02312.30
5.3.50.0050.01812.09
5.3.40.0020.02612.12
5.3.30.0120.03312.08
5.3.20.0020.02811.96
5.3.10.0140.01011.85
5.3.00.0080.03311.95
5.2.170.0060.01510.53
5.2.160.0050.02810.55
5.2.150.0060.01710.45
5.2.140.0030.02810.57
5.2.130.0030.01810.55
5.2.120.0050.01610.51
5.2.110.0050.03510.55
5.2.100.0050.02210.53
5.2.90.0040.01810.46
5.2.80.0030.03210.43
5.2.70.0090.02110.49
5.2.60.0020.03410.43
5.2.50.0030.02510.45
5.2.40.0080.02810.43
5.2.30.0030.02010.38
5.2.20.0080.02710.39
5.2.10.0030.03210.43
5.2.00.0080.02310.35
5.1.60.0000.03010.01
5.1.50.0020.0239.99
5.1.40.0020.0309.97
5.1.30.0020.02710.17
5.1.20.0040.02910.16
5.1.10.0070.02310.04
5.1.00.0060.0279.99
5.0.50.0070.0209.28
5.0.40.0050.0219.21
5.0.30.0000.0329.10
5.0.20.0010.0259.12
5.0.10.0030.0239.08
5.0.00.0030.0319.05
4.4.90.0020.0128.54
4.4.80.0020.0198.54
4.4.70.0050.0158.54
4.4.60.0030.0118.54
4.4.50.0020.0128.54
4.4.40.0030.0268.54
4.4.30.0020.0188.54
4.4.20.0030.0138.54
4.4.10.0030.0128.54
4.4.00.0070.0228.54
4.3.110.0020.0198.54
4.3.100.0000.0218.54
4.3.90.0070.0138.54
4.3.80.0040.0258.54
4.3.70.0000.0168.54
4.3.60.0040.0108.54
4.3.50.0000.0158.54
4.3.40.0000.0298.54
4.3.30.0010.0208.54
4.3.20.0030.0188.54
4.3.10.0050.0128.54
4.3.00.0020.0188.54

preferences:
48.02 ms | 401 KiB | 5 Q