3v4l.org

run code in 300+ PHP versions simultaneously
<?php $file = <<<'FILE' class TestTextBefore {} <?php /* class TestComment {} */ class Test {} <<<STRING class TestString {} STRING; class test2 { public function test1() {} public function test2() {} public function test3() {} } class NotATest {} class // valid tokens between the 'class' keyword and the test name /* should be handled correctly */ Test3 {} ?> class TestTestAfter {} FILE; echo $file;

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.0110.00418.05
8.3.50.0080.01021.20
8.3.40.0110.00418.54
8.3.30.0110.00418.50
8.3.20.0070.00020.21
8.3.10.0050.00323.46
8.3.00.0040.00420.80
8.2.180.0090.00618.41
8.2.170.0140.00022.96
8.2.160.0110.00420.35
8.2.150.0040.00424.18
8.2.140.0050.00324.66
8.2.130.0000.00819.27
8.2.120.0050.00326.35
8.2.110.0040.00422.11
8.2.100.0080.00418.16
8.2.90.0040.00419.08
8.2.80.0040.00418.04
8.2.70.0060.00317.37
8.2.60.0040.00418.03
8.2.50.0000.00818.07
8.2.40.0060.00321.91
8.2.30.0000.00720.72
8.2.20.0030.00517.73
8.2.10.0040.00417.93
8.2.00.0050.00217.93
8.1.280.0120.00425.92
8.1.270.0080.00020.38
8.1.260.0080.00028.09
8.1.250.0000.00728.09
8.1.240.0100.00022.04
8.1.230.0050.00519.16
8.1.220.0040.00417.74
8.1.210.0000.00818.77
8.1.200.0060.00317.00
8.1.190.0090.00317.11
8.1.180.0040.00418.10
8.1.170.0030.00618.57
8.1.160.0040.00420.56
8.1.150.0040.00418.69
8.1.140.0050.00319.51
8.1.130.0040.00417.63
8.1.120.0000.00717.32
8.1.110.0000.00717.37
8.1.100.0040.00417.31
8.1.90.0000.00817.38
8.1.80.0080.00017.28
8.1.70.0000.00717.24
8.1.60.0000.00817.47
8.1.50.0030.00517.36
8.1.40.0060.00317.43
8.1.30.0040.00417.48
8.1.20.0000.00817.57
8.1.10.0060.00317.51
8.1.00.0080.00017.43
8.0.300.0000.00718.77
8.0.290.0040.00416.63
8.0.280.0050.00218.46
8.0.270.0000.00717.29
8.0.260.0080.00017.18
8.0.250.0000.00717.00
8.0.240.0030.00617.00
8.0.230.0000.00717.00
8.0.220.0000.00716.86
8.0.210.0000.00716.90
8.0.200.0030.00316.98
8.0.190.0060.00316.98
8.0.180.0040.00416.79
8.0.170.0000.00816.90
8.0.160.0000.00716.82
8.0.150.0070.00016.84
8.0.140.0070.00016.75
8.0.130.0060.00013.37
8.0.120.0000.00916.89
8.0.110.0030.00616.91
8.0.100.0000.00816.76
8.0.90.0030.00516.69
8.0.80.0090.00616.76
8.0.70.0000.00816.75
8.0.60.0040.00416.99
8.0.50.0000.00816.77
8.0.30.0110.00817.13
8.0.20.0100.01117.40
8.0.10.0000.00716.89
8.0.00.0110.01116.72
7.4.330.0050.00016.79
7.4.320.0030.00316.41
7.4.300.0030.00316.38
7.4.290.0040.00416.52
7.4.280.0060.00316.53
7.4.270.0000.00716.54
7.4.260.0030.00316.46
7.4.250.0030.00616.50
7.4.240.0020.00516.49
7.4.230.0030.00316.53
7.4.220.0070.00816.38
7.4.210.0070.01016.50
7.4.200.0030.00316.55
7.4.160.0050.01116.46
7.4.150.0140.00317.40
7.4.140.0080.01217.86
7.4.130.0130.00416.43
7.4.120.0120.01016.33
7.4.110.0140.00316.64
7.4.100.0140.00916.33
7.4.90.0160.00716.46
7.4.80.0060.01119.39
7.4.70.0090.00616.63
7.4.60.0060.01016.39
7.4.50.0070.00716.42
7.4.40.0120.00916.58
7.4.30.0130.01016.56
7.4.00.0060.01014.96
7.3.330.0000.00613.07
7.3.320.0000.00513.10
7.3.310.0000.00716.30
7.3.300.0060.00016.25
7.3.290.0050.00916.28
7.3.280.0100.00416.31
7.3.270.0030.02117.40
7.3.260.0100.01316.30
7.3.250.0080.00916.39
7.3.240.0110.00916.29
7.3.230.0090.00916.39
7.3.210.0100.00716.21
7.3.200.0060.01316.29
7.3.190.0090.00816.30
7.3.180.0060.00916.40
7.3.170.0130.00316.32
7.3.160.0110.00516.13
7.3.10.0060.00916.63
7.3.00.0040.00716.51
7.2.330.0090.00916.66
7.2.320.0030.01316.59
7.2.310.0060.01216.51
7.2.300.0040.01916.26
7.2.290.0070.01616.54
7.2.130.0000.01016.91
7.2.120.0110.00316.84
7.2.110.0040.01116.73
7.2.100.0070.01016.39
7.2.90.0040.00816.54
7.2.80.0040.00716.66
7.2.70.0000.01216.68
7.2.60.0080.00316.77
7.2.50.0040.00816.67
7.2.40.0030.00916.95
7.2.30.0030.00916.76
7.2.20.0070.00716.42
7.2.10.0060.00316.61
7.2.00.0040.00717.89
7.1.250.0070.00715.86
7.1.200.0090.00315.80
7.1.100.0000.01118.05
7.1.70.0000.00717.03
7.1.60.0140.01019.52
7.1.50.0030.02216.98
7.1.00.0100.07022.30
7.0.200.0040.00416.75
7.0.60.0100.06319.93
7.0.50.0070.04317.88
7.0.40.0070.03720.31
7.0.30.0130.04320.12
7.0.20.0300.08019.99
7.0.10.0070.04720.30
7.0.00.0030.08720.19
5.6.280.0000.06721.06
5.6.210.0070.08020.64
5.6.200.0130.07318.22
5.6.190.0070.07720.41
5.6.180.0300.07720.57
5.6.170.0230.04320.38
5.6.160.0070.04320.49
5.6.150.0030.06718.14
5.6.140.0070.07018.15
5.6.130.0130.06318.11
5.6.120.0130.03320.98
5.6.110.0000.04320.97
5.6.100.0100.08021.03
5.6.90.0030.06020.94
5.6.80.0130.08020.37
5.5.350.4130.04720.43
5.5.340.0030.08017.95
5.5.330.0070.05020.37
5.5.320.0230.03720.51
5.5.310.0300.08320.50
5.5.300.0030.03717.91
5.5.290.0100.07317.95
5.5.280.0070.04020.87
5.5.270.0100.07720.95
5.5.260.0100.04320.86
5.5.250.0070.04320.61
5.5.240.0030.09020.04

preferences:
44.55 ms | 401 KiB | 5 Q