3v4l.org

run code in 300+ PHP versions simultaneously
<?php class foo { public function __construct() { $this->something(); } public function something() { echo __CLASS__; // foo var_dump($this); } } class foo_bar extends foo { public function __construct() { parent::something(); $this->something(); } public function something() { echo __CLASS__; // foo_bar var_dump($this); } } class foo_bar_baz extends foo_bar { public function __construct() { parent::something(); $this->something(); } public function something() { echo __CLASS__; // foo_bar_baz var_dump($this); } public function call() { echo self::something(); // self echo parent::something(); // parent echo foo::something(); // grandparent } } $obj = new foo_bar_baz();

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.40.0150.00018.77
8.3.30.0100.00718.66
8.3.20.0060.00318.60
8.3.10.0040.00419.25
8.3.00.0050.00321.85
8.2.170.0150.00322.96
8.2.160.0100.00320.45
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0110.00421.12
8.2.110.0000.01120.53
8.2.100.0070.00417.72
8.2.90.0000.00919.22
8.2.80.0000.00717.97
8.2.70.0040.00417.63
8.2.60.0030.00617.80
8.2.50.0030.00618.07
8.2.40.0000.00818.09
8.2.30.0040.00421.13
8.2.20.0000.00717.65
8.2.10.0040.00417.48
8.2.00.0040.00417.53
8.1.270.0050.00223.99
8.1.260.0080.00026.35
8.1.250.0070.00028.09
8.1.240.0110.00022.42
8.1.230.0060.00620.85
8.1.220.0050.00318.77
8.1.210.0080.00018.96
8.1.200.0070.00317.23
8.1.190.0050.00217.40
8.1.180.0060.00318.10
8.1.170.0000.00818.67
8.1.160.0000.00718.82
8.1.150.0040.00418.63
8.1.140.0040.00417.31
8.1.130.0030.00317.84
8.1.120.0040.00717.40
8.1.110.0030.00617.39
8.1.100.0040.00417.41
8.1.90.0000.00817.46
8.1.80.0000.00717.39
8.1.70.0000.00717.31
8.1.60.0000.00817.49
8.1.50.0080.00017.46
8.1.40.0040.00417.50
8.1.30.0030.00617.70
8.1.20.0080.00017.61
8.1.10.0030.00617.54
8.1.00.0040.00417.36
8.0.300.0000.00720.02
8.0.290.0040.00417.18
8.0.280.0030.00518.35
8.0.270.0040.00417.13
8.0.260.0000.00616.82
8.0.250.0030.00516.82
8.0.240.0090.00316.86
8.0.230.0070.00016.91
8.0.220.0000.00716.90
8.0.210.0030.00316.74
8.0.200.0000.00616.92
8.0.190.0030.00316.89
8.0.180.0000.00716.80
8.0.170.0080.00016.87
8.0.160.0000.00716.71
8.0.150.0000.00816.83
8.0.140.0060.00316.84
8.0.130.0030.00313.25
8.0.120.0000.00716.73
8.0.110.0000.00716.65
8.0.100.0000.00816.77
8.0.90.0000.00816.64
8.0.80.0040.01116.82
8.0.70.0000.00816.65
8.0.60.0000.00816.74
8.0.50.0040.00416.94
8.0.30.0060.01317.07
8.0.20.0140.00717.40
8.0.10.0040.00416.97
8.0.00.0100.00916.51
7.4.330.0000.00514.78
7.4.320.0000.00916.43
7.4.300.0040.00416.49
7.4.290.0040.00416.41
7.4.280.0040.00416.64
7.4.270.0030.00316.63
7.4.260.0050.00013.29
7.4.250.0030.00516.61
7.4.240.0000.00716.46
7.4.230.0030.00316.39
7.4.220.0120.01216.63
7.4.210.0060.00816.57
7.4.200.0070.00016.53
7.4.190.0000.00716.46
7.4.160.0110.00616.41
7.4.150.0140.00417.40
7.4.140.0140.00817.86
7.4.130.0070.01016.52
7.4.120.0080.01216.53
7.4.110.0060.01116.43
7.4.100.0100.00616.40
7.4.90.0100.00716.39
7.4.80.0110.01119.39
7.4.70.0060.01216.34
7.4.60.0110.00516.48
7.4.50.0090.00016.32
7.4.40.0100.00622.52
7.4.30.0120.00616.45
7.4.10.0100.01015.04
7.4.00.0030.01414.73
7.3.330.0050.00013.11
7.3.320.0050.00013.22
7.3.310.0000.00716.22
7.3.300.0030.00316.20
7.3.290.0000.01416.26
7.3.280.0100.00916.16
7.3.270.0070.01017.40
7.3.260.0130.01218.24
7.3.250.0130.00316.46
7.3.240.0030.01316.36
7.3.230.0030.01316.39
7.3.210.0080.01216.30
7.3.200.0120.01319.39
7.3.190.0140.00916.16
7.3.180.0050.01016.20
7.3.170.0070.00716.34
7.3.160.0110.01116.37
7.3.130.0090.00614.48
7.3.120.0090.00714.64
7.3.110.0040.01414.85
7.3.100.0000.00914.68
7.3.90.0070.00714.94
7.3.80.0030.01314.71
7.3.70.0050.00514.84
7.3.60.0000.01414.80
7.3.50.0090.00614.41
7.3.40.0000.01314.66
7.3.30.0080.00614.64
7.3.20.0030.01016.44
7.3.10.0080.00716.38
7.3.00.0100.00216.60
7.2.330.0130.00616.71
7.2.320.0070.01416.41
7.2.310.0060.01116.35
7.2.300.0030.01316.80
7.2.290.0040.01416.68
7.2.260.0060.01014.93
7.2.250.0060.01215.02
7.2.240.0060.01215.19
7.2.230.0040.01114.84
7.2.220.0000.01415.00
7.2.210.0000.01315.04
7.2.200.0000.01514.82
7.2.190.0030.01015.07
7.2.180.0080.00314.75
7.2.170.0000.01315.04
7.2.160.0060.01014.99
7.2.150.0060.00616.63
7.2.140.0030.00916.60
7.2.130.0060.00916.87
7.2.120.0050.00816.86
7.2.110.0090.00616.88
7.2.100.0070.00616.92
7.2.90.0020.01316.79
7.2.80.0070.01016.79
7.2.70.0060.00616.80
7.2.60.0060.00816.96
7.2.50.0070.00616.86
7.2.40.0060.00816.87
7.2.30.0080.00817.00
7.2.20.0050.01216.85
7.2.10.0080.00716.78
7.2.00.0060.00817.45
7.1.330.0030.01015.62
7.1.320.0000.01315.82
7.1.310.0030.01015.65
7.1.300.0040.01115.84
7.1.290.0030.00715.83
7.1.280.0090.00615.63
7.1.270.0040.00815.38
7.1.260.0080.00415.91
7.1.250.0060.00815.64
7.1.240.0090.00615.85
7.1.230.0060.00915.73
7.1.220.0040.00415.79
7.1.210.0030.00715.84
7.1.200.0030.01015.80
7.1.190.0030.00715.79
7.1.180.0040.00815.89
7.1.170.0000.01515.38
7.1.160.0090.00615.72
7.1.150.0070.00315.83
7.1.140.0060.00615.85
7.1.130.0090.00615.76
7.1.120.0080.00315.80
7.1.110.0030.00915.70
7.1.100.0020.01016.86
7.1.90.0000.01815.80
7.1.80.0040.00415.76
7.1.70.0030.00716.39
7.1.60.0060.01117.47
7.1.50.0110.00916.34
7.1.40.0000.00915.76
7.1.30.0030.00715.67
7.1.20.0080.00615.50
7.1.10.0040.00715.55
7.1.00.0020.02619.02
7.0.330.0040.01115.39
7.0.320.0070.00715.31
7.0.310.0080.00415.39
7.0.300.0000.01015.18
7.0.290.0070.00715.52
7.0.280.0090.00615.22
7.0.270.0070.00315.46
7.0.260.0100.00315.20
7.0.250.0030.01415.17
7.0.240.0050.00315.27
7.0.230.0090.00415.42
7.0.220.0030.01015.33
7.0.210.0070.00315.49
7.0.200.0060.00516.15
7.0.190.0040.00815.39
7.0.180.0070.00715.44
7.0.170.0070.00715.33
7.0.160.0030.00515.38
7.0.150.0030.00815.13
7.0.140.0050.03818.76
7.0.130.0030.00815.20
7.0.120.0030.00615.58
7.0.110.0040.01115.54
7.0.100.0000.01515.22
7.0.90.0090.00615.29
7.0.80.0100.00315.43
7.0.70.0040.04218.46
7.0.60.0030.04718.63
7.0.50.0020.04818.81
7.0.40.0020.03516.73
7.0.30.0040.04516.68
7.0.20.0080.03216.76
7.0.10.0030.04416.76
7.0.00.0070.04416.73
5.6.400.0060.00614.49
5.6.390.0070.00314.16
5.6.380.0080.00513.99
5.6.370.0040.01114.24
5.6.360.0070.01014.12
5.6.350.0030.01414.10
5.6.340.0060.00914.57
5.6.330.0040.00714.44
5.6.320.0040.00414.30
5.6.310.0030.01014.45
5.6.300.0030.00614.45
5.6.290.0060.00914.48
5.6.280.0030.04117.81
5.6.270.0030.00614.42
5.6.260.0060.00614.36
5.6.250.0030.01314.42
5.6.240.0060.00914.15
5.6.230.0150.00014.29
5.6.220.0050.02817.43
5.6.210.0020.05017.53
5.6.200.0030.04717.58
5.6.190.0050.04517.78
5.6.180.0080.04517.60
5.6.170.0130.04017.84
5.6.160.0050.04617.65
5.6.150.0050.03917.74
5.6.140.0060.04617.70
5.6.130.0050.03917.53
5.6.120.0050.04217.85
5.6.110.0070.04317.69
5.6.100.0050.02017.57
5.6.90.0030.04917.74
5.6.80.0080.04017.37
5.6.70.0070.04217.28
5.6.60.0110.02617.32
5.6.50.0040.02417.26
5.6.40.0030.04117.35
5.6.30.0080.04217.24
5.6.20.0000.04517.45
5.6.10.0100.03817.36
5.6.00.0050.04117.34
5.5.380.0000.01014.04
5.5.370.0060.00914.24
5.5.360.0080.04317.23
5.5.350.0070.04317.24
5.5.340.0070.03017.54
5.5.330.0030.04817.40
5.5.320.0070.04317.54
5.5.310.0020.04017.72
5.5.300.0080.03217.52
5.5.290.0070.04117.50
5.5.280.0060.04317.55
5.5.270.0050.04617.54
5.5.260.0030.04517.38
5.5.250.0050.03417.30
5.5.240.0100.03817.29
5.5.230.0050.04217.18
5.5.220.0050.02817.29
5.5.210.0030.02617.26
5.5.200.0080.03717.26
5.5.190.0020.04517.31
5.5.180.0020.02717.04
5.5.170.0060.00914.28
5.5.160.0100.03717.21
5.5.150.0030.03717.00
5.5.140.0070.04117.22
5.5.130.0030.04317.08
5.5.120.0070.02817.20
5.5.110.0050.04517.00
5.5.100.0050.04217.20
5.5.90.0050.03517.21
5.5.80.0050.03417.13
5.5.70.0030.03217.17
5.5.60.0030.03817.01
5.5.50.0060.02117.12
5.5.40.0060.02617.29
5.5.30.0080.04017.01
5.5.20.0070.03517.03
5.5.10.0000.03617.00
5.5.00.0080.04017.22
5.4.450.0050.04315.13
5.4.440.0130.03815.20
5.4.430.0050.02915.24
5.4.420.0050.03915.13
5.4.410.0060.04015.06
5.4.400.0000.03514.99
5.4.390.0050.04015.22
5.4.380.0070.03815.06
5.4.370.0030.02715.04
5.4.360.0020.02115.09
5.4.350.0050.03315.01
5.4.340.0000.02614.99
5.4.330.0050.00310.96
5.4.320.0030.03615.03
5.4.310.0060.03815.12
5.4.300.0090.03515.22
5.4.290.0050.04015.15
5.4.280.0050.04015.04
5.4.270.0020.04414.96
5.4.260.0100.03715.04
5.4.250.0030.03314.93
5.4.240.0060.03814.98
5.4.230.0050.03314.98
5.4.220.0030.02815.09
5.4.210.0090.03714.99
5.4.200.0020.03015.12
5.4.190.0040.03214.81
5.4.180.0060.03315.12
5.4.170.0030.02814.95
5.4.160.0020.02615.21
5.4.150.0000.04714.92
5.4.140.0060.03413.70
5.4.130.0050.03513.70
5.4.120.0030.03313.79
5.4.110.0050.03713.74
5.4.100.0050.04013.66
5.4.90.0060.03413.62
5.4.80.0020.03913.70
5.4.70.0030.02813.71
5.4.60.0020.04213.63
5.4.50.0000.04213.68
5.4.40.0040.04113.86
5.4.30.0040.03013.53
5.4.20.0030.02213.81
5.4.10.0000.02313.59
5.4.00.0030.02013.37
5.3.290.0050.03912.74
5.3.280.0070.03512.74
5.3.270.0030.04012.69
5.3.260.0060.04212.69
5.3.250.0060.02612.69
5.3.240.0000.04212.78
5.3.230.0020.03112.75
5.3.220.0030.04112.69
5.3.210.0050.04012.76
5.3.200.0050.03212.67
5.3.190.0070.03312.66
5.3.180.0050.02812.67
5.3.170.0070.03112.71
5.3.160.0050.03212.72
5.3.150.0030.03012.69
5.3.140.0000.03812.66
5.3.130.0040.02812.71
5.3.120.0020.03012.71
5.3.110.0040.02612.67
5.3.100.0050.01812.44
5.3.90.0000.02412.40
5.3.80.0040.03612.42
5.3.70.0070.01812.42
5.3.60.0060.01512.41
5.3.50.0070.01512.44
5.3.40.0010.02112.38
5.3.30.0020.01912.43
5.3.20.0020.01712.24
5.3.10.0020.01512.29
5.3.00.0030.02812.30
5.2.170.0000.03012.28
5.2.160.0030.03312.28
5.2.150.0000.03012.28
5.2.140.0030.02712.28
5.2.130.0000.04312.28
5.2.120.0000.03012.28
5.2.110.0000.02712.28
5.2.100.0000.02312.28
5.2.90.0000.02712.28
5.2.80.0000.02312.28
5.2.70.0000.02712.28
5.2.60.0000.02312.28
5.2.50.0000.03012.28
5.2.40.0000.02312.28
5.2.30.0030.02312.28
5.2.20.0030.02312.28
5.2.10.0000.03012.28
5.2.00.0000.02312.28
5.1.60.0000.02312.28
5.1.50.0000.02012.28
5.1.40.0000.02012.28
5.1.30.0030.03012.28
5.1.20.0000.02012.28
5.1.10.0030.02012.28
5.1.00.0000.02012.28
5.0.50.0000.01712.28
5.0.40.0030.01712.28
5.0.30.0000.03312.28
5.0.20.0000.02012.28
5.0.10.0000.01712.28
5.0.00.0000.03012.28
4.4.90.0000.01312.28
4.4.80.0000.01312.28
4.4.70.0000.02012.28
4.4.60.0000.01312.28
4.4.50.0000.01712.28
4.4.40.0000.02012.28
4.4.30.0000.01312.28
4.4.20.0030.01312.28
4.4.10.0000.01312.28
4.4.00.0000.02312.28
4.3.110.0000.01312.28
4.3.100.0000.01712.28
4.3.90.0000.01012.28
4.3.80.0000.02012.28
4.3.70.0000.01012.28
4.3.60.0000.01012.28
4.3.50.0030.01012.28
4.3.40.0000.02012.28
4.3.30.0000.01312.28
4.3.20.0030.01012.28
4.3.10.0030.01012.28
4.3.00.0000.01312.28

preferences:
35 ms | 400 KiB | 5 Q