3v4l.org

run code in 300+ PHP versions simultaneously
<?php #[Attribute(Attribute::TARGET_CLASS | Attribute::IS_REPEATABLE)] class FooAttribute { function __construct(public string $value) {} } #[FooAttribute('a')] #[FooAttribute('b')] class Foo {} var_dump( array_map( fn ($ar) => $ar->newInstance(), (new ReflectionClass(Foo::class))->getAttributes(FooAttribute::class) ) );

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.0140.00716.50
8.3.50.0090.00620.32
8.3.40.0070.01318.71
8.3.30.0100.01018.81
8.3.20.0050.00324.18
8.3.10.0040.00424.66
8.3.00.0070.00026.16
8.2.180.0120.00425.92
8.2.170.0070.00718.97
8.2.160.0030.01022.96
8.2.150.0040.00425.66
8.2.140.0070.00024.66
8.2.130.0000.00826.16
8.2.120.0030.00619.00
8.2.110.0050.00520.93
8.2.100.0090.00317.91
8.2.90.0040.00417.91
8.2.80.0000.00717.97
8.2.70.0030.00517.63
8.2.60.0050.00317.38
8.2.50.0000.00817.98
8.2.40.0000.00918.09
8.2.30.0000.00718.04
8.2.20.0070.00020.41
8.2.10.0050.00317.68
8.2.00.0040.00419.20
8.1.280.0090.00625.92
8.1.270.0040.00423.99
8.1.260.0060.00326.35
8.1.250.0040.00428.09
8.1.240.0060.00620.72
8.1.230.0110.00020.98
8.1.220.0080.00017.74
8.1.210.0050.00318.86
8.1.200.0030.00617.36
8.1.190.0040.00417.53
8.1.180.0000.00818.10
8.1.170.0000.00817.62
8.1.160.0050.00218.74
8.1.150.0000.00718.50
8.1.140.0030.00517.45
8.1.130.0000.00718.77
8.1.120.0000.00717.29
8.1.110.0070.00017.41
8.1.100.0000.01117.53
8.1.90.0050.00317.39
8.1.80.0040.00417.44
8.1.70.0070.00017.45
8.1.60.0040.00417.48
8.1.50.0000.00817.43
8.1.40.0040.00417.59
8.1.30.0030.00617.68
8.1.20.0190.00517.53
8.1.10.0090.01517.38
8.1.00.0200.00417.35
8.0.300.0040.00419.87
8.0.290.0040.00416.61
8.0.280.0030.00318.33
8.0.270.0030.00316.74
8.0.260.0040.00418.32
8.0.250.0050.00216.90
8.0.240.0000.00716.79
8.0.230.0050.00316.77
8.0.220.0000.00716.74
8.0.210.0040.00416.89
8.0.200.0050.00316.98
8.0.190.0030.00516.99
8.0.180.0020.00516.91
8.0.170.0050.00316.80
8.0.160.0050.00316.91
8.0.150.0100.01016.78
8.0.140.0120.00816.76
8.0.130.0150.00516.66
8.0.120.0140.00516.88
8.0.110.0160.00316.81
8.0.100.0190.00016.79
8.0.90.0110.00916.77
8.0.80.0110.01116.73
8.0.70.0160.00516.77
8.0.60.0200.00316.70
8.0.50.0150.00416.79
8.0.30.0120.00816.82
8.0.20.0180.00316.89
8.0.10.0200.00016.86
7.4.330.0030.00315.55
7.4.320.0040.00416.28
7.4.300.0030.00316.34
7.4.290.0070.00016.28
7.4.280.0050.00316.39
7.4.270.0150.00716.45
7.4.260.0140.00816.20
7.4.250.0160.00316.27
7.4.240.0170.00016.32
7.4.230.0060.00916.30
7.4.220.0200.00016.21
7.4.210.0150.00316.46
7.4.200.0090.00616.35
7.4.190.0150.00416.37
7.4.180.0170.00516.34
7.4.160.0080.01216.27
7.4.150.0160.00316.23
7.4.140.0200.00016.26
7.4.130.0140.00616.10
7.4.120.0110.00816.29
7.4.110.0160.00616.21
7.4.100.0090.00416.20
7.4.90.0100.00516.25
7.4.80.0090.00416.19
7.4.70.0060.00916.10
7.4.60.0160.00016.22
7.4.50.0090.00515.95
7.4.40.0070.00716.13
7.4.30.0100.00316.20
7.4.20.0110.00016.19
7.4.10.0130.00016.05
7.4.00.0070.00316.07

preferences:
64.84 ms | 400 KiB | 5 Q