3v4l.org

run code in 300+ PHP versions simultaneously
<?php // include('database.php'); // require('fpdf.php'); class FPDF {} $process = new Process(); class PDF extends FPDF { function Header() { // Logo $this->Image('logo.png',10,6,30); // Arial bold 15 $this->SetFont('Arial','B',15); // Move to the right $this->Cell(80); // Title $this->Cell(30,10,'Title',1,0,'C'); // Line break $this->Ln(20); } function Footer() { // Position at 1.5 cm from bottom $this->SetY(-15); // Arial italic 8 $this->SetFont('Arial','I',8); // Page number $this->Cell(0,10,'Page '.$this->PageNo().'/{nb}',0,0,'C'); } } class Process { private $dbconn; private $pdf; private $resultarr = array(); private $identarr = array(); function __construct() { $this->dbconn = new Database(); $this->pdf = new PDF(); $this->init(0); } private function init($i) { switch($i) { case 0: $query = "SELECT ident FROM vm_result WHERE date > NOW() - INTERVAL 7 DAY GROUP BY ident"; break; case 1: break; } $this->load_entries($query); } private function load_entries($query) { $result = $this->dbconn->query($query); while($row = $result->fetch_assoc()) { array_push($this->identarr, $row['ident']); } // loop per customer foreach($this->identarr as $ident) { $this->resultarr = array(); $query = "SELECT name, count, date FROM vm_result WHERE ident = '$ident' ORDER BY date ASC"; $result = $this->dbconn->query($query); while($row = $result->fetch_assoc()) { $str = $row['name'] . ':' . $row['count'] . ':' . $row['date']; array_push($this->resultarr, $str); } // summarize $this->summarize(); } } private function summarize() { foreach($this->resultarr as $entry) { $tmp = explode(":", $entry); $name = $tmp[0]; $count = $tmp[1]; $day = $tmp[2]; } } } ?>

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.0160.00618.97
8.3.30.0140.00019.14
8.3.20.0080.00020.39
8.3.10.0080.00023.67
8.3.00.0080.00019.38
8.2.170.0070.01122.96
8.2.160.0120.00320.25
8.2.150.0060.00324.18
8.2.140.0040.00424.66
8.2.130.0090.00026.16
8.2.120.0000.00720.94
8.2.110.0060.00320.54
8.2.100.0040.00818.09
8.2.90.0000.00819.17
8.2.80.0000.00917.97
8.2.70.0060.00317.50
8.2.60.0040.00417.93
8.2.50.0050.00318.07
8.2.40.0030.00519.75
8.2.30.0090.00017.92
8.2.20.0090.00017.60
8.2.10.0000.00717.89
8.2.00.0040.00417.58
8.1.270.0030.00623.79
8.1.260.0070.00026.35
8.1.250.0000.00728.09
8.1.240.0000.00823.97
8.1.230.0040.00719.16
8.1.220.0040.00417.74
8.1.210.0050.00318.77
8.1.200.0060.00317.13
8.1.190.0060.00317.13
8.1.180.0030.00618.10
8.1.170.0000.00818.66
8.1.160.0000.00721.98
8.1.150.0000.00818.70
8.1.140.0000.00717.36
8.1.130.0000.00717.79
8.1.120.0000.00717.40
8.1.110.0030.00617.39
8.1.100.0040.00417.41
8.1.90.0040.00417.26
8.1.80.0070.00017.38
8.1.70.0000.00817.28
8.1.60.0040.00417.56
8.1.50.0040.00417.37
8.1.40.0080.00017.40
8.1.30.0040.00417.62
8.1.20.0050.00317.68
8.1.10.0000.00817.58
8.1.00.0000.00817.54
8.0.300.0040.00418.77
8.0.290.0030.00616.75
8.0.280.0000.00718.33
8.0.270.0000.00717.22
8.0.260.0000.00817.09
8.0.250.0030.00316.85
8.0.240.0040.00416.97
8.0.230.0000.00717.02
8.0.220.0050.00216.92
8.0.210.0040.00416.75
8.0.200.0060.00016.96
8.0.190.0040.00417.07
8.0.180.0000.00716.91
8.0.170.0030.00516.98
8.0.160.0000.00716.98
8.0.150.0030.00516.91
8.0.140.0040.00416.89
8.0.130.0030.00313.43
8.0.120.0050.00216.73
8.0.110.0050.00316.82
8.0.100.0070.00016.74
8.0.90.0080.00016.77
8.0.80.0090.01216.86
8.0.70.0000.00716.92
8.0.60.0000.00716.80
8.0.50.0000.00716.78
8.0.30.0110.01116.98
8.0.20.0080.01017.40
8.0.10.0030.00616.91
8.0.00.0090.01016.68
7.4.330.0050.00015.02
7.4.320.0000.00716.55
7.4.300.0060.00016.46
7.4.290.0080.00016.39
7.4.280.0080.00416.37
7.4.270.0030.00316.49
7.4.260.0050.00316.44
7.4.250.0000.00716.33
7.4.240.0020.00516.48
7.4.230.0030.00316.65
7.4.220.0220.00616.57
7.4.210.0080.01116.64
7.4.200.0040.00416.36
7.4.160.0060.01216.37
7.4.150.0100.00717.40
7.4.140.0030.01417.86
7.4.130.0090.00816.51
7.4.120.0010.01616.49
7.4.110.0180.00016.39
7.4.100.0070.01116.37
7.4.90.0090.00916.54
7.4.80.0060.01219.39
7.4.70.0070.01016.62
7.4.60.0100.00716.48
7.4.50.0000.00816.38
7.4.40.0060.01016.44
7.4.30.0130.00316.43
7.4.10.0100.01015.04
7.4.00.0060.00914.91
7.3.330.0030.00313.34
7.3.320.0000.00713.42
7.3.310.0070.00016.45
7.3.300.0030.00616.36
7.3.290.0100.00316.47
7.3.280.0070.01116.39
7.3.270.0190.00817.40
7.3.260.0150.00416.68
7.3.250.0130.00816.48
7.3.240.0060.01616.49
7.3.230.0100.00716.58
7.3.210.0090.00916.64
7.3.200.0140.00719.39
7.3.190.0110.01116.42
7.3.180.0100.00616.29
7.3.170.0160.00016.32
7.3.160.0060.01016.63
7.3.130.0070.01114.91
7.3.120.0100.00314.69
7.3.110.0090.00914.65
7.3.100.0070.01014.82
7.3.90.0070.00714.95
7.3.80.0110.00714.89
7.3.70.0030.01014.56
7.3.60.0060.00914.98
7.3.50.0090.00914.65
7.3.40.0030.01314.86
7.3.30.0060.00914.53
7.3.20.0000.01216.46
7.3.10.0070.00716.51
7.3.00.0090.00916.39
7.2.330.0170.00716.32
7.2.320.0100.00716.44
7.2.310.0070.01116.67
7.2.300.0030.01316.58
7.2.290.0000.01716.46
7.2.260.0080.00814.98
7.2.250.0090.00914.79
7.2.240.0040.01115.19
7.2.230.0070.01014.92
7.2.220.0110.00614.89
7.2.210.0040.01114.67
7.2.200.0060.00915.20
7.2.190.0090.00614.88
7.2.180.0030.00614.80
7.2.170.0070.01015.02
7.2.160.0100.00314.78
7.2.150.0100.00716.66
7.2.140.0100.00316.64
7.2.130.0000.01316.63
7.2.120.0060.00616.60
7.2.110.0090.00616.75
7.2.100.0030.01316.78
7.2.90.0000.01016.67
7.2.80.0030.00916.62
7.2.70.0000.01016.78
7.2.60.0060.00816.71
7.2.50.0000.01516.73
7.2.40.0030.00716.62
7.2.30.0030.00716.84
7.2.20.0070.00316.80
7.2.10.0000.01416.78
7.2.00.0050.00817.76
7.1.330.0000.01415.68
7.1.320.0100.01015.68
7.1.310.0030.00615.49
7.1.300.0090.00915.63
7.1.290.0070.01015.58
7.1.280.0070.00715.63
7.1.270.0110.00315.50
7.1.260.0030.01315.70
7.1.250.0000.00915.46
7.1.240.0070.00715.75
7.1.230.0030.00615.66
7.1.220.0000.01215.49
7.1.210.0090.00615.36
7.1.200.0060.00715.65
7.1.190.0100.00315.79
7.1.180.0040.01115.74
7.1.170.0000.01015.68
7.1.160.0030.00515.43
7.1.150.0050.00315.61
7.1.140.0040.00815.64
7.1.130.0000.01215.38
7.1.120.0060.00615.30
7.1.110.0040.00415.48
7.1.100.0070.00516.92
7.1.90.0090.00615.75
7.1.80.0070.00315.83
7.1.70.0020.01016.12
7.1.60.0080.01017.52
7.1.50.0150.00924.98
7.1.40.0040.01115.59
7.1.30.0030.01015.37
7.1.20.0030.00615.66
7.1.10.0070.00715.58
7.1.00.0030.04219.11
7.0.330.0000.01115.07
7.0.320.0000.01415.29
7.0.310.0060.00815.18
7.0.300.0040.00815.32
7.0.290.0030.00515.38
7.0.280.0000.01015.46
7.0.270.0040.01115.26
7.0.260.0070.00715.43
7.0.250.0080.00615.30
7.0.240.0030.01015.06
7.0.230.0030.00815.05
7.0.220.0000.01415.50
7.0.210.0030.01115.18
7.0.200.0320.00714.93
7.0.190.0140.00015.42
7.0.180.0130.00315.45
7.0.170.0070.00715.27
7.0.160.0000.01215.45
7.0.150.0040.01115.18
7.0.140.0020.04218.63
7.0.130.0000.01215.52
7.0.120.0060.00615.38
7.0.110.0040.04517.73
7.0.100.0030.04317.63
7.0.90.0030.04717.74
7.0.80.0060.04217.75
7.0.70.0050.04417.61
7.0.60.0080.03017.75
7.0.50.0020.04917.62
7.0.40.0040.04216.60
7.0.30.0040.02516.51
7.0.20.0050.02916.58
7.0.10.0000.02616.45
7.0.00.0050.02816.54
5.6.400.0040.01114.57
5.6.390.0030.00514.43
5.6.380.0000.01414.35
5.6.370.0030.00614.14
5.6.360.0040.00414.18
5.6.350.0130.00314.45
5.6.340.0040.00814.10
5.6.330.0060.00914.49
5.6.320.0030.00914.29
5.6.310.0060.00914.30
5.6.300.0000.01713.93
5.6.290.0060.00914.18
5.6.280.0070.03817.87
5.6.270.0060.00613.93
5.6.260.0070.04117.39
5.6.250.0060.03617.47
5.6.240.0120.04317.37
5.6.230.0070.04717.51
5.6.220.0120.04217.36
5.6.210.0150.03217.38
5.6.200.0120.04017.45
5.6.190.0060.04317.51
5.6.180.0070.03317.60
5.6.170.0040.02517.48
5.6.160.0050.03317.29
5.6.150.0050.02717.17
5.6.140.0020.02617.51
5.6.130.0030.02317.33
5.6.120.0020.04117.25
5.6.110.0020.03017.51
5.6.100.0050.04217.47
5.6.90.0030.04417.40
5.6.80.0050.03117.09
5.6.70.0060.03917.07
5.6.60.0050.03817.11
5.6.50.0050.02217.12
5.6.40.0030.03516.88
5.6.30.0020.02417.19
5.6.20.0020.03417.06
5.6.10.0020.03817.08
5.6.00.0100.03317.07
5.5.380.0080.04317.20
5.5.370.0120.03517.24
5.5.360.0020.05317.13
5.5.350.0050.03217.30
5.5.340.0060.04017.43
5.5.330.0070.04517.58
5.5.320.0080.02517.59
5.5.310.0090.02217.51
5.5.300.0090.02217.62
5.5.290.0070.02217.47
5.5.280.0020.02617.53
5.5.270.0060.04817.36
5.5.260.0050.03017.57
5.5.250.0030.02717.38
5.5.240.0100.03717.06
5.5.230.0080.02217.24
5.5.220.0020.02617.13
5.5.210.0110.03617.23
5.5.200.0050.03717.20
5.5.190.0070.02017.10
5.5.180.0050.02517.15
5.5.170.0080.00013.71
5.5.160.0050.02817.32
5.5.150.0050.02317.20
5.5.140.0010.02516.92
5.5.130.0060.02017.13
5.5.120.0020.02617.12
5.5.110.0030.02517.05
5.5.100.0040.02116.94
5.5.90.0070.04117.15
5.5.80.0020.02516.92
5.5.70.0040.02417.15
5.5.60.0020.02717.19
5.5.50.0040.02617.21
5.5.40.0050.02316.96
5.5.30.0030.02117.00
5.5.20.0060.02516.99
5.5.10.0050.02317.11
5.5.00.0080.02917.10
5.4.450.0030.02315.69
5.4.440.0030.02415.68
5.4.430.0050.04315.69
5.4.420.0150.03515.77
5.4.410.0030.04015.69
5.4.400.0030.02515.52
5.4.390.0050.03715.64
5.4.380.0040.01915.52
5.4.370.0080.02115.52
5.4.360.0050.02915.66
5.4.350.0050.03815.52
5.4.340.0010.03615.69
5.4.330.0040.00412.04
5.4.320.0050.02515.61
5.4.310.0030.02115.61
5.4.300.0050.02015.65
5.4.290.0070.01815.52
5.4.280.0100.01715.59
5.4.270.0050.02415.56
5.4.260.0030.02315.61
5.4.250.0050.02715.60
5.4.240.0100.01615.61
5.4.230.0020.02215.57
5.4.220.0000.02615.67
5.4.210.0020.02415.69
5.4.200.0000.02215.57
5.4.190.0050.02615.68
5.4.180.0050.02315.49
5.4.170.0020.03015.60
5.4.160.0110.03815.51
5.4.150.0070.03615.51
5.4.140.0030.04414.31
5.4.130.0020.03814.22
5.4.120.0070.02014.30
5.4.110.0040.02714.24
5.4.100.0030.04314.28
5.4.90.0050.02814.33
5.4.80.0050.03814.24
5.4.70.0040.04114.32
5.4.60.0050.02514.19
5.4.50.0070.03714.28
5.4.40.0050.04014.32
5.4.30.0050.04114.22
5.4.20.0080.02114.23
5.4.10.0050.03314.26
5.4.00.0020.04114.00
5.3.290.0000.05014.84
5.3.280.0030.03714.48
5.3.270.0070.06014.63
5.3.260.0070.07714.63
5.3.250.0100.07014.49
5.3.240.0100.06714.77
5.3.230.0000.08314.75
5.3.220.0070.06714.59
5.3.210.0030.07714.71
5.3.200.0070.08014.45
5.3.190.0070.07314.55
5.3.180.0100.07714.66
5.3.170.0000.05714.60
5.3.160.0000.08014.71
5.3.150.0170.06314.61
5.3.140.0100.07314.54
5.3.130.0100.07314.71
5.3.120.0170.08314.80
5.3.110.0030.07314.58
5.3.100.0100.07313.93
5.3.90.0030.07314.10
5.3.80.0030.07714.17
5.3.70.0130.07013.89
5.3.60.0130.06714.00
5.3.50.0070.07313.82
5.3.40.0100.07314.09
5.3.30.0030.07313.79
5.3.20.0000.06713.85
5.3.10.0070.03313.64
5.3.00.0170.05713.89
5.2.170.0030.06312.94
5.2.160.0030.06012.94
5.2.150.0130.05712.94
5.2.140.0030.03712.94
5.2.130.0030.06712.94
5.2.120.0000.03712.94
5.2.110.0070.06012.94
5.2.100.0000.04312.94
5.2.90.0000.03312.94
5.2.80.0130.05312.94
5.2.70.0200.05012.94
5.2.60.0130.05312.94
5.2.50.0100.05712.94
5.2.40.0100.05712.94
5.2.30.0070.06312.94
5.2.20.0030.06312.94
5.2.10.0000.06312.94
5.2.00.0030.06012.94
5.1.60.0070.05012.94
5.1.50.0130.04712.94
5.1.40.0030.05012.94
5.1.30.0070.05712.94
5.1.20.0070.05312.94
5.1.10.0000.06012.94
5.1.00.0030.05712.94
5.0.50.0030.04712.94
5.0.40.0030.04712.94
5.0.30.0070.05712.94
5.0.20.0070.04012.94
5.0.10.0030.04312.94
5.0.00.0000.05012.94
4.4.90.0070.03012.94
4.4.80.0000.03712.94
4.4.70.0070.03312.94
4.4.60.0000.03712.94
4.4.50.0000.02312.94
4.4.40.0030.04312.94
4.4.30.0030.01712.94
4.4.20.0000.03712.94
4.4.10.0030.03712.94
4.4.00.0070.05012.94
4.3.110.0000.03712.94
4.3.100.0070.01312.94
4.3.90.0030.01712.94
4.3.80.0030.05012.94
4.3.70.0030.02712.94
4.3.60.0030.03312.94
4.3.50.0030.03312.94
4.3.40.0030.04312.94
4.3.30.0000.03712.94
4.3.20.0000.03012.94
4.3.10.0130.02712.94
4.3.00.0000.03712.94

preferences:
46.79 ms | 400 KiB | 5 Q