3v4l.org

run code in 300+ PHP versions simultaneously
<?php $json = new stdClass; $str = 'foo'; $abc = 'bar'; $json->$str = $abc; echo $json->$str; echo json_encode($json);

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.0100.01018.43
8.3.50.0140.00821.20
8.3.40.0090.00618.50
8.3.30.0140.00418.43
8.3.20.0060.00920.34
8.3.10.0000.00823.59
8.3.00.0050.00323.71
8.2.180.0080.00818.54
8.2.170.0040.01122.96
8.2.160.0070.00720.32
8.2.150.0050.00324.18
8.2.140.0090.00024.66
8.2.130.0040.00419.77
8.2.120.0050.00326.35
8.2.110.0090.00020.83
8.2.100.0070.00417.80
8.2.90.0040.00419.21
8.2.80.0030.00617.97
8.2.70.0060.00317.63
8.2.60.0060.00318.03
8.2.50.0070.00018.07
8.2.40.0050.00322.31
8.2.30.0040.00419.31
8.2.20.0000.00717.75
8.2.10.0000.00718.16
8.2.00.0030.00518.01
8.1.280.0070.00725.92
8.1.270.0040.00423.84
8.1.260.0050.00328.09
8.1.250.0070.00328.09
8.1.240.0030.00622.45
8.1.230.0080.00419.16
8.1.220.0060.00317.74
8.1.210.0030.00618.77
8.1.200.0030.00617.23
8.1.190.0080.00017.35
8.1.180.0020.00518.10
8.1.170.0060.00318.50
8.1.160.0000.00720.71
8.1.150.0000.00818.80
8.1.140.0030.00619.48
8.1.130.0000.00717.60
8.1.120.0050.00217.36
8.1.110.0040.00417.45
8.1.100.0050.00317.45
8.1.90.0000.00717.45
8.1.80.0080.00017.37
8.1.70.0040.00417.36
8.1.60.0040.00417.55
8.1.50.0030.00617.41
8.1.40.0060.00317.56
8.1.30.0000.00817.50
8.1.20.0060.00317.59
8.1.10.0050.00217.43
8.1.00.0040.00417.50
8.0.300.0000.00718.77
8.0.290.0030.00616.75
8.0.280.0040.00418.44
8.0.270.0000.00817.25
8.0.260.0000.00817.18
8.0.250.0030.00316.85
8.0.240.0070.00016.97
8.0.230.0040.00416.98
8.0.220.0050.00216.92
8.0.210.0040.00416.92
8.0.200.0000.00816.84
8.0.190.0050.00316.92
8.0.180.0030.00316.93
8.0.170.0040.00416.79
8.0.160.0000.00716.75
8.0.150.0000.00716.76
8.0.140.0000.00716.81
8.0.130.0030.00313.39
8.0.120.0080.00016.88
8.0.110.0040.00416.93
8.0.100.0000.00816.77
8.0.90.0040.00416.77
8.0.80.0110.01116.88
8.0.70.0040.00416.73
8.0.60.0000.00716.78
8.0.50.0040.00416.77
8.0.30.0120.00717.12
8.0.20.0080.01317.40
8.0.10.0000.00717.06
8.0.00.0130.00816.87
7.4.330.0050.00016.79
7.4.320.0000.00616.60
7.4.300.0030.00516.41
7.4.290.0030.00316.54
7.4.280.0000.00916.43
7.4.270.0030.00316.57
7.4.260.0070.00416.34
7.4.250.0000.00816.38
7.4.240.0050.00216.51
7.4.230.0040.00416.55
7.4.220.0040.01416.57
7.4.210.0040.01116.61
7.4.200.0030.00316.46
7.4.160.0120.01216.55
7.4.150.0110.00717.40
7.4.140.0130.01017.86
7.4.130.0170.00216.45
7.4.120.0090.00916.51
7.4.110.0120.00616.48
7.4.100.0070.01116.56
7.4.90.0100.00716.49
7.4.80.0070.01119.39
7.4.70.0030.01516.46
7.4.60.0040.01216.51
7.4.50.0100.00316.39
7.4.40.0120.00616.60
7.4.30.0130.00616.50
7.4.10.0040.01414.81
7.4.00.0050.00914.99
7.3.330.0050.00013.18
7.3.320.0000.00613.24
7.3.310.0050.00316.08
7.3.300.0060.00016.13
7.3.290.0070.01116.26
7.3.280.0100.01016.31
7.3.270.0070.01017.40
7.3.260.0060.01216.49
7.3.250.0100.01016.35
7.3.240.0130.00316.31
7.3.230.0090.00916.41
7.3.210.0100.00716.45
7.3.200.0180.00019.39
7.3.190.0100.00516.29
7.3.180.0070.01416.48
7.3.170.0130.00716.31
7.3.160.0080.00816.47
7.3.130.0120.00614.84
7.3.120.0070.01014.57
7.3.110.0100.01014.88
7.3.100.0130.00014.68
7.3.90.0070.00414.63
7.3.80.0030.01414.84
7.3.70.0070.00714.78
7.3.60.0030.00514.62
7.3.50.0030.01014.80
7.3.40.0060.00614.86
7.3.30.0070.00414.57
7.3.20.0000.01416.39
7.3.10.0040.01016.43
7.3.00.0100.00716.53
7.2.330.0100.00716.70
7.2.320.0160.00316.62
7.2.310.0040.01916.74
7.2.300.0080.00816.65
7.2.290.0140.00416.73
7.2.260.0110.00714.81
7.2.250.0040.01514.90
7.2.240.0040.01114.75
7.2.230.0060.00915.22
7.2.220.0100.00714.88
7.2.210.0030.00914.75
7.2.200.0110.00414.70
7.2.190.0030.01014.93
7.2.180.0070.00314.86
7.2.170.0090.00314.64
7.2.160.0080.00315.01
7.2.150.0070.00716.57
7.2.140.0030.01016.57
7.2.130.0060.01016.89
7.2.120.0030.00616.66
7.2.110.0060.00616.95
7.2.100.0000.01416.67
7.2.90.0000.01016.91
7.2.80.0030.01016.79
7.2.70.0040.00716.92
7.2.60.0040.00716.66
7.2.50.0040.01217.12
7.2.40.0070.00716.81
7.2.30.0070.00716.93
7.2.20.0100.00317.04
7.2.10.0040.00716.67
7.2.00.0030.00818.14
7.1.330.0000.01415.79
7.1.320.0030.00715.96
7.1.310.0040.00715.77
7.1.300.0050.00515.53
7.1.290.0070.00715.47
7.1.280.0000.01215.74
7.1.270.0090.00615.71
7.1.260.0060.00615.69
7.1.250.0040.00915.79
7.1.240.0080.00415.86
7.1.230.0030.00915.75
7.1.220.0040.00715.75
7.1.210.0000.01415.86
7.1.200.0140.00015.72
7.1.190.0070.00715.73
7.1.180.0030.01015.65
7.1.170.0040.01115.86
7.1.160.0030.01015.44
7.1.150.0060.00615.70
7.1.140.0040.01115.48
7.1.130.0000.01615.84
7.1.120.0030.01315.64
7.1.110.0070.01015.83
7.1.100.0030.01016.51
7.1.90.0030.01416.02
7.1.80.0090.00615.89
7.1.70.0050.00716.53
7.1.60.0070.00817.50
7.1.50.0100.00716.22
7.1.40.0120.00315.66
7.1.30.0000.01215.37
7.1.20.0030.00915.74
7.1.10.0030.00715.83
7.1.00.0070.04018.92
7.0.330.0000.01415.34
7.0.320.0070.00715.34
7.0.310.0070.00415.26
7.0.300.0030.01015.57
7.0.290.0050.00515.27
7.0.280.0060.01215.15
7.0.270.0060.01315.35
7.0.260.0000.02015.59
7.0.250.0100.01115.13
7.0.240.0000.01915.45
7.0.230.0040.01115.18
7.0.220.0090.00815.38
7.0.210.0130.00615.12
7.0.200.0060.00816.09
7.0.190.0060.01215.56
7.0.180.0070.00715.36
7.0.170.0070.00715.13
7.0.160.0110.00415.33
7.0.150.0000.01415.29
7.0.140.0050.00515.39
7.0.130.0040.00815.43
7.0.120.0080.00315.54
7.0.110.0040.01115.43
7.0.100.0040.00715.42
7.0.90.0300.02217.71
7.0.80.0280.04317.66
7.0.70.0300.04217.65
7.0.60.0300.03817.66
7.0.50.0280.03917.86
7.0.40.0070.04216.66
7.0.30.0020.03016.74
7.0.20.0120.03816.65
7.0.10.0060.02716.81
7.0.00.0070.02816.79
5.6.400.0080.00814.16
5.6.390.0030.01014.47
5.6.380.0060.00614.37
5.6.370.0070.00714.16
5.6.360.0050.00514.30
5.6.350.0090.00614.34
5.6.340.0070.01014.02
5.6.330.0110.00514.34
5.6.320.0040.01214.28
5.6.310.0150.00314.33
5.6.300.0080.00414.54
5.6.290.0070.00313.96
5.6.280.0050.03317.59
5.6.270.0140.00014.70
5.6.260.0030.00914.14
5.6.250.0060.00614.21
5.6.240.0100.02217.48
5.6.230.0070.04317.49
5.6.220.0100.04417.50
5.6.210.0080.04017.41
5.6.200.0070.04117.76
5.6.190.0050.04317.61
5.6.180.0080.02117.56
5.6.170.0070.04017.73
5.6.160.0090.02017.75
5.6.150.0070.04017.70
5.6.140.0110.03817.66
5.6.130.0050.04317.72
5.6.120.0050.02217.56
5.6.110.0090.03517.64
5.6.100.0030.04817.57
5.6.90.0090.03917.60
5.6.80.0070.03517.27
5.6.70.0080.04217.27
5.6.60.0030.04217.27
5.6.50.0110.04117.40
5.6.40.0020.04717.32
5.6.30.0080.03817.24
5.6.20.0030.04717.29
5.6.10.0000.03517.20
5.6.00.0060.02617.35
5.5.380.0110.03717.34
5.5.370.0050.02717.37
5.5.360.0040.04617.29
5.5.350.0080.03717.31
5.5.340.0070.02317.50
5.5.330.0070.04517.52
5.5.320.0120.03817.45
5.5.310.0120.03517.42
5.5.300.0080.02517.30
5.5.290.0070.02417.41
5.5.280.0100.02217.55
5.5.270.0070.02017.55
5.5.260.0030.02617.45
5.5.250.0070.02717.37
5.5.240.0060.02917.00
5.5.230.0050.04716.94
5.5.220.0070.04416.96
5.5.210.0030.05017.00
5.5.200.0130.02017.11
5.5.190.0060.03117.09
5.5.180.0050.03117.23
5.5.170.0040.01113.89
5.5.160.0150.03616.99
5.5.150.0070.04916.88
5.5.140.0060.03617.22
5.5.130.0060.02817.13
5.5.120.0070.04217.11
5.5.110.0070.02217.22
5.5.100.0060.04416.90
5.5.90.0050.04516.85
5.5.80.0120.03817.01
5.5.70.0080.04317.11
5.5.60.0100.03217.01
5.5.50.0090.03816.76
5.5.40.0080.04017.07
5.5.30.0020.02916.88
5.5.20.0070.04316.90
5.5.10.0030.03717.12
5.5.00.0050.03817.01

preferences:
32.04 ms | 401 KiB | 5 Q