3v4l.org

run code in 500+ PHP versions simultaneously
<?php class Foo { private readonly array $fruits; public function __construct() { $this->fruits = ['banana', 'pear', 'apple']; \sort($this->fruits); } } new Foo();

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.5.30.0120.01219.60
8.5.20.0100.00717.92
8.5.10.0050.00519.11
8.5.00.0110.01020.25
8.4.180.0140.00725.64
8.4.170.0120.00923.73
8.4.160.0140.01023.83
8.4.150.0080.00416.94
8.4.140.0090.01117.65
8.4.130.0140.00717.98
8.4.120.0050.00320.67
8.4.110.0120.00822.25
8.4.100.0110.00917.90
8.4.90.0130.00718.03
8.4.80.0140.00518.02
8.4.70.0030.00518.08
8.4.60.0060.01019.80
8.4.50.0080.01319.86
8.4.40.0070.00317.80
8.4.30.0040.01122.21
8.4.20.0050.00322.53
8.4.10.0030.00623.79
8.3.300.0110.01022.78
8.3.290.0140.00718.49
8.3.280.0070.00516.20
8.3.270.0120.00916.46
8.3.260.0110.00816.60
8.3.250.0090.00420.86
8.3.240.0110.00716.64
8.3.230.0050.00516.68
8.3.220.0160.00319.10
8.3.210.0090.01016.61
8.3.200.0110.00816.54
8.3.190.0100.00716.66
8.3.180.0060.01316.63
8.3.170.0050.00317.04
8.3.160.0040.00416.75
8.3.150.0060.00319.07
8.3.140.0000.01016.57
8.3.130.0040.00418.56
8.3.120.0090.00019.22
8.3.110.0130.00718.42
8.3.100.0100.00618.50
8.3.50.0100.00718.68
8.2.300.0120.01318.19
8.2.290.0130.00720.55
8.2.280.0120.00616.75
8.2.270.0090.00917.31
8.2.260.0000.00718.84
8.2.250.0080.00016.63
8.2.240.0030.00517.06
8.2.230.0040.00418.28
8.2.220.0030.00618.33
8.2.90.0030.00517.75
8.2.80.0140.00417.13
8.2.70.0110.00817.50
8.2.60.0150.00417.09
8.2.50.0180.00017.36
8.2.40.0160.00017.63
8.2.30.0160.00017.50
8.2.20.0130.00417.25
8.2.10.0000.01617.50
8.2.00.0120.00617.25
8.1.340.0120.00817.77
8.1.330.0130.00716.70
8.1.320.0110.00916.29
8.1.310.0140.00416.47
8.1.300.0120.00616.36
8.1.220.0110.00616.75
8.1.210.0060.01017.00
8.1.200.0070.01017.00
8.1.190.0120.00916.75
8.1.180.0130.00517.00
8.1.170.0120.00616.88
8.1.160.0130.00716.75
8.1.150.0160.00017.22
8.1.140.0150.00017.00
8.1.130.0120.00317.22
8.1.120.0140.00417.13
8.1.110.0150.00217.23
8.1.100.0130.00316.98
8.1.90.0100.00717.25
8.1.80.0130.00417.25
8.1.70.0160.00017.13
8.1.60.0180.00017.00
8.1.50.0100.00716.88
8.1.40.0110.00717.38
8.1.30.0160.00317.13
8.1.20.0120.00817.23
8.1.10.0140.00416.88
8.1.00.0150.00417.25
8.0.290.0040.01216.13
8.0.280.0120.00416.75
8.0.270.0160.00016.38
8.0.260.0110.00416.75
8.0.250.0100.00716.50
8.0.240.0090.00616.38
8.0.230.0130.00416.75
8.0.220.0150.00016.35
8.0.210.0120.00616.37
8.0.200.0050.01116.50
8.0.190.0120.00316.38
8.0.180.0110.00516.38
8.0.170.0200.00016.23
8.0.160.0150.00016.11
8.0.150.0110.00416.38
8.0.140.0110.00516.38
8.0.130.0120.00416.25
8.0.120.0090.00616.12
8.0.110.0070.00716.38
8.0.100.0140.00016.24
8.0.90.0080.00816.50
8.0.80.0100.00516.48
8.0.70.0170.00016.47
8.0.60.0040.01216.25
8.0.50.0150.00016.75
8.0.30.0110.00516.63
8.0.20.0120.00216.50
8.0.10.0110.00516.35

preferences:
49.73 ms | 991 KiB | 5 Q