3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { protected $test = ''; } $test = new Test(); echo 'before' . PHP_EOL; foreach ($test as $key => $value) { echo $key . ' ' . $value . PHP_EOL; } $test->testing = 'testing'; $test->_testing = 'testing2'; echo 'after' . PHP_EOL; foreach ($test as $key => $value) { echo $key . ' ' . $value . PHP_EOL; }

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.70.0070.00718.68
8.3.60.0110.01118.56
8.3.50.0110.01017.50
8.3.40.0090.00618.79
8.3.30.0070.00718.59
8.3.20.0050.00221.95
8.3.10.0090.00023.55
8.3.00.0000.00817.91
8.2.190.0070.00716.75
8.2.180.0090.00616.75
8.2.170.0070.01122.96
8.2.160.0030.01020.90
8.2.150.0040.00424.18
8.2.140.0070.00024.66
8.2.130.0080.00026.16
8.2.120.0070.00421.13
8.2.110.0070.00421.18
8.2.100.0080.00417.78
8.2.90.0040.00420.59
8.2.80.0040.00417.97
8.2.70.0000.00817.92
8.2.60.0050.00317.93
8.2.50.0030.00518.10
8.2.40.0040.00420.34
8.2.30.0080.00019.17
8.2.20.0040.00417.94
8.2.10.0000.00818.09
8.2.00.0070.00018.07
8.1.280.0120.00325.92
8.1.270.0040.01123.80
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0060.00623.84
8.1.230.0080.00320.97
8.1.220.0000.00817.79
8.1.210.0050.00318.91
8.1.200.0070.00317.35
8.1.190.0000.00817.22
8.1.180.0040.00418.10
8.1.170.0040.00418.56
8.1.160.0070.00018.94
8.1.150.0050.00322.09
8.1.140.0040.00419.61
8.1.130.0050.00220.78
8.1.120.0070.00017.46
8.1.110.0040.00417.37
8.1.100.0040.00417.34
8.1.90.0030.00617.37
8.1.80.0040.00417.45
8.1.70.0030.00317.44
8.1.60.0040.00817.55
8.1.50.0020.00517.55
8.1.40.0040.00417.50
8.1.30.0040.00417.65
8.1.20.0090.00017.52
8.1.10.0040.00417.42
8.1.00.0000.00717.51
8.0.300.0000.00719.98
8.0.290.0000.00816.63
8.0.280.0030.00318.39
8.0.270.0070.00017.13
8.0.260.0000.00716.83
8.0.250.0000.00716.92
8.0.240.0000.00816.95
8.0.230.0030.00316.94
8.0.220.0030.00316.88
8.0.210.0070.00016.89
8.0.200.0000.00616.99
8.0.190.0040.00416.85
8.0.180.0000.00716.90
8.0.170.0030.00316.93
8.0.160.0000.00816.82
8.0.150.0000.00716.86
8.0.140.0000.00816.76
8.0.130.0090.00013.34
8.0.120.0050.00216.79
8.0.110.0070.00016.80
8.0.100.0000.00716.94
8.0.90.0000.00816.96
8.0.80.0070.00716.88
8.0.70.0040.00416.73
8.0.60.0040.00416.86
8.0.50.0040.00416.78
8.0.30.0110.00817.10
8.0.20.0060.01317.40
8.0.10.0070.00017.04
8.0.00.0090.00917.02
7.4.330.0040.00415.55
7.4.320.0030.00316.53
7.4.300.0000.00616.40
7.4.290.0030.00616.62
7.4.280.0040.00416.64
7.4.270.0030.00516.57
7.4.260.0070.00016.45
7.4.250.0000.00716.39
7.4.240.0000.00716.49
7.4.230.0030.00516.70
7.4.220.0090.00916.55
7.4.210.0100.00616.46
7.4.200.0030.00316.70
7.4.160.0120.00616.45
7.4.150.0090.00917.40
7.4.140.0060.01317.86
7.4.130.0170.00316.39
7.4.120.0090.01016.51
7.4.110.0070.01016.39
7.4.100.0090.00916.57
7.4.90.0100.00716.59
7.4.80.0090.01419.39
7.4.70.0090.00616.61
7.4.60.0090.00816.57
7.4.50.0080.00416.28
7.4.40.0130.01016.36
7.4.30.0090.00916.39
7.4.00.0030.01015.05
7.3.330.0030.00513.27
7.3.320.0030.00313.16
7.3.310.0000.00716.31
7.3.300.0030.00316.31
7.3.290.0090.00816.27
7.3.280.0090.00716.28
7.3.270.0140.00317.40
7.3.260.0030.01416.39
7.3.250.0120.00516.41
7.3.240.0080.01216.42
7.3.230.0090.00916.49
7.3.210.0120.00616.43
7.3.200.0090.01516.40
7.3.190.0120.00816.41
7.3.180.0130.00316.53
7.3.170.0030.01316.48
7.3.160.0060.00916.46
7.2.330.0070.01316.50
7.2.320.0140.00316.82
7.2.310.0130.00316.75
7.2.300.0150.00616.40
7.2.290.0080.00816.51
7.2.60.0060.00617.02
7.2.50.0040.01117.03
7.1.200.0060.00915.72
7.1.70.0090.00617.07
7.1.60.0730.01333.18
7.1.50.0600.02032.84
7.1.40.1030.02332.55
7.1.30.0600.01732.57
7.1.20.0700.01332.59
7.1.10.0630.01014.68
7.1.00.0670.01014.70
7.0.200.0530.00715.14
7.0.190.0530.01014.56
7.0.180.0570.00714.44
7.0.170.0770.01014.34
7.0.160.0600.00714.33
7.0.150.0700.01014.34
7.0.140.0800.01014.54
7.0.130.0600.01014.73
7.0.120.1100.00714.43
7.0.110.0800.01314.39
7.0.100.0570.01014.36
7.0.90.0730.00714.45
7.0.80.0800.01314.57
7.0.70.0900.01314.39
7.0.60.0730.00314.48
7.0.50.1070.01314.56
7.0.40.0630.00314.72
7.0.30.1500.01314.67
7.0.20.0630.01014.78
7.0.10.0570.01314.68
7.0.00.0630.01314.53

preferences:
64.6 ms | 401 KiB | 5 Q