3v4l.org

run code in 300+ PHP versions simultaneously
<?php //file testWorks.php interface IStringable1 { public function toString(); } class MyTestWorks1 implements IStringable1 { public function toString($a = '', $b = NULL) { echo "My Test is instantiated", PHP_EOL; } } $obj = new MyTestWorks1(); $obj->toString(); //file testBroken.php interface IStringable2 { public function toString(); } trait TStringable2 { public function toString($a = '', $b = NULL) { echo "My Test is instantiated", PHP_EOL; } } class MyTestWorks2 implements IStringable2{ use TStringable2; } $obj = new MyTestWorks2(); $obj->toString();

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.70.0040.01118.16
8.3.60.0170.00316.63
8.3.50.0090.00921.07
8.3.40.0160.00318.89
8.3.30.0070.00718.93
8.3.20.0080.00020.22
8.3.10.0030.00623.66
8.3.00.0040.00419.16
8.2.190.0140.00716.75
8.2.180.0110.00718.04
8.2.170.0120.00318.99
8.2.160.0040.01122.96
8.2.150.0000.00824.18
8.2.140.0030.00624.66
8.2.130.0040.00426.16
8.2.120.0000.00821.02
8.2.110.0030.00720.89
8.2.100.0070.00419.64
8.2.90.0060.00320.42
8.2.80.0080.00020.36
8.2.70.0030.00717.34
8.2.60.0030.00617.93
8.2.50.0060.00318.07
8.2.40.0030.00519.72
8.2.30.0000.00718.05
8.2.20.0000.00917.68
8.2.10.0030.00518.02
8.2.00.0070.00018.07
8.1.280.0130.00725.92
8.1.270.0050.00320.38
8.1.260.0060.00326.35
8.1.250.0050.00228.09
8.1.240.0060.00322.18
8.1.230.0100.00020.76
8.1.220.0000.00817.74
8.1.210.0080.00018.84
8.1.200.0000.00817.23
8.1.190.0040.00417.22
8.1.180.0040.00418.10
8.1.170.0030.00618.62
8.1.160.0070.00021.87
8.1.150.0040.00418.75
8.1.140.0040.00417.43
8.1.130.0000.00717.69
8.1.120.0040.00417.44
8.1.110.0070.00017.48
8.1.100.0000.00817.44
8.1.90.0070.00017.42
8.1.80.0000.00717.41
8.1.70.0070.00017.44
8.1.60.0060.00317.47
8.1.50.0000.00917.40
8.1.40.0050.00217.48
8.1.30.0000.00717.66
8.1.20.0040.00417.62
8.1.10.0000.00817.60
8.1.00.0000.00917.51
8.0.300.0070.00019.97
8.0.290.0050.00216.63
8.0.280.0030.00318.42
8.0.270.0070.00017.25
8.0.260.0030.00317.16
8.0.250.0030.00316.82
8.0.240.0050.00216.91
8.0.230.0000.00716.82
8.0.220.0040.00416.89
8.0.210.0060.00316.88
8.0.200.0030.00316.93
8.0.190.0060.00316.93
8.0.180.0000.00716.89
8.0.170.0040.00416.89
8.0.160.0000.00716.89
8.0.150.0000.00716.82
8.0.140.0050.00316.73
8.0.130.0000.00513.29
8.0.120.0040.00416.88
8.0.110.0080.00016.94
8.0.100.0070.00016.77
8.0.90.0000.00816.70
8.0.80.0090.00616.80
8.0.70.0000.00716.71
8.0.60.0050.00316.94
8.0.50.0040.00416.76
8.0.30.0080.01116.84
8.0.20.0140.01217.40
8.0.10.0040.00416.81
8.0.00.0100.01016.57
7.4.330.0020.00215.03
7.4.320.0030.00316.63
7.4.300.0060.00016.50
7.4.290.0000.00716.59
7.4.280.0050.00316.54
7.4.270.0000.00716.52
7.4.260.0070.00016.40
7.4.250.0000.00816.40
7.4.240.0030.00316.61
7.4.230.0040.00416.69
7.4.220.0040.01416.65
7.4.210.0100.00416.56
7.4.200.0070.00016.67
7.4.160.0030.01316.42
7.4.150.0110.00917.40
7.4.140.0170.01817.86
7.4.130.0090.00916.45
7.4.120.0090.00916.48
7.4.110.0100.00716.48
7.4.100.0030.01516.50
7.4.90.0180.00016.41
7.4.80.0060.01319.39
7.4.70.0030.01816.54
7.4.60.0090.00616.54
7.4.50.0040.00016.52
7.4.40.0100.01016.51
7.4.30.0040.01416.63
7.4.00.0090.00614.64
7.3.330.0080.00013.15
7.3.320.0140.00013.16
7.3.310.0030.00316.27
7.3.300.0000.00716.25
7.3.290.0030.00316.28
7.3.280.0100.00916.25
7.3.270.0120.00317.40
7.3.260.0040.01416.38
7.3.250.0120.00816.37
7.3.240.0030.01316.31
7.3.230.0140.00716.39
7.3.210.0130.00316.18
7.3.200.0140.00919.39
7.3.190.0040.01116.35
7.3.180.0130.00616.40
7.3.170.0040.01216.58
7.3.160.0100.00616.25
7.3.10.0100.00316.67
7.3.00.0030.01016.44
7.2.330.0130.00316.81
7.2.320.0030.01616.80
7.2.310.0100.00716.74
7.2.300.0110.00616.69
7.2.290.0140.00516.70
7.2.130.0070.00716.91
7.2.120.0040.00816.69
7.2.110.0150.00016.62
7.2.100.0030.00717.00
7.2.90.0090.00616.90
7.2.80.0030.00717.00
7.2.70.0040.01116.77
7.2.60.0050.01116.86
7.2.50.0060.00916.86
7.2.40.0070.00716.80
7.2.30.0090.00617.07
7.2.20.0030.00916.85
7.2.10.0000.01316.68
7.2.00.0110.00316.89
7.1.250.0080.00315.74
7.1.200.0080.00315.56
7.1.70.0030.00716.96
7.1.60.0030.02019.50
7.1.50.0290.01034.70
7.1.00.0000.07722.36
7.0.200.0080.00016.73
7.0.60.0070.08319.95
7.0.50.0100.07017.82
7.0.40.0030.09020.04
7.0.30.0200.08720.06
7.0.20.0370.06720.33
7.0.10.0070.04020.15
7.0.00.0000.04720.23
5.6.280.0070.07021.10
5.6.210.0170.07320.72
5.6.200.0170.07318.25
5.6.190.0130.07720.49
5.6.180.0500.07020.57
5.6.170.0330.06320.57
5.6.160.0000.04320.52
5.6.150.0070.05718.25
5.6.140.0100.08018.16
5.6.130.0070.04018.17
5.6.120.0100.06721.01
5.6.110.0030.09321.00
5.6.100.0100.08321.09
5.6.90.0130.07021.13
5.6.80.0100.07020.39
5.5.350.0030.08320.42
5.5.340.0030.06018.08
5.5.330.0070.05720.47
5.5.320.0330.04020.30
5.5.310.0230.04720.34
5.5.300.0100.04317.97
5.5.290.0070.08718.05
5.5.280.0030.04320.80
5.5.270.0030.04020.95
5.5.260.0130.06720.77
5.5.250.0070.08020.80
5.5.240.0100.07720.27
5.4.450.0570.05019.47
5.4.440.0530.05319.52
5.4.430.0130.03719.27
5.4.420.0130.05319.38
5.4.410.0600.00018.95
5.4.400.0570.00018.77
5.4.390.0570.00018.70
5.4.380.0600.00018.50
5.4.370.0600.00018.78
5.4.360.0570.00018.81
5.4.350.0600.00018.48
5.4.340.0570.00018.64
5.4.320.0600.00018.75
5.4.310.0600.00018.78
5.4.300.0570.00018.74
5.4.290.0570.00018.57
5.4.280.0600.00018.72
5.4.270.0700.00018.63
5.4.260.0700.00018.72
5.4.250.0630.00018.53
5.4.240.0630.00018.73
5.4.230.0630.00018.63
5.4.220.0630.00018.69
5.4.210.0600.00018.82
5.4.200.0570.00016.55
5.4.190.0570.00018.71
5.4.180.0600.00018.51
5.4.170.0800.00018.46
5.4.160.0670.00018.76
5.4.150.0670.00018.48
5.4.140.0570.00016.22
5.4.130.0530.00016.47
5.4.120.0570.00016.31
5.4.110.0530.00016.21
5.4.100.0570.00016.17
5.4.90.0570.00016.29
5.4.80.0570.00016.36
5.4.70.0630.00016.33
5.4.60.0570.00016.32
5.4.50.0600.00016.30
5.4.40.0570.00016.30
5.4.30.0570.00016.27
5.4.20.0570.00016.16
5.4.10.0530.00016.25
5.4.00.0530.00015.64
5.3.290.0600.00014.81
5.3.280.0670.00014.74
5.3.270.0670.00014.65
5.3.260.0770.00014.67
5.3.250.0600.00014.63
5.3.240.0570.00014.64
5.3.230.0570.00014.73
5.3.220.0570.00014.70
5.3.210.0630.00014.76
5.3.200.0570.00014.60
5.3.190.0570.00014.71
5.3.180.0600.00014.63
5.3.170.0570.00014.55
5.3.160.0570.00014.61
5.3.150.0630.00014.56
5.3.140.0570.00014.58
5.3.130.0600.00014.65
5.3.120.0630.00014.72
5.3.110.0630.00014.55
5.3.100.0570.00014.04
5.3.90.0600.00014.04
5.3.80.0630.00014.05
5.3.70.0600.00014.14
5.3.60.0570.00014.16
5.3.50.0570.00014.02
5.3.40.0600.00014.04
5.3.30.0770.00013.96
5.3.20.0570.00013.75
5.3.10.0570.00013.60
5.3.00.0670.00013.66
5.2.170.0470.00011.20
5.2.160.0470.00011.14
5.2.150.0470.00011.28
5.2.140.0470.00011.25
5.2.130.0470.00011.11
5.2.120.0430.00011.14
5.2.110.0500.00011.31
5.2.100.0430.00011.15
5.2.90.0500.00011.18
5.2.80.0470.00011.20
5.2.70.0470.00011.32
5.2.60.0470.00011.18
5.2.50.0470.00011.06
5.2.40.0430.00011.08
5.2.30.0470.00011.05
5.2.20.0470.00010.96
5.2.10.0470.00010.96
5.2.00.0470.00010.90
5.1.60.0400.00010.20
5.1.50.0400.00010.13
5.1.40.0370.00010.05
5.1.30.0400.00010.56
5.1.20.0430.00010.46
5.1.10.0400.00010.11
5.1.00.0400.00010.26
5.0.50.0300.0008.68
5.0.40.0300.0008.55
5.0.30.0470.0008.28
5.0.20.0300.0008.20
5.0.10.0300.0008.25
5.0.00.0430.0008.21
4.4.90.0230.0005.94
4.4.80.0230.0005.89
4.4.70.0230.0005.93
4.4.60.0230.0005.81
4.4.50.0230.0005.91
4.4.40.0370.0005.90
4.4.30.0230.0005.93
4.4.20.0230.0006.00
4.4.10.0230.0005.95
4.4.00.0370.0005.95
4.3.110.0230.0005.81
4.3.100.0230.0005.80
4.3.90.0200.0005.83
4.3.80.0370.0005.91
4.3.70.0300.0005.91
4.3.60.0230.0005.81
4.3.50.0300.0005.80
4.3.40.0330.0005.73
4.3.30.0230.0004.55
4.3.20.0230.0004.52
4.3.10.0230.0004.48
4.3.00.0270.01716.09

preferences:
21.12 ms | 401 KiB | 5 Q