3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(E_ALL ^ E_STRICT); trait MyTrait { /** * Comes from trait */ private $foo; } class MyClass { use MyTrait; /** * Comes from class */ private $foo; } $classFoo = new \ReflectionProperty('MyClass', 'foo'); $traitFoo = new \ReflectionProperty('MyTrait', 'foo'); var_export($traitFoo->getDocComment() == $classFoo->getDocComment()); $classFoo = new \ReflectionProperty('MyClass','foo'); $traitFoo = new \ReflectionProperty('MyTrait','foo'); echo $traitFoo->getDeclaringClass()->getName().PHP_EOL; echo $traitFoo->getDocComment().PHP_EOL; echo $classFoo->getDeclaringClass()->getName().PHP_EOL; echo $classFoo->getDocComment().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.60.0070.00716.63
8.3.50.0160.00721.96
8.3.40.0140.00718.67
8.3.30.0030.01019.09
8.3.20.0060.00320.22
8.3.10.0050.00321.77
8.3.00.0050.00320.70
8.2.180.0090.00916.75
8.2.170.0080.00622.96
8.2.160.0100.00319.38
8.2.150.0050.00324.18
8.2.140.0030.00624.66
8.2.130.0040.00426.16
8.2.120.0040.00419.77
8.2.110.0060.00320.36
8.2.100.0040.00717.84
8.2.90.0030.00519.02
8.2.80.0000.00817.97
8.2.70.0050.00317.38
8.2.60.0080.00017.79
8.2.50.0050.00318.07
8.2.40.0040.00419.84
8.2.30.0000.00717.95
8.2.20.0000.00717.68
8.2.10.0000.00718.16
8.2.00.0030.00617.72
8.1.280.0070.00725.92
8.1.270.0040.00420.64
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0040.00423.87
8.1.230.0110.00019.16
8.1.220.0050.00317.74
8.1.210.0080.00018.77
8.1.200.0030.00617.23
8.1.190.0040.00417.23
8.1.180.0060.00318.10
8.1.170.0050.00318.71
8.1.160.0040.00422.05
8.1.150.0080.00018.91
8.1.140.0040.00417.45
8.1.130.0030.00617.82
8.1.120.0040.00317.43
8.1.110.0060.00317.41
8.1.100.0000.00817.40
8.1.90.0030.00617.38
8.1.80.0000.00717.46
8.1.70.0000.00717.46
8.1.60.0000.00817.45
8.1.50.0030.00517.56
8.1.40.0040.00417.48
8.1.30.0030.00617.61
8.1.20.0030.00517.52
8.1.10.0040.00417.46
8.1.00.0040.00417.49
8.0.300.0050.00318.77
8.0.290.0020.00516.63
8.0.280.0000.00718.44
8.0.270.0040.00417.26
8.0.260.0000.00617.30
8.0.250.0000.00717.00
8.0.240.0080.00016.96
8.0.230.0030.00316.95
8.0.220.0070.00016.93
8.0.210.0060.00316.93
8.0.200.0060.00016.88
8.0.190.0000.00816.83
8.0.180.0030.00716.84
8.0.170.0000.00716.87
8.0.160.0030.00316.88
8.0.150.0040.00416.77
8.0.140.0020.00516.86
8.0.130.0000.00613.25
8.0.120.0000.00816.89
8.0.110.0040.00416.79
8.0.100.0070.00016.78
8.0.90.0070.00016.93
8.0.80.0130.00616.84
8.0.70.0030.00416.76
8.0.60.0070.00017.01
8.0.50.0030.00516.88
8.0.30.0160.00917.08
8.0.20.0130.01017.40
8.0.10.0040.00416.89
8.0.00.0080.00916.52
7.4.330.0030.00315.03
7.4.320.0030.00316.59
7.4.300.0060.00016.42
7.4.290.0000.00716.50
7.4.280.0080.00316.52
7.4.270.0030.00316.50
7.4.260.0050.00516.48
7.4.250.0040.00416.55
7.4.240.0050.00216.56
7.4.230.0050.00216.69
7.4.220.0120.00616.47
7.4.210.0060.01316.52
7.4.200.0050.00216.39
7.4.160.0090.01216.48
7.4.150.0060.01917.40
7.4.140.0110.00817.86
7.4.130.0050.01116.49
7.4.120.0080.01316.48
7.4.110.0070.01116.71
7.4.100.0150.00616.59
7.4.90.0080.01116.57
7.4.80.0060.00916.51
7.4.70.0120.00916.55
7.4.60.0000.01516.59
7.4.50.0090.00016.68
7.4.40.0000.01616.49
7.4.30.0140.00716.49
7.4.00.0080.00814.73
7.3.330.0020.00213.21
7.3.320.0030.01013.04
7.3.310.0040.00316.30
7.3.300.0000.00716.25
7.3.290.0050.01016.23
7.3.280.0120.00616.26
7.3.270.0160.00017.40
7.3.260.0180.00016.47
7.3.250.0060.01216.52
7.3.240.0130.00316.57
7.3.230.0160.00616.39
7.3.210.0150.00316.29
7.3.200.0070.01619.39
7.3.190.0060.00916.32
7.3.180.0090.01116.30
7.3.170.0140.00316.27
7.3.160.0080.00916.41
7.3.10.0050.01316.50
7.3.00.0110.00816.41
7.2.330.0110.00516.71
7.2.320.0100.00716.45
7.2.310.0040.01916.64
7.2.300.0100.01316.67
7.2.290.0080.01516.54
7.2.130.0090.00816.77
7.2.120.0110.00816.71
7.2.110.0060.00716.54
7.2.100.0020.01016.58
7.2.90.0080.00616.98
7.2.80.0120.00916.81
7.2.70.0050.01016.40
7.2.60.0040.01316.62
7.2.50.0120.00816.85
7.2.40.0120.00516.92
7.2.30.0060.00916.66
7.2.20.0110.00416.71
7.2.10.0050.01016.83
7.2.00.0050.00617.70
7.1.250.0100.00915.58
7.1.200.0040.01115.70
7.1.100.0030.00617.75
7.1.70.0030.00617.09
7.1.60.0030.02019.46
7.1.50.0090.01216.67
7.1.00.0070.07322.35
7.0.200.0030.00516.61
7.0.140.0070.06022.18
7.0.60.0130.07720.00
7.0.50.0030.05017.89
7.0.40.0100.08320.13
7.0.30.0270.06720.13
7.0.20.0100.04720.20
7.0.10.0070.08320.26
7.0.00.0030.04720.17
5.6.280.0000.07721.13
5.6.210.0100.08320.55
5.6.200.0100.06718.24
5.6.190.0070.05320.48
5.6.180.3970.03320.57
5.6.170.0230.03320.51
5.6.160.0100.08020.44
5.6.150.0070.08018.19
5.6.140.0070.08018.27
5.6.130.0070.03718.15
5.6.120.0070.08321.00
5.6.110.0200.05721.04
5.6.100.0100.08021.05
5.6.90.0030.06721.12
5.6.80.0070.08020.38
5.6.70.3370.04020.43
5.5.350.0130.03720.32
5.5.340.0030.04018.03
5.5.330.0070.08020.47
5.5.320.0300.07320.37
5.5.310.0130.04320.24
5.5.300.0000.05318.08
5.5.290.0070.06717.99
5.5.280.0070.09320.99
5.5.270.0000.04720.78
5.5.260.0170.07320.77
5.5.250.0170.04320.79
5.5.240.0370.06020.27
5.4.450.0130.05019.57
5.4.440.0030.06019.54
5.4.430.0130.03719.30
5.4.420.0200.03019.30
5.4.410.0170.03319.19
5.4.400.0230.05019.02
5.4.390.0170.03719.05
5.4.380.0130.07319.20
5.4.370.0130.06019.19
5.4.360.0230.06018.99
5.4.350.0170.07318.84
5.4.340.0200.03719.02
5.4.320.0100.08319.14
5.4.310.0100.06319.09
5.4.300.0070.04319.00
5.4.290.0170.06719.24
5.4.280.0130.07319.19
5.4.270.0130.07319.12
5.4.260.0130.04318.99
5.4.250.0170.05018.94
5.4.240.0100.03319.17
5.4.230.0100.06719.05
5.4.220.0130.06718.85
5.4.210.0170.05019.20
5.4.200.0230.05319.12
5.4.190.0200.07019.13
5.4.180.0100.08019.18
5.4.170.0130.07018.97
5.4.160.0070.05018.78
5.4.150.0100.03719.19
5.4.140.0070.05716.42
5.4.130.0170.05016.35
5.4.120.0030.06316.31
5.4.110.0100.03716.40
5.4.100.0130.03316.27
5.4.90.0130.03316.19
5.4.80.0100.04016.54
5.4.70.0100.06716.55
5.4.60.0170.04316.52
5.4.50.0070.05316.34
5.4.40.0130.06716.17
5.4.30.0030.07716.37
5.4.20.0030.05716.48
5.4.10.0070.04016.53
5.4.00.0200.04315.78
5.3.290.0100.04314.51
5.3.280.0200.07014.54
5.3.270.0170.05714.43
5.3.260.0170.07314.47
5.3.250.0100.06314.62
5.3.240.0200.06714.45
5.3.230.0130.07014.45
5.3.220.0170.04314.50
5.3.210.0200.07014.41
5.3.200.0130.04714.42
5.3.190.0070.04714.44
5.3.180.0100.04314.55
5.3.170.0200.05714.50
5.3.160.0200.03714.47
5.3.150.0030.04714.40
5.3.140.0100.04714.51
5.3.130.0030.06714.48
5.3.120.0170.05014.53
5.3.110.0100.04014.49
5.3.100.0230.03013.89
5.3.90.0100.06313.96
5.3.80.0170.07314.06
5.3.70.0170.04013.96
5.3.60.0100.06013.88
5.3.50.0130.04313.96
5.3.40.0100.05013.80
5.3.30.0170.06013.75
5.3.20.0170.04013.63
5.3.10.0100.04713.45
5.3.00.0170.03313.48
5.2.170.0030.03313.02
5.2.160.0070.03713.02
5.2.150.0070.03313.02
5.2.140.0130.04013.02
5.2.130.0170.03313.02
5.2.120.0100.04013.02
5.2.110.0100.05713.02
5.2.100.0070.03313.02
5.2.90.0070.03313.02
5.2.80.0030.03313.02
5.2.70.0030.03313.02
5.2.60.0130.02313.02
5.2.50.0030.03313.02
5.2.40.0030.03013.02
5.2.30.0070.06313.02
5.2.20.0100.03313.02
5.2.10.0030.03013.02
5.2.00.0000.06713.02
5.1.60.0030.05713.02
5.1.50.0070.02713.02
5.1.40.0070.02313.02
5.1.30.0100.03313.02
5.1.20.0030.05313.02
5.1.10.0000.03013.02
5.1.00.0100.02013.02
5.0.50.0030.04713.02
5.0.40.0070.03313.02
5.0.30.0000.04013.02
5.0.20.0000.02713.02
5.0.10.0100.03713.02
5.0.00.0030.03713.02
4.4.90.0030.01713.02
4.4.80.0030.03313.02
4.4.70.0070.02713.02
4.4.60.0030.03313.02
4.4.50.0030.02313.02
4.4.40.0030.05013.02
4.4.30.0100.01713.02
4.4.20.0100.01313.02
4.4.10.0030.03313.02
4.4.00.0030.04013.02
4.3.110.0000.03013.02
4.3.100.0070.02713.02
4.3.90.0030.02013.02
4.3.80.0000.03013.02
4.3.70.0030.02313.02
4.3.60.0070.01313.02
4.3.50.0000.01713.02
4.3.40.0070.01713.02
4.3.30.0030.03313.02
4.3.20.0000.02013.02
4.3.10.0000.04013.02
4.3.00.0030.03313.02

preferences:
50.44 ms | 401 KiB | 5 Q