3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace FOO; class FOO { public const FOO = null; public $X = null; public function BAR(): void {} } echo class_exists('foo\foo') ? 'x':'o'; echo method_exists(FOO::class, 'bar') ? 'x':'o'; echo property_exists(FOO::class, 'x') ? 'x':'o'; echo defined(FOO::class.'::foo')? 'x':'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.0100.01018.43
8.3.50.0150.00618.07
8.3.40.0160.00321.68
8.3.30.0070.01318.38
8.3.20.0060.00324.18
8.3.10.0070.00024.66
8.3.00.0040.00426.16
8.2.180.0110.00725.92
8.2.170.0130.00318.88
8.2.160.0130.00622.96
8.2.150.0050.00325.66
8.2.140.0030.00624.66
8.2.130.0020.00526.16
8.2.120.0080.00026.35
8.2.110.0060.00320.52
8.2.100.0120.00017.59
8.2.90.0060.00320.45
8.2.80.0000.00820.41
8.2.70.0030.00617.93
8.2.60.0070.00417.89
8.2.50.0040.00418.10
8.2.40.0000.00819.39
8.2.30.0040.00419.32
8.2.20.0070.00017.95
8.2.10.0040.00419.21
8.2.00.0040.00419.02
8.1.280.0100.00525.92
8.1.270.0090.00023.99
8.1.260.0000.00828.09
8.1.250.0100.00028.09
8.1.240.0030.00822.13
8.1.230.0040.00822.13
8.1.220.0050.00317.74
8.1.210.0080.00018.77
8.1.200.0050.00517.09
8.1.190.0040.00417.10
8.1.180.0040.00418.10
8.1.170.0080.00018.66
8.1.160.0000.00718.89
8.1.150.0000.00718.76
8.1.140.0000.00718.80
8.1.130.0000.00720.29
8.1.120.0030.00317.38
8.1.110.0040.00417.42
8.1.100.0040.00417.25
8.1.90.0040.00417.38
8.1.80.0000.00817.38
8.1.70.0030.00317.36
8.1.60.0030.00617.38
8.1.50.0000.00717.26
8.1.40.0040.00417.34
8.1.30.0040.00417.44
8.1.20.0000.01117.45
8.1.10.0030.00617.54
8.1.00.0040.00417.41
8.0.300.0000.00720.23
8.0.290.0040.00816.58
8.0.280.0040.00418.40
8.0.270.0000.00716.76
8.0.260.0000.00620.21
8.0.250.0000.00716.91
8.0.240.0000.00616.81
8.0.230.0040.00416.76
8.0.220.0030.00316.69
8.0.210.0000.00616.79
8.0.200.0030.00316.90
8.0.190.0070.00016.85
8.0.180.0000.00816.88
8.0.170.0080.00016.85
8.0.160.0030.00316.83
8.0.150.0000.00716.75
8.0.140.0040.00416.76
8.0.130.0030.00313.20
8.0.120.0030.00516.69
8.0.110.0000.00716.75
8.0.100.0000.00816.66
8.0.90.0040.00416.76
8.0.80.0070.00816.77
8.0.70.0000.00716.83
8.0.60.0040.00416.80
8.0.50.0000.00816.75
8.0.30.0070.01317.16
8.0.20.0190.01117.03
8.0.10.0070.00016.82
8.0.00.0080.01716.61
7.4.330.0040.00015.55
7.4.320.0000.00616.42
7.4.300.0000.00716.50
7.4.290.0000.00716.39
7.4.280.0000.00716.34
7.4.270.0000.00716.41
7.4.260.0030.00313.17
7.4.250.0050.00316.37
7.4.240.0030.00516.49
7.4.230.0000.00716.61
7.4.220.0070.00016.49
7.4.210.0070.00716.48
7.4.200.0000.00916.38
7.4.130.0100.01316.41
7.4.120.0030.01316.39
7.4.110.0100.00716.39
7.4.100.0130.00516.21
7.4.90.0240.00016.29
7.4.80.0170.01416.40
7.4.70.0230.01016.34
7.4.60.0300.00016.51
7.4.50.0160.01616.28
7.4.40.0270.01216.27
7.4.30.0280.01116.32
7.4.20.0160.02016.44
7.4.10.0210.01216.50
7.4.00.0170.00416.38
7.3.330.0000.00716.09
7.3.320.0050.00013.02
7.3.310.0070.00016.09
7.3.300.0030.00316.05
7.3.290.0090.00716.19
7.3.260.0090.01616.48
7.3.240.0120.00316.42
7.3.230.0140.00716.55
7.3.220.0120.00816.26
7.3.210.0220.01016.40
7.3.200.0160.01616.30
7.3.190.0280.00916.33
7.3.180.0160.01616.30
7.3.170.0270.01016.11
7.3.160.0260.01716.54
7.3.150.0320.00516.41
7.3.140.0290.01116.14
7.3.130.0270.01216.32
7.3.120.0310.00416.41
7.3.110.0230.01116.27
7.3.100.0090.01516.24
7.3.90.0090.01416.39
7.3.80.0090.01216.41
7.3.70.0090.01016.12
7.3.60.0070.01116.14
7.3.50.0090.01216.23
7.3.40.0140.00416.30
7.3.30.0070.01116.33
7.3.20.0490.00916.28
7.3.10.0310.00616.31
7.3.00.0320.00316.42
7.2.340.0110.00716.27
7.2.330.0200.01216.58
7.2.320.0240.01116.54
7.2.310.0330.00316.57
7.2.300.0260.00816.57
7.2.290.0240.01616.21
7.2.280.0280.01316.57
7.2.270.0210.01516.52
7.2.260.0290.01016.58
7.2.250.0230.01116.61
7.2.240.0290.00416.34
7.2.230.0040.02116.49
7.2.220.0160.00816.20
7.2.210.0130.00616.47
7.2.200.0090.01316.53
7.2.190.0090.01716.46
7.2.180.0050.01416.36
7.2.170.0130.00616.45
7.2.160.0100.01616.60
7.2.150.0280.01116.55
7.2.140.1230.01016.41
7.2.130.0250.01316.42
7.2.120.0300.00416.45
7.2.110.0260.00716.56
7.2.100.0280.00716.38
7.2.90.0160.00416.30
7.2.80.0110.01116.45
7.2.70.0120.00616.45
7.2.60.0080.01116.48
7.2.50.0150.00416.46
7.2.40.0100.00716.57
7.2.30.0110.00716.48
7.2.20.0070.01316.35
7.2.10.0180.00316.61
7.2.00.0160.01016.56

preferences:
58.83 ms | 400 KiB | 5 Q