3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Post { protected $title; protected $text; protected $filters; function __construct($title, $text, $filters) { $this->title = $title; $this->text = $text; $this->filters = $filters; } function get_title() { return htmlspecialchars($this->title); } function display_post() { $text = htmlspecialchars($this->text); foreach ($this->filters as $filter) $text = $filter->filter($text); return $text; } function __destruct() { // debugging stuff $s = "<!-- POST " . htmlspecialchars($this->title); $text = htmlspecialchars($this->text); foreach ($this->filters as $filter) $text = $filter->filter($text); $s = $s . ": " . $text; $s = $s . " -->"; echo $s; } }; echo serialize(new Post("huehuehue i repor u", new SplFileObject("/home/daedalus/flag.txt"), Array()));

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.0090.00618.92
8.3.30.0030.01018.99
8.3.20.0040.00420.33
8.3.10.0050.00323.61
8.3.00.0000.00819.38
8.2.170.0120.00322.96
8.2.160.0040.01420.44
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0050.00326.16
8.2.120.0000.00822.28
8.2.110.0100.00019.21
8.2.100.0090.00617.63
8.2.90.0040.00419.27
8.2.80.0080.00017.97
8.2.70.0000.00817.50
8.2.60.0030.00517.80
8.2.50.0030.00618.07
8.2.40.0000.00819.76
8.2.30.0040.00418.01
8.2.20.0000.00817.72
8.2.10.0040.00418.04
8.2.00.0060.00317.77
8.1.270.0000.00823.91
8.1.260.0070.00026.35
8.1.250.0070.00028.09
8.1.240.0040.00423.91
8.1.230.0120.00017.42
8.1.220.0040.00417.74
8.1.210.0050.00518.77
8.1.200.0090.00017.23
8.1.190.0000.00817.23
8.1.180.0000.00918.10
8.1.170.0000.00818.46
8.1.160.0000.00721.89
8.1.150.0040.00418.79
8.1.140.0000.00717.28
8.1.130.0030.00317.81
8.1.120.0000.00717.44
8.1.110.0000.00717.43
8.1.100.0000.00817.34
8.1.90.0000.00717.41
8.1.80.0050.00217.20
8.1.70.0030.00317.26
8.1.60.0050.00317.54
8.1.50.0040.00417.48
8.1.40.0080.00017.48
8.1.30.0000.00817.64
8.1.20.0040.00417.55
8.1.10.0000.00717.55
8.1.00.0030.00517.38
8.0.300.0040.00418.77
8.0.290.0000.00816.63
8.0.280.0030.00318.42
8.0.270.0030.00317.14
8.0.260.0000.00617.14
8.0.250.0030.00317.03
8.0.240.0030.00316.98
8.0.230.0000.00716.89
8.0.220.0070.00017.00
8.0.210.0040.00416.96
8.0.200.0000.00717.01
8.0.190.0000.00716.90
8.0.180.0000.00716.98
8.0.170.0040.00416.92
8.0.160.0080.00016.87
8.0.150.0040.00416.84
8.0.140.0030.00516.87
8.0.130.0030.00313.34
8.0.120.0080.00016.91
8.0.110.0000.00816.98
8.0.100.0050.00317.00
8.0.90.0040.00416.79
8.0.80.0100.00616.90
8.0.70.0040.00416.96
8.0.60.0020.00517.00
8.0.50.0050.00316.82
8.0.30.0070.01417.13
8.0.20.0160.00617.40
8.0.10.0030.00516.89
8.0.00.0120.00516.77
7.4.330.0020.00215.02
7.4.320.0000.00616.42
7.4.300.0070.00016.59
7.4.290.0070.00016.56
7.4.280.0000.00716.43
7.4.270.0000.00716.43
7.4.260.0070.00016.52
7.4.250.0070.00016.46
7.4.240.0060.00216.56
7.4.230.0030.00316.37
7.4.220.0120.01516.61
7.4.210.0180.00016.61
7.4.200.0000.00716.67
7.4.160.0170.00016.38
7.4.150.0120.00617.40
7.4.140.0050.01317.86
7.4.130.0080.00816.36
7.4.120.0140.00716.60
7.4.110.0070.01116.38
7.4.100.0150.00316.53
7.4.90.0030.01416.56
7.4.80.0070.01019.39
7.4.70.0100.00716.41
7.4.60.0150.00616.55
7.4.50.0000.00416.45
7.4.40.0070.01016.65
7.4.30.0070.01016.49
7.4.00.0100.00714.87
7.3.330.0030.00313.38
7.3.320.0000.00513.34
7.3.310.0000.00716.40
7.3.300.0040.00416.45
7.3.290.0150.00516.37
7.3.280.0080.00816.39
7.3.270.0180.00617.40
7.3.260.0130.01016.34
7.3.250.0080.01116.34
7.3.240.0160.00616.30
7.3.230.0160.00816.39
7.3.210.0140.00316.35
7.3.200.0120.00919.39
7.3.190.0070.01416.49
7.3.180.0030.01216.34
7.3.170.0070.01316.47
7.3.160.0040.01216.35
7.3.00.0090.00616.54
7.2.330.0120.00616.54
7.2.320.0110.00616.53
7.2.310.0130.00316.63
7.2.300.0140.00316.74
7.2.290.0070.01016.59
7.2.130.0070.01016.18
7.2.120.0100.00616.56
7.2.110.0160.00316.69
7.2.100.0100.00716.57
7.2.90.0120.00616.72
7.2.80.0130.00016.59
7.2.70.0140.00716.71
7.2.60.0140.00516.74
7.2.50.0060.00616.21
7.2.40.0180.00016.76
7.2.30.0090.00916.57
7.2.20.0140.00716.34
7.2.10.0130.00316.18
7.2.00.0060.00916.34
7.1.250.0060.01015.51
7.1.240.0090.00315.24
7.1.230.0060.00615.50
7.1.220.0130.00015.09
7.1.210.0100.00315.20
7.1.200.0040.00815.38
7.1.190.0110.01115.32
7.1.180.0130.00315.52
7.1.170.0100.00715.25
7.1.160.0160.00315.19
7.1.150.0130.00615.29
7.1.140.0080.00315.38
7.1.130.0030.01015.36
7.1.120.0070.01115.36
7.1.110.0100.00615.50
7.1.100.0110.00715.38
7.1.90.0110.00015.65
7.1.80.0090.00615.42
7.1.70.0070.00716.31
7.1.60.0140.00617.31
7.1.50.0110.01024.95
7.1.40.0150.00415.56
7.1.30.0090.00615.49
7.1.20.0140.00315.47
7.1.10.0070.01115.45
7.1.00.0060.04318.82
7.0.330.0030.01015.38
7.0.320.0130.00715.15
7.0.310.0110.00415.12
7.0.300.0090.00315.00
7.0.290.0150.00315.06
7.0.280.0100.00714.98
7.0.270.0080.00415.09
7.0.260.0030.01415.20
7.0.250.0140.00715.16
7.0.240.0110.00615.38
7.0.230.0110.00815.07
7.0.220.0140.00415.08
7.0.210.0170.00915.22
7.0.200.0090.00715.87
7.0.190.0090.00915.30
7.0.180.0140.00715.44
7.0.170.0140.00315.32
7.0.160.0130.00815.06
7.0.150.0130.00515.38
7.0.140.0110.03818.73
7.0.130.0120.00314.94
7.0.120.0060.00615.02
7.0.110.0290.04817.67
7.0.100.0110.04317.59
7.0.90.0110.03017.67
7.0.80.0130.03017.60
7.0.70.0110.03617.54
7.0.60.0130.04017.26
7.0.50.0070.04317.63
7.0.40.0080.03816.52
7.0.30.0030.04516.30
7.0.20.0100.03016.56
7.0.10.0000.04316.56
7.0.00.0100.03816.43
5.6.380.0070.00314.02
5.6.370.0150.00914.24
5.6.360.0090.01514.29
5.6.350.0150.00914.41
5.6.340.0060.00914.35
5.6.330.0060.00914.00
5.6.320.0070.00714.25
5.6.310.0080.00414.21
5.6.300.0000.01113.93
5.6.290.0000.01313.92
5.6.280.0080.03617.44
5.6.270.0000.01114.15
5.6.260.0090.04517.41
5.6.250.0120.03317.36
5.6.240.0080.03717.24
5.6.230.0070.03717.38
5.6.220.0050.04517.39
5.6.210.0050.03617.22
5.6.200.0050.04717.47
5.6.190.0050.04217.30
5.6.180.0120.03517.22
5.6.170.0090.03617.42
5.6.160.0080.04317.38
5.6.150.0140.03817.48
5.6.140.0130.03917.31
5.6.130.0020.04617.42
5.6.120.0030.04617.46
5.6.110.0070.04017.60
5.6.100.0090.04417.37
5.6.90.0050.04317.35
5.6.80.0120.03516.98
5.6.70.0050.04217.11
5.6.60.0120.03816.96
5.6.50.0090.04116.98
5.6.40.0090.04017.06
5.6.30.0070.02517.21
5.6.20.0080.04316.91
5.6.10.0080.02316.83
5.6.00.0050.03917.05
5.5.380.0020.04314.35
5.5.370.0060.04214.43
5.5.360.0030.03514.24
5.5.350.0030.04214.34
5.5.340.0070.02214.49
5.5.330.0080.04114.49
5.5.320.0080.03114.57
5.5.310.0000.04614.62
5.5.300.0050.02714.41
5.5.290.0030.04214.48
5.5.280.0050.04514.50
5.5.270.0070.04114.54
5.5.260.0120.03814.65
5.5.250.0060.04114.27
5.5.240.0100.03814.30
5.5.230.0030.04014.21
5.5.220.0070.04214.20
5.5.210.0120.03414.26
5.5.200.0060.02514.18
5.5.190.0010.02614.10
5.5.180.0020.03914.16
5.5.170.0030.00910.90
5.5.160.0050.02514.24
5.5.150.0020.03714.18
5.5.140.0020.02914.22
5.5.130.0100.03514.24
5.5.120.0080.02214.08
5.5.110.0070.04014.17
5.5.100.0030.04314.04
5.5.90.0040.04014.19
5.5.80.0080.03514.03
5.5.70.0040.03614.12
5.5.60.0050.03914.08
5.5.50.0040.03914.19
5.5.40.0030.04014.13
5.5.30.0030.04114.02
5.5.20.0050.04214.13
5.5.10.0030.03214.06
5.5.00.0060.03914.04
5.4.450.0020.04315.33
5.4.440.0000.04515.25
5.4.430.0070.04215.08
5.4.420.0080.03815.22
5.4.410.0130.03315.02
5.4.400.0060.04014.95
5.4.390.0080.03515.02
5.4.380.0050.02415.07
5.4.370.0050.04214.95
5.4.360.0090.03414.94
5.4.350.0020.02414.95
5.4.340.0030.03414.94
5.4.330.0060.00610.90
5.4.320.0110.03115.12
5.4.310.0020.04014.94
5.4.300.0080.03214.94
5.4.290.0050.04014.96
5.4.280.0070.03514.98
5.4.270.0030.03815.04
5.4.260.0060.03815.07
5.4.250.0060.03615.04
5.4.240.0030.03615.05
5.4.230.0070.03815.11
5.4.220.0050.03214.94
5.4.210.0050.04014.96
5.4.200.0070.03715.14
5.4.190.0090.03715.04
5.4.180.0040.02515.04
5.4.170.0080.02015.03
5.4.160.0030.04314.95
5.4.150.0060.03614.94
5.4.140.0070.02613.60
5.4.130.0080.03013.68
5.4.120.0050.03913.63
5.4.110.0040.04213.65
5.4.100.0090.03413.74
5.4.90.0050.03913.68
5.4.80.0070.02413.72
5.4.70.0100.03313.60
5.4.60.0050.02713.72
5.4.50.0080.03813.67
5.4.40.0080.03613.68
5.4.30.0080.04113.80
5.4.20.0050.04013.73
5.4.10.0060.03913.64
5.4.00.0070.03913.43
5.3.290.0120.01912.81
5.3.280.0030.03312.83
5.3.270.0050.04212.78
5.3.260.0040.03912.75
5.3.250.0020.04012.80
5.3.240.0040.04212.82
5.3.230.0080.03612.80
5.3.220.0080.03812.74
5.3.210.0040.04512.74
5.3.200.0070.03712.74
5.3.190.0080.03512.75
5.3.180.0080.02312.73
5.3.170.0080.03412.74
5.3.160.0070.03612.80
5.3.150.0060.04112.72
5.3.140.0090.03712.74
5.3.130.0050.02212.73
5.3.120.0100.03612.71
5.3.110.0070.04312.73
5.3.100.0120.03512.46
5.3.90.0110.03512.39
5.3.80.0060.04012.44
5.3.70.0060.04412.51
5.3.60.0030.04212.44
5.3.50.0050.04212.46
5.3.40.0030.04212.41
5.3.30.0090.03712.40
5.3.20.0000.04012.37
5.3.10.0050.04012.30
5.3.00.0100.02512.39
5.2.170.0070.02911.07
5.2.160.0050.03511.07
5.2.150.0060.03011.02
5.2.140.0020.03810.96
5.2.130.0070.02811.00
5.2.120.0000.03811.00
5.2.110.0050.03111.00
5.2.100.0020.03311.04
5.2.90.0070.02810.99
5.2.80.0060.03111.04
5.2.70.0080.02011.03
5.2.60.0020.03811.03
5.2.50.0060.03010.97
5.2.40.0020.03611.07
5.2.30.0020.03210.96
5.2.20.0050.02010.92
5.2.10.0060.02710.88
5.2.00.0060.02810.82
5.1.60.0030.02810.44
5.1.50.0020.02610.45
5.1.40.0070.02010.48
5.1.30.0050.02710.64
5.1.20.0070.02210.67
5.1.10.0010.03010.58
5.1.00.0030.02510.49
5.0.50.0050.02310.36
5.0.40.0050.02110.36
5.0.30.0030.03210.36
5.0.20.0020.01510.36
5.0.10.0030.01910.36
5.0.00.0060.03010.36
4.4.90.0050.01710.36
4.4.80.0020.01910.36
4.4.70.0030.01810.36
4.4.60.0030.01810.36
4.4.50.0020.02010.36
4.4.40.0000.02010.36
4.4.30.0020.02010.36
4.4.20.0050.01810.36
4.4.10.0020.01210.36
4.4.00.0000.02910.36
4.3.110.0030.00910.36
4.3.100.0030.01810.36
4.3.90.0020.01810.36
4.3.80.0040.02510.36
4.3.70.0050.00810.36
4.3.60.0020.01710.36
4.3.50.0020.01710.36
4.3.40.0010.02610.36
4.3.30.0010.01810.36
4.3.20.0030.01510.36
4.3.10.0020.01410.36
4.3.00.0000.01410.36

preferences:
42.05 ms | 400 KiB | 5 Q