3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a1 = new stdclass; $a2 = new stdclass; $a3 = new stdclass; $a4 = new stdclass; $a5 = new stdclass; $a6 = new stdclass; $a7 = new stdclass; $a8 = new stdclass; $a9 = new stdclass; function bla($o){ return substr(spl_object_hash($o), 0, 16); } for($i = 1; $i < 10; $i++){ $var = ${'a' . $i}; var_dump($var); $r = hex2bin(bla($var)) ^ hex2bin(bla($a1)); $i = (int)bin2hex($r); $i += ($i % 2) === 0 ? 1 : -1; echo $i . "\n"; echo "-------------------\n"; }

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.4.140.0110.01017.70
8.4.130.0080.00418.97
8.4.120.0090.01023.88
8.4.110.0090.01118.88
8.4.100.0040.00518.82
8.4.90.0100.01022.22
8.4.80.0140.00718.63
8.4.70.0110.00818.83
8.4.60.0130.00618.87
8.4.50.0110.00918.61
8.4.40.0100.01019.53
8.4.30.0170.00317.88
8.4.20.0100.01017.67
8.4.10.0060.00617.85
8.3.270.0130.00716.47
8.3.260.0090.01016.89
8.3.250.0090.00918.91
8.3.240.0090.01117.09
8.3.230.0120.00716.70
8.3.220.0060.00219.09
8.3.210.0060.00316.66
8.3.200.0070.00216.62
8.3.190.0120.00517.20
8.3.180.0110.00720.46
8.3.170.0080.00018.98
8.3.160.0180.00017.14
8.3.150.0150.00416.49
8.3.140.0070.01020.70
8.3.130.0030.00618.58
8.3.120.0040.00418.74
8.3.110.0060.00320.94
8.3.100.0080.00024.06
8.3.90.0040.00426.77
8.3.80.0090.00016.50
8.3.70.0180.00016.63
8.3.60.0140.00018.55
8.3.50.0100.00522.06
8.3.40.0120.00318.67
8.3.30.0090.00618.46
8.3.20.0000.00821.90
8.3.10.0030.00620.27
8.3.00.0040.00421.97
8.2.290.0100.00620.51
8.2.280.0110.00918.51
8.2.270.0090.00616.67
8.2.260.0150.00316.77
8.2.250.0110.00716.77
8.2.240.0040.00418.82
8.2.230.0060.00322.58
8.2.220.0060.00337.54
8.2.210.0000.00826.77
8.2.200.0070.00416.63
8.2.190.0090.00916.63
8.2.180.0120.00918.29
8.2.170.0070.00722.96
8.2.160.0030.01022.12
8.2.150.0050.00324.18
8.2.140.0050.00324.66
8.2.130.0000.00726.16
8.2.120.0070.00021.06
8.2.110.0070.00321.08
8.2.100.0060.00617.84
8.2.90.0080.00018.16
8.2.80.0050.00517.97
8.2.70.0000.00818.04
8.2.60.0040.00418.22
8.2.50.0050.00318.10
8.2.40.0030.00619.39
8.2.30.0000.00719.22
8.2.20.0040.00418.14
8.2.10.0000.00718.03
8.2.00.0040.00417.77
8.1.330.0110.00922.10
8.1.320.0130.00616.09
8.1.310.0090.00916.02
8.1.300.0090.00620.19
8.1.290.0060.00318.88
8.1.280.0070.01425.92
8.1.270.0080.00023.72
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0030.00721.29
8.1.230.0080.00420.95
8.1.220.0030.00517.74
8.1.210.0000.00818.88
8.1.200.0000.00817.22
8.1.190.0040.00417.23
8.1.180.0030.00618.10
8.1.170.0040.00418.64
8.1.160.0040.00418.87
8.1.150.0040.00418.67
8.1.140.0000.00819.52
8.1.130.0000.00719.01
8.1.120.0000.00717.48
8.1.110.0040.00417.45
8.1.100.0040.00417.47
8.1.90.0000.00817.45
8.1.80.0000.00717.50
8.1.70.0000.00717.54
8.1.60.0030.00517.63
8.1.50.0040.00417.53
8.1.40.0060.00317.54
8.1.30.0000.00817.75
8.1.20.0040.00417.55
8.1.10.0040.00417.59
8.1.00.0040.00417.57
8.0.300.0040.00419.95
8.0.290.0000.00716.75
8.0.280.0030.00518.43
8.0.270.0030.00317.28
8.0.260.0000.00617.24
8.0.250.0000.00716.99
8.0.240.0040.00417.00
8.0.230.0030.00316.86
8.0.220.0000.00716.86
8.0.210.0080.00016.80
8.0.200.0030.00317.00
8.0.190.0000.00716.95
8.0.180.0060.00316.90
8.0.170.0050.00316.84
8.0.160.0040.00417.01
8.0.150.0080.00016.92
8.0.140.0040.00416.78
8.0.130.0030.00313.30
8.0.120.0030.00516.76
8.0.110.0080.00016.88
8.0.100.0000.00816.82
8.0.90.0070.00016.79
8.0.80.0030.01416.89
8.0.70.0040.00416.86
8.0.60.0050.00216.86
8.0.50.0070.00016.90
8.0.30.0120.00817.19
8.0.20.0130.00917.40
8.0.10.0040.00416.93
8.0.00.0130.00716.67
7.4.330.0030.00315.55
7.4.320.0000.00616.58
7.4.300.0000.00616.54
7.4.290.0030.00616.62
7.4.280.0030.00616.42
7.4.270.0000.00716.55
7.4.260.0000.00816.57
7.4.250.0000.00716.50
7.4.240.0040.00416.52
7.4.230.0030.00316.60
7.4.220.0090.01216.50
7.4.210.0100.01016.64
7.4.200.0000.00716.62
7.4.160.0090.00716.63
7.4.150.0060.01217.40
7.4.140.0150.01117.86
7.4.130.0100.00816.49
7.4.120.0080.01016.55
7.4.110.0100.00716.51
7.4.100.0000.01716.45
7.4.90.0070.01016.60
7.4.80.0100.00719.39
7.4.70.0060.01016.52
7.4.60.0070.01016.45
7.4.50.0090.00616.47
7.4.40.0030.01516.52
7.4.30.0060.01116.52
7.4.10.0080.00415.02
7.4.00.0070.00814.88
7.3.330.0000.00513.20
7.3.320.0020.00313.11
7.3.310.0030.00516.36
7.3.300.0030.00316.33
7.3.290.0100.00516.35
7.3.280.0120.00716.29
7.3.270.0040.01417.40
7.3.260.0060.01316.57
7.3.250.0050.01416.42
7.3.240.0090.01216.34
7.3.230.0080.00816.22
7.3.210.0030.01816.30
7.3.200.0060.01016.39
7.3.190.0100.00716.66
7.3.180.0090.00816.61
7.3.170.0100.00716.38
7.3.160.0090.00916.41
7.3.130.0130.00314.92
7.3.120.0150.00414.78
7.3.110.0130.00615.02
7.3.100.0070.00715.05
7.3.90.0070.01114.78
7.3.80.0000.01414.82
7.3.70.0100.00314.70
7.3.60.0100.00014.51
7.3.50.0000.01314.91
7.3.40.0090.00614.65
7.3.30.0030.00915.01
7.3.20.0070.01416.63
7.3.10.0090.00316.62
7.3.00.0030.01016.75
7.2.330.0090.01016.82
7.2.320.0050.01316.93
7.2.310.0070.01016.85
7.2.300.0040.01916.73
7.2.290.0130.00716.79
7.2.260.0070.01115.29
7.2.250.0100.00314.76
7.2.240.0110.00715.28
7.2.230.0060.00915.23
7.2.220.0140.00315.26
7.2.210.0060.00915.00
7.2.200.0040.00815.17
7.2.190.0070.00714.91
7.2.180.0040.01215.05
7.2.170.0070.01114.93
7.2.160.0060.01514.98
7.2.150.0060.01017.00
7.2.140.0030.01017.01
7.2.130.0070.01016.96
7.2.120.0090.00917.00
7.2.110.0030.01317.01
7.2.100.0070.01116.77
7.2.90.0090.00317.19
7.2.80.0040.00816.91
7.2.70.0070.00716.77
7.2.60.0090.00716.94
7.2.50.0060.01017.08
7.2.40.0030.00617.02
7.2.30.0000.01716.95
7.2.20.0030.01016.89
7.2.10.0060.00816.73
7.2.00.0020.01418.23
7.1.330.0120.00615.68
7.1.320.0040.01415.71
7.1.310.0070.00715.57
7.1.300.0130.00315.69
7.1.290.0090.00615.89
7.1.280.0060.00615.79
7.1.270.0030.00615.61
7.1.260.0040.00815.79
7.1.250.0070.01015.79
7.1.240.0120.00015.90
7.1.230.0090.00315.95
7.1.220.0110.00415.86
7.1.210.0030.01015.54
7.1.200.0040.00915.75
7.1.190.0030.01415.74
7.1.180.0000.01516.06
7.1.170.0070.01015.54
7.1.160.0060.00915.47
7.1.150.0080.00816.02
7.1.140.0060.00315.86
7.1.130.0090.00615.84
7.1.120.0030.00715.93
7.1.110.0090.00615.82
7.1.100.0030.01017.08
7.1.90.0000.00915.90
7.1.80.0070.00715.85
7.1.70.0020.01016.29
7.1.60.0030.01016.61
7.1.50.0140.00916.29
7.1.40.0030.01015.78
7.1.30.0060.00715.92
7.1.20.0040.00815.72
7.1.10.0010.04119.06
7.1.00.0170.02919.03
7.0.330.0060.01215.15
7.0.320.0000.01415.44
7.0.310.0110.00415.43
7.0.300.0060.00915.45
7.0.290.0030.01015.42
7.0.280.0060.00615.44
7.0.270.0040.00715.63
7.0.260.0040.00715.28
7.0.250.0060.00315.37
7.0.240.0030.01015.50
7.0.230.0080.00015.49
7.0.220.0040.01115.66
7.0.210.0040.00815.25
7.0.200.0050.01116.01
7.0.190.0040.00715.32
7.0.180.0060.00615.47
7.0.170.0060.01015.39
7.0.160.0070.00715.43
7.0.150.0050.03418.69
7.0.140.0090.03218.62
7.0.130.0100.03418.67
7.0.120.0080.03318.60
7.0.110.0080.03118.62
7.0.100.0020.03918.62
7.0.90.0100.03618.59
7.0.80.0100.02918.61
7.0.70.0090.02918.69
7.0.60.0090.03218.45
7.0.50.0060.04718.56
7.0.40.0090.03217.69
7.0.30.0100.02817.67
7.0.20.0100.03017.67
7.0.10.0060.03317.69
7.0.00.0100.03817.61
5.6.400.0070.00714.61
5.6.390.0090.00614.79
5.6.380.0130.00014.31
5.6.370.0090.00614.43
5.6.360.0100.00014.40
5.6.350.0000.01714.42
5.6.340.0120.00014.34
5.6.330.0030.01214.54
5.6.320.0040.01114.55
5.6.310.0000.01613.90
5.6.300.0000.01014.79
5.6.290.0090.00314.56
5.6.280.0070.00714.51
5.6.270.0100.00614.36
5.6.260.0040.00714.32
5.6.250.0060.00914.52
5.6.240.0070.00714.71
5.6.230.0030.00614.29
5.6.220.0030.01014.52
5.6.210.0060.00914.22
5.6.200.0030.01314.21
5.6.190.0060.00314.31
5.6.180.0030.01014.38
5.6.170.0000.01014.41
5.6.160.0040.01114.18
5.6.150.0060.00914.47
5.6.140.0040.00814.52
5.6.130.0150.00014.24
5.6.120.0060.00614.48
5.6.110.0070.01014.36
5.6.100.0040.00414.48
5.6.90.0070.00714.16
5.6.80.0040.00814.37
5.6.70.0030.01014.27
5.6.60.0040.00814.21
5.6.50.0050.00314.23
5.6.40.0050.00514.32
5.6.30.0070.00714.20
5.6.20.0060.00914.30
5.6.10.0060.00914.39
5.6.00.0060.00614.30

preferences:
39.29 ms | 403 KiB | 5 Q