3v4l.org

run code in 300+ PHP versions simultaneously
<?php $s = array(); class MyArrayObject{ public $name, $age; public function __construct( $name, $age ) { $this->name = $name; $this->age = $age; } } for( $x=0;$x<10000;$x++){ $o = new MyArrayObject( "Adam", 35 ); $s[] = $o; }

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.0180.00717.86
8.3.50.0160.00018.17
8.3.40.0070.01019.84
8.3.30.0090.01219.73
8.3.20.0030.00720.34
8.3.10.0040.00423.52
8.3.00.0040.00421.68
8.2.180.0100.01018.38
8.2.170.0170.00322.96
8.2.160.0110.00722.39
8.2.150.0040.00424.18
8.2.140.0100.00624.66
8.2.130.0060.00319.03
8.2.120.0000.00926.35
8.2.110.0070.00722.38
8.2.100.0120.00018.84
8.2.90.0060.00318.85
8.2.80.0000.00918.63
8.2.70.0030.00618.93
8.2.60.0000.01019.16
8.2.50.0030.00618.63
8.2.40.0030.00620.45
8.2.30.0000.00820.38
8.2.20.0080.00419.31
8.2.10.0030.00619.18
8.2.00.0050.00518.71
8.1.280.0070.01525.92
8.1.270.0030.00620.50
8.1.260.0100.00626.35
8.1.250.0030.00628.09
8.1.240.0100.00024.78
8.1.230.0030.01019.15
8.1.220.0060.00319.16
8.1.210.0060.00318.77
8.1.200.0030.00718.86
8.1.190.0000.00918.73
8.1.180.0030.00619.03
8.1.170.0030.00620.00
8.1.160.0000.00820.30
8.1.150.0030.00620.31
8.1.140.0030.00623.60
8.1.130.0030.00521.76
8.1.120.0000.00818.70
8.1.110.0000.00818.82
8.1.100.0000.00918.79
8.1.90.0070.00318.60
8.1.80.0030.00618.75
8.1.70.0000.01018.79
8.1.60.0030.00718.95
8.1.50.0090.00018.87
8.1.40.0030.00618.91
8.1.30.0060.00318.88
8.1.20.0000.01118.98
8.1.10.0030.00718.79
8.1.00.0030.00618.84
8.0.300.0090.00018.77
8.0.290.0030.00617.88
8.0.280.0000.00919.78
8.0.270.0040.00418.57
8.0.260.0000.00819.63
8.0.250.0000.01218.29
8.0.240.0030.00618.04
8.0.230.0080.00018.11
8.0.220.0040.00418.06
8.0.210.0060.00318.15
8.0.200.0030.00518.26
8.0.190.0030.00918.16
8.0.180.0030.00718.11
8.0.170.0030.00618.22
8.0.160.0030.00618.14
8.0.150.0040.00418.02
8.0.140.0030.00618.13
8.0.130.0000.00814.70
8.0.120.0030.00618.09
8.0.110.0000.01117.94
8.0.100.0000.00917.99
8.0.90.0090.00017.98
8.0.80.0080.01718.05
8.0.70.0030.00617.99
8.0.60.0090.00018.16
8.0.50.0000.00918.13
8.0.30.0110.01118.22
8.0.20.0030.00518.37
8.0.10.0040.00418.29
8.0.00.0090.01118.04
7.4.330.0030.00317.17
7.4.320.0030.00617.74
7.4.300.0040.00417.63
7.4.290.0030.00617.82
7.4.280.0000.01017.86
7.4.270.0000.00917.78
7.4.260.0000.00817.79
7.4.250.0060.00617.84
7.4.240.0030.00617.76
7.4.230.0090.00017.89
7.4.220.0030.00717.61
7.4.210.0110.01017.89
7.4.200.0030.00617.88
7.4.160.0120.00717.87
7.4.140.0100.01517.86
7.4.130.0160.01017.64
7.4.120.0110.01117.81
7.4.110.0120.00917.80
7.4.100.0090.01217.82
7.4.90.0150.00617.83
7.4.80.0140.00719.39
7.4.70.0130.00717.67
7.4.60.0160.00317.72
7.4.50.0040.01117.90
7.4.40.0130.00617.68
7.3.330.0030.00314.61
7.3.320.0040.00414.67
7.3.310.0000.01117.66
7.3.300.0090.00017.58
7.3.290.0040.00417.64
7.3.280.0110.00817.55
7.3.260.0120.00917.66
7.3.240.0140.01017.63
7.3.230.0080.01117.64
7.3.210.0100.01017.93
7.3.200.0100.01017.88
7.3.190.0140.01417.96
7.3.180.0100.01017.66
7.3.170.0090.01217.89
7.3.160.0110.00717.94
7.2.330.0150.00618.29
7.2.320.0150.00618.11
7.2.310.0120.00918.23
7.2.300.0060.01517.91
7.2.290.0190.00317.93

preferences:
40.64 ms | 401 KiB | 5 Q