3v4l.org

run code in 300+ PHP versions simultaneously
<?php #[Attribute] class SomeAttr {} #[SomeAttr] class SomeClass { /** * Some comment */ #[SomeAttr] public function someMethod(string $someParam): void { } } $reflection = new ReflectionClass(SomeClass::class); echo (string) $reflection; echo (string) $reflection->getMethod('someMethod'); echo $reflection->getMethod('someMethod')->getAttributes()[0];

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.120.0110.00920.81
8.4.110.0100.00722.34
8.4.100.0050.00517.91
8.4.90.0110.01018.89
8.4.80.0130.00717.83
8.4.70.0040.00419.45
8.4.60.0110.00919.13
8.4.50.0060.00318.67
8.4.40.0130.00618.01
8.4.30.0150.00320.64
8.4.20.0170.00317.76
8.4.10.0030.00625.79
8.3.250.0110.00718.75
8.3.240.0110.00916.76
8.3.230.0130.00616.63
8.3.220.0100.00716.97
8.3.210.0050.00316.44
8.3.200.0060.00316.79
8.3.190.0100.00918.85
8.3.180.0120.00616.26
8.3.170.0000.00717.27
8.3.160.0030.01420.04
8.3.150.0120.00618.95
8.3.140.0110.00418.77
8.3.130.0040.00418.42
8.3.120.0110.00018.68
8.3.110.0040.00420.94
8.3.100.0050.00324.06
8.3.90.0040.00726.77
8.3.80.0090.00019.36
8.3.70.0210.00016.58
8.3.60.0160.00616.75
8.3.50.0100.00723.58
8.3.40.0070.00718.84
8.3.30.0110.00418.54
8.3.20.0070.00024.18
8.3.10.0050.00224.66
8.3.00.0000.00826.16
8.2.290.0080.00220.70
8.2.280.0100.01118.61
8.2.270.0110.00417.55
8.2.260.0080.00017.46
8.2.250.0100.01016.38
8.2.240.0000.00817.15
8.2.230.0030.00622.58
8.2.220.0110.00437.54
8.2.210.0040.00426.77
8.2.200.0030.00718.88
8.2.190.0070.00716.61
8.2.180.0140.00325.92
8.2.170.0040.01119.06
8.2.160.0110.01122.96
8.2.150.0040.00425.66
8.2.140.0090.00024.66
8.2.130.0070.00026.16
8.2.120.0100.00021.07
8.2.110.0050.00522.29
8.2.100.0090.00317.63
8.2.90.0060.00319.16
8.2.80.0030.00617.97
8.2.70.0060.00317.38
8.2.60.0030.00617.93
8.2.50.0040.00418.05
8.2.40.0080.00018.25
8.2.30.0040.00418.10
8.2.20.0040.00418.14
8.2.10.0040.00419.26
8.2.00.0000.00719.26
8.1.330.0110.00821.95
8.1.320.0090.01015.97
8.1.310.0040.01416.34
8.1.300.0000.00819.45
8.1.290.0040.00430.84
8.1.280.0060.00925.92
8.1.270.0050.00323.99
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0130.00320.91
8.1.230.0040.00817.42
8.1.220.0040.00417.78
8.1.210.0030.00518.77
8.1.200.0060.00317.22
8.1.190.0080.00017.25
8.1.180.0040.00418.10
8.1.170.0060.00320.57
8.1.160.0060.00318.85
8.1.150.0040.00418.71
8.1.140.0040.00418.83
8.1.130.0070.00020.05
8.1.120.0000.00817.43
8.1.110.0040.00417.38
8.1.100.0080.00017.30
8.1.90.0050.00317.35
8.1.80.0040.00417.37
8.1.70.0070.00317.42
8.1.60.0030.00617.56
8.1.50.0030.00617.55
8.1.40.0030.00517.47
8.1.30.0030.00617.61
8.1.20.0030.00517.50
8.1.10.0040.00417.41
8.1.00.0070.00317.48
8.0.300.0040.00418.77
8.0.290.0040.00416.75
8.0.280.0030.00318.47
8.0.270.0030.00318.09
8.0.260.0040.00418.39
8.0.250.0040.00417.05
8.0.240.0040.00417.06
8.0.230.0040.00416.79
8.0.220.0070.00016.80
8.0.210.0000.00716.82
8.0.200.0030.00317.02
8.0.190.0040.00417.01
8.0.180.0030.00616.91
8.0.170.0000.00816.98
8.0.160.0030.00316.91
8.0.150.0070.00016.87
8.0.140.0000.00816.84
8.0.130.0000.00613.29
8.0.120.0050.00316.90
8.0.110.0020.00516.84
8.0.100.0040.00416.84
8.0.90.0000.00716.89
8.0.80.0080.00816.89
8.0.70.0040.00416.77
8.0.60.0030.00616.93
8.0.50.0040.00417.02
8.0.30.0060.01416.81
8.0.20.0090.00917.08
8.0.10.0090.00917.15
8.0.00.0100.00717.03
7.4.330.0050.00015.55
7.4.320.0020.00516.59
7.4.300.0000.00816.63
7.4.290.0050.00216.38
7.4.280.0040.00416.44
7.4.270.0000.00716.42
7.4.260.0000.00513.30
7.4.250.0040.00416.43
7.4.240.0050.00316.61
7.4.230.0000.00716.50
7.4.220.0020.00616.55
7.4.210.0070.00616.58
7.4.200.0070.00016.68
7.4.140.0100.01016.63
7.4.130.0100.00616.47
7.4.120.0140.00316.44
7.4.110.0150.00416.67
7.4.100.0080.00816.38
7.4.90.0070.01016.42
7.4.80.0120.00916.43
7.4.70.0160.00316.22
7.4.60.0150.00316.58
7.4.50.0140.00316.57
7.4.40.0170.00016.51
7.4.30.0060.01216.27
7.4.20.0170.00316.61
7.4.10.0030.01316.54
7.4.00.0070.01116.64
7.3.330.0000.00716.38
7.3.320.0050.00013.34
7.3.310.0030.00316.38
7.3.300.0000.00716.38
7.3.290.0160.00616.41
7.3.260.0110.00716.48
7.3.250.0100.00716.54
7.3.240.0130.00316.42
7.3.230.0120.00616.44
7.3.220.0140.00316.58
7.3.210.0110.00516.38
7.3.200.0070.01016.53
7.3.190.0070.01316.41
7.3.180.0100.00716.40
7.3.170.0130.00416.47
7.3.160.0060.01516.46
7.3.150.0120.00616.46
7.3.140.0150.00316.47
7.3.130.0070.01316.49
7.3.120.0030.01316.45
7.3.110.0100.00716.23
7.3.100.0110.01216.38
7.3.90.0070.01316.40
7.3.80.0100.01016.47
7.3.70.0100.00716.44
7.3.60.0100.00716.48
7.3.50.0060.01016.41
7.3.40.0090.00916.51
7.3.30.0100.00716.39
7.3.20.0110.01116.48
7.3.10.0210.00416.24
7.3.00.0120.00616.36

preferences:
26.85 ms | 403 KiB | 5 Q