3v4l.org

run code in 300+ PHP versions simultaneously
<?php class AnotherClass{ public $world = "world"; } $anotherClass = new AnotherClass(); class TestClass{ function __construct(){ ob_start(array($this,"callback")); } function callback($input){ global $anotherClass; return $input.$anotherClass->world; } } $tClass = new TestClass(); echo "hello"; ob_flush();

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.0170.00316.63
8.3.50.0090.00616.33
8.3.40.0070.01118.50
8.3.30.0030.01218.84
8.3.20.0040.01518.73
8.3.10.0050.00318.68
8.3.00.0050.00519.38
8.2.180.0220.00025.92
8.2.170.0040.01119.13
8.2.160.0130.00322.96
8.2.150.0050.00324.18
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0040.00420.98
8.2.110.0030.00721.04
8.2.100.0090.00317.91
8.2.90.0030.00517.88
8.2.80.0030.00517.97
8.2.70.0000.00917.50
8.2.60.0070.00017.91
8.2.50.0040.00418.07
8.2.40.0030.00619.50
8.2.30.0000.00817.55
8.2.20.0060.00317.69
8.2.10.0040.00417.73
8.2.00.0150.00017.68
8.1.280.0070.01025.92
8.1.270.0050.00223.99
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0040.00817.23
8.1.230.0040.00719.48
8.1.220.0000.00917.78
8.1.210.0040.00418.77
8.1.200.0070.00317.48
8.1.190.0000.00817.13
8.1.180.0000.00818.10
8.1.170.0000.00718.84
8.1.160.0000.00718.96
8.1.150.0040.00418.55
8.1.140.0040.00417.48
8.1.130.0040.00419.23
8.1.120.0050.00317.46
8.1.110.0040.00417.34
8.1.100.0040.00417.34
8.1.90.0070.00017.39
8.1.80.0050.00317.35
8.1.70.0030.00317.39
8.1.60.0000.00717.55
8.1.50.0000.00817.39
8.1.40.0000.00917.40
8.1.30.0000.00817.62
8.1.20.0080.00017.70
8.1.10.0080.00017.60
8.1.00.0040.00417.58
8.0.300.0000.00820.80
8.0.290.0040.00416.63
8.0.280.0040.00318.57
8.0.270.0030.00317.19
8.0.260.0030.00316.81
8.0.250.0060.00316.97
8.0.240.0000.00816.84
8.0.230.0050.00316.83
8.0.220.0040.00416.90
8.0.210.0000.00716.87
8.0.200.0000.00716.94
8.0.190.0060.00316.96
8.0.180.0050.00316.80
8.0.170.0040.00416.93
8.0.160.0000.00816.85
8.0.150.0030.00616.86
8.0.140.0000.00716.80
8.0.130.0000.00513.34
8.0.120.0050.00516.80
8.0.110.0030.00316.93
8.0.100.0040.00416.79
8.0.90.0070.00016.95
8.0.80.0110.00416.86
8.0.70.0040.00416.93
8.0.60.0090.00016.99
8.0.50.0040.00416.86
8.0.30.0160.00317.11
8.0.20.0110.00817.10
8.0.10.0050.00317.06
8.0.00.0100.00916.94
7.4.330.0000.00512.93
7.4.320.0060.00016.39
7.4.300.0030.00316.49
7.4.290.0070.00316.41
7.4.280.0040.00416.43
7.4.270.0000.00616.40
7.4.260.0030.00313.27
7.4.250.0040.00416.63
7.4.240.0030.00316.51
7.4.230.0080.00016.67
7.4.220.0110.00716.59
7.4.210.0080.00816.66
7.4.200.0000.00816.53
7.4.190.0080.00016.69
7.4.160.0120.00616.41
7.4.150.0140.00616.59
7.4.140.0100.00717.86
7.4.130.0100.01116.34
7.4.120.0130.00716.55
7.4.110.0060.01216.56
7.4.100.0130.00316.73
7.4.90.0090.00916.52
7.4.80.0110.01319.39
7.4.70.0090.01216.48
7.4.60.0090.01016.66
7.4.50.0030.00316.46
7.4.40.0080.00816.17
7.4.30.0140.00416.54
7.4.00.0070.00714.70
7.3.330.0060.00013.08
7.3.320.0000.00513.09
7.3.310.0070.00016.30
7.3.300.0040.00416.25
7.3.290.0130.00416.28
7.3.280.0110.00316.21
7.3.270.0140.00316.36
7.3.260.0090.00916.43
7.3.240.0100.00716.36
7.3.230.0040.01316.38
7.3.210.0030.01616.61
7.3.200.0080.01516.27
7.3.190.0090.00916.64
7.3.180.0070.01016.22
7.3.170.0140.00616.29
7.3.160.0080.00816.52
7.3.120.0090.00614.79
7.3.10.0060.00916.58
7.3.00.0070.00716.69
7.2.330.0250.00016.71
7.2.320.0110.00716.36
7.2.310.0120.00616.86
7.2.300.0070.01016.37
7.2.290.0090.00916.51
7.2.130.0070.00716.81
7.2.120.0050.00816.82
7.2.110.0070.00816.75
7.2.100.0080.00616.79
7.2.90.0080.00816.73
7.2.80.0050.01016.93
7.2.70.0080.00517.02
7.2.60.0090.00617.08
7.2.50.0090.00416.96
7.2.40.0080.00316.93
7.2.30.0030.00617.00
7.2.20.0020.01317.01
7.2.10.0070.00716.85
7.2.00.0030.00917.84
7.1.250.0030.00815.77
7.1.240.0090.00315.67
7.1.230.0100.00715.88
7.1.220.0040.00415.84
7.1.210.0070.00715.80
7.1.200.0130.00515.64
7.1.190.0040.01115.79
7.1.180.0060.00615.95
7.1.170.0030.01315.54
7.1.160.0100.00315.57
7.1.150.0060.00915.88
7.1.140.0070.00715.57
7.1.130.0030.00915.71
7.1.120.0070.00715.81
7.1.110.0000.01115.79
7.1.100.0030.01016.00
7.1.90.0040.00815.76
7.1.80.0030.00615.78
7.1.70.0020.01116.31
7.1.60.0090.00316.29
7.1.50.0060.01216.29
7.1.40.0030.01215.93
7.1.30.0030.01015.70
7.1.20.0130.00015.54
7.1.10.0080.00415.83
7.1.00.0040.03619.14
7.0.320.0070.00715.10
7.0.310.0070.00715.39
7.0.300.0030.00615.38
7.0.290.0060.00315.41
7.0.280.0070.00715.59
7.0.270.0030.01015.45
7.0.260.0060.00615.47
7.0.250.0040.00815.55
7.0.240.0090.00315.59
7.0.230.0030.01015.38
7.0.220.0060.00315.53
7.0.210.0090.00615.26
7.0.200.0050.00715.87
7.0.190.0000.01115.53
7.0.180.0040.00815.39
7.0.170.0070.00715.32
7.0.160.0040.00815.28
7.0.150.0000.01315.47
7.0.140.0030.04118.78
7.0.130.0040.00815.46
7.0.120.0050.01918.80
7.0.110.0060.00315.57
7.0.100.0130.00315.27
7.0.90.0000.00815.17
7.0.80.0050.00515.60
7.0.70.0070.00315.33
7.0.60.0110.04017.68
7.0.50.0030.02416.67
7.0.40.0060.02516.90
7.0.30.0180.04016.77
7.0.20.0140.02816.76
7.0.10.0130.03016.77
7.0.00.0080.04316.74
5.6.380.0080.00314.47
5.6.370.0060.00614.43
5.6.360.0000.01414.27
5.6.350.0090.00614.37
5.6.340.0030.01014.57
5.6.330.0110.00414.27
5.6.320.0030.00714.12
5.6.310.0100.00314.44
5.6.300.0030.01314.20
5.6.290.0000.01314.53
5.6.280.0030.04117.77
5.6.270.0070.00714.42
5.6.260.0080.00314.28
5.6.250.0030.01214.02
5.6.240.0100.00314.59
5.6.230.0070.00714.32
5.6.220.0030.00714.35
5.6.210.0070.04217.51
5.6.200.0100.04016.45
5.6.190.0020.03317.43
5.6.180.0190.03717.66
5.6.170.0120.02817.35
5.6.160.0110.03017.48
5.6.150.0030.02416.20
5.6.140.0080.03516.23
5.6.130.0080.04116.32
5.6.120.0100.03617.68
5.6.110.0070.04717.61
5.6.100.0060.03517.61
5.6.90.0130.03817.76
5.6.80.0040.02417.25
5.6.70.0220.03517.22
5.6.60.0060.00614.27
5.6.50.0000.00814.21
5.6.40.0090.00614.42
5.6.30.0030.01014.33
5.6.20.0060.00914.43
5.6.10.0040.00814.38
5.6.00.0030.01014.40
5.5.380.0090.00311.37
5.5.370.0000.00911.17
5.5.360.0000.00811.12
5.5.350.0130.04615.86
5.5.340.0060.03714.47
5.5.330.0050.02115.65
5.5.320.0000.03115.69
5.5.310.0180.03815.78
5.5.300.0080.03514.54
5.5.290.0020.02714.65
5.5.280.0050.03416.11
5.5.270.0030.03215.94
5.5.260.0050.03816.14
5.5.250.0110.02215.80
5.5.240.0080.04415.71
5.5.230.0030.00911.00
5.5.220.0030.00611.30
5.5.210.0000.01110.78
5.5.200.0040.00710.80
5.5.190.0070.00011.21
5.5.180.0060.00611.09
5.5.170.0000.00914.14
5.5.160.0000.00611.15
5.5.150.0040.00811.00
5.5.140.0090.00311.29
5.5.130.0000.01210.91
5.5.120.0090.00310.77
5.5.110.0000.00811.06
5.5.100.0030.00610.91
5.5.90.0000.01011.00
5.5.80.0080.00311.20
5.5.70.0040.00811.19
5.5.60.0030.00911.00
5.5.50.0050.00311.19
5.5.40.0060.00610.88
5.5.30.0000.01210.98
5.5.20.0060.00011.32
5.5.10.0060.00011.19
5.5.00.0060.00311.01
5.4.450.0950.02015.36
5.4.440.0900.02815.37
5.4.430.1000.01815.23
5.4.420.0950.02615.23
5.4.410.0890.02115.25
5.4.400.0930.02415.10
5.4.390.1070.02715.07
5.4.380.1130.02215.06
5.4.370.0900.02215.15
5.4.360.0570.02215.27
5.4.350.0050.03715.05
5.4.340.0030.02115.03
5.4.330.0130.00011.13
5.4.320.0050.03615.07
5.4.310.1080.02415.13
5.4.300.1080.02214.88
5.4.290.1050.02214.96
5.4.280.1010.02615.06
5.4.270.0910.02315.09
5.4.260.1050.02415.02
5.4.250.1050.02815.07
5.4.240.1020.02715.14
5.4.230.1050.01915.24
5.4.220.0830.02315.10
5.4.210.0890.02115.17
5.4.200.0880.02515.00
5.4.190.1050.02514.97
5.4.180.1060.02514.76
5.4.170.1100.02615.06
5.4.160.0950.02315.11
5.4.150.1000.02014.98
5.4.140.1000.02113.73
5.4.130.1020.02413.90
5.4.120.1160.01513.65
5.4.110.0970.01913.78
5.4.100.1040.02113.87
5.4.90.1030.02213.60
5.4.80.0950.02513.59
5.4.70.1050.02313.64
5.4.60.1030.01813.63
5.4.50.1090.02413.71
5.4.40.0950.02213.80
5.4.30.0900.02213.83
5.4.20.1060.01813.67
5.4.10.1080.02513.66
5.4.00.0950.02113.47
5.3.290.0270.02412.72
5.3.280.0120.03312.56
5.3.270.0080.03812.66
5.3.260.0530.02012.48
5.3.250.1030.02512.50
5.3.240.0920.02112.62
5.3.230.1080.02212.57
5.3.220.1100.01712.44
5.3.210.1020.02312.39
5.3.200.1030.02012.51
5.3.190.1000.01812.41
5.3.180.0920.02412.66
5.3.170.0970.02012.46
5.3.160.0430.02312.55
5.3.150.0020.03112.68
5.3.140.0030.03912.54
5.3.130.0990.02412.63
5.3.120.0970.02212.58
5.3.110.0900.02512.55
5.3.100.0950.02012.28
5.3.90.1000.02412.33
5.3.80.1010.02512.22
5.3.70.0960.01712.25
5.3.60.0930.02212.27
5.3.50.0950.02212.15
5.3.40.0930.02012.30
5.3.30.0620.02012.27
5.3.20.0090.02311.95
5.3.10.0060.02211.96
5.3.00.0850.01911.96
5.2.170.0870.01910.50
5.2.160.0870.01910.50
5.2.150.0940.02210.61
5.2.140.0750.01710.48
5.2.130.0780.02410.48
5.2.120.0880.02010.48
5.2.110.0770.02010.43
5.2.100.0780.01510.46
5.2.90.0720.01910.43
5.2.80.0880.02410.47
5.2.70.0750.01510.51
5.2.60.0840.01710.45
5.2.50.0750.01810.39
5.2.40.0700.02810.38
5.2.30.0680.01210.39
5.2.20.0590.01810.39
5.2.10.0650.01510.33
5.2.00.0570.02010.23
5.1.60.0740.0179.87
5.1.50.0650.0159.86
5.1.40.0580.0179.90
5.1.30.0720.01910.17
5.1.20.0780.01310.08
5.1.10.0750.0159.95
5.1.00.0720.0199.92
5.0.50.0320.0129.26
5.0.40.0280.0159.12
5.0.30.0350.0159.01
5.0.20.0020.0139.05
5.0.10.0050.0089.09
5.0.00.0000.0189.01
4.4.90.0020.0109.01
4.4.80.0000.0119.01
4.4.70.0020.0099.01
4.4.60.0020.0139.01
4.4.50.0030.0119.01
4.4.40.0350.0119.01
4.4.30.0310.0089.01
4.4.20.0280.0109.01
4.4.10.0230.0139.01
4.4.00.0260.0129.01
4.3.110.0250.0109.01
4.3.100.0200.0089.01
4.3.90.0270.0099.01
4.3.80.0330.0179.01
4.3.70.0320.0139.01
4.3.60.0250.0089.01
4.3.50.0330.0079.01
4.3.40.0310.0119.01
4.3.30.0180.0089.01
4.3.20.0130.0119.01
4.3.10.0150.0109.01
4.3.00.0150.0109.01

preferences:
43.32 ms | 401 KiB | 5 Q