3v4l.org

run code in 300+ PHP versions simultaneously
<?php class appendiceHelper { public $document; public $documentDealer; public $documentDate; public $Luglio2015; public $Ottobre2015; public $special; public function __construct($dealer,$date) { $this->documentDealer = $dealer; $this->documentDate = new DateTime($date); $this->document = "pdf/appendice_EM.pdf"; $this->special = 0; $this->IsSpecial(); $this->Luglio2015 = new DateTime(); $this->Luglio2015->setDate(2015, 7, 1); $this->Luglio2015->setTime(00, 01); $this->Ottobre2015 = new DateTime(); $this->Ottobre2015->setDate(2015, 10, 1); $this->Ottobre2015->setTime(00, 01); } private function IsSpecial() { //Dealer Stracciari - Authos if ($this->documentDealer == 882) $this->special = 1; if ($this->documentDealer == 1821) $this->special = 1; if ($this->documentDealer == 2633) $this->special = 1; if ($this->documentDealer == 3194) $this->special = 1; if ($this->documentDealer == 3206) $this->special = 1; if ($this->documentDealer == 3210) $this->special = 1; if ($this->documentDealer == 3218) $this->special = 1; if ($this->documentDealer == 3223) $this->special = 1; } public function getDocument() { $this->document = "pdf/app_cert_4.pdf"; $intervalLuglio2015 = $this->Luglio2015->diff($this->documentDate)->invert; $intervalOttobre2015 = $this->Ottobre2015->diff($this->documentDate)->invert; if($intervalOttobre2015 == 1) $this->document = "pdf/app_cert_2.pdf"; if($intervalLuglio2015 == 1) $this->document = "pdf/app_cert_1.pdf"; if($this->special == 1) { $this->document = "pdf/app_cert_5_special.pdf"; if($intervalOttobre2015 == 1) $this->document = "pdf/app_cert_3_special.pdf"; if($intervalLuglio2015 == 1) $this->document = "pdf/app_cert_1.pdf"; } return $this->document; } } $test = new appendiceHelper(1, new DateTime()) ?>

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.0110.00716.88
8.3.50.0040.01116.72
8.3.40.0050.01018.88
8.3.30.0090.00619.09
8.3.20.0000.00720.17
8.3.10.0040.00421.93
8.3.00.0040.00423.51
8.2.180.0070.01016.75
8.2.170.0070.00719.21
8.2.160.0070.00722.96
8.2.150.0080.00025.66
8.2.140.0050.00224.66
8.2.130.0040.00419.73
8.2.120.0040.00426.35
8.2.110.0060.00322.13
8.2.100.0080.00317.93
8.2.90.0040.00419.23
8.2.80.0030.00617.97
8.2.70.0070.00317.75
8.2.60.0000.00817.80
8.2.50.0040.00418.07
8.2.40.0040.00420.45
8.2.30.0050.00321.14
8.2.20.0000.00717.90
8.2.10.0080.00018.09
8.2.00.0000.00918.06
8.1.270.0160.00323.96
8.1.260.0070.00328.09
8.1.250.0080.00028.09
8.1.240.0040.00422.48
8.1.230.0030.00919.02
8.1.220.0040.00417.74
8.1.210.0060.00318.77
8.1.200.0060.00317.38
8.1.190.0030.00517.50
8.1.180.0040.00418.10
8.1.170.0080.00018.70
8.1.160.0000.00720.77
8.1.150.0060.00318.78
8.1.140.0040.00419.59
8.1.130.0000.00717.74
8.1.120.0040.00417.56
8.1.110.0000.00717.59
8.1.100.0000.00717.59
8.1.90.0040.00417.53
8.1.80.0070.00017.54
8.1.70.0050.00217.67
8.1.60.0030.00617.61
8.1.50.0030.00517.70
8.1.40.0030.00517.63
8.1.30.0090.00017.79
8.1.20.0040.00417.84
8.1.10.0080.00017.68
8.1.00.0000.00817.72
8.0.300.0000.00718.77
8.0.290.0040.00416.84
8.0.280.0020.00518.36
8.0.270.0040.00417.18
8.0.260.0030.00317.29
8.0.250.0000.00717.21
8.0.240.0060.00017.20
8.0.230.0040.00417.17
8.0.220.0000.00717.15
8.0.210.0000.00717.07
8.0.200.0070.00017.14
8.0.190.0040.00417.18
8.0.180.0070.00017.14
8.0.170.0000.00717.04
8.0.160.0030.00517.12
8.0.150.0040.00416.93
8.0.140.0040.00316.99
8.0.130.0000.00513.56
8.0.120.0040.00417.05
8.0.110.0000.00917.15
8.0.100.0040.00416.96
8.0.90.0040.00417.18
8.0.80.0070.01117.17
8.0.70.0040.00417.03
8.0.60.0070.00017.11
8.0.50.0000.00717.07
8.0.30.0080.00917.31
8.0.20.0130.01117.44
8.0.10.0040.00417.31
8.0.00.0110.00916.97
7.4.330.0030.00316.83
7.4.320.0000.00616.55
7.4.300.0030.00316.70
7.4.290.0040.00416.71
7.4.280.0060.00316.52
7.4.270.0040.00416.61
7.4.260.0070.00316.66
7.4.250.0020.00516.66
7.4.240.0000.00716.67
7.4.230.0030.00516.64
7.4.220.0040.01216.65
7.4.210.0090.00516.68
7.4.200.0030.00316.52
7.4.160.0100.00616.72
7.4.150.0090.00917.40
7.4.140.0100.01217.86
7.4.130.0070.01116.71
7.4.120.0090.01116.78
7.4.110.0110.00516.72
7.4.100.0100.01316.70
7.4.90.0150.00316.89
7.4.80.0030.01419.39
7.4.70.0120.00616.70
7.4.60.0030.01316.67
7.4.50.0110.00316.57
7.4.40.0100.00716.84
7.4.30.0100.00716.57
7.4.00.0070.00715.35
7.3.330.0030.00313.52
7.3.320.0000.00613.47
7.3.310.0050.00216.40
7.3.300.0000.00616.42
7.3.290.0000.00716.49
7.3.280.0100.00816.52
7.3.270.0030.01417.40
7.3.260.0170.00016.58
7.3.250.0110.01016.58
7.3.240.0100.00616.65
7.3.230.0090.00916.66
7.3.210.0090.00916.55
7.3.200.0030.01519.39
7.3.190.0000.01816.55
7.3.180.0100.00616.69
7.3.170.0070.01016.75
7.3.160.0060.01016.70
7.3.10.0170.00616.23
7.3.00.0180.00516.48
7.2.330.0110.00716.68
7.2.320.0040.01316.88
7.2.310.0110.00616.83
7.2.300.0030.01416.54
7.2.290.0120.00816.84
7.2.130.0090.01216.82
7.2.120.0170.00716.70
7.2.110.0100.01016.43
7.2.100.0140.00816.35
7.2.90.0170.00716.55
7.2.80.0160.00516.64
7.2.70.0160.00816.68
7.2.60.0120.00617.04
7.2.50.0170.00616.88
7.2.40.0120.00816.41
7.2.30.0090.01216.62
7.2.20.0120.00616.59
7.2.10.0160.01016.44
7.2.00.0130.00618.15
7.1.250.0180.00715.29
7.1.200.0040.01115.94
7.1.100.0000.01118.09
7.1.70.0030.00517.28
7.1.60.0070.01619.27
7.1.50.0100.01317.00
7.1.00.0030.07722.57
7.0.200.0000.00716.98
7.0.60.0200.06721.66
7.0.50.0100.06017.99
7.0.40.0130.08020.21
7.0.30.0600.06020.09
7.0.20.0230.04320.20
7.0.10.0070.06020.20
7.0.00.0030.04320.22
5.6.280.0070.03021.12
5.6.210.0070.07720.78
5.6.200.0000.04318.16
5.6.190.0100.04020.33
5.6.180.0430.06020.63
5.6.170.0200.07720.40
5.6.160.0070.05020.44
5.6.150.0070.03718.13
5.6.140.0130.07018.19
5.6.130.0070.06318.13
5.6.120.0130.04720.87
5.6.110.0070.08320.90
5.6.100.0100.04721.12
5.6.90.0100.06721.09
5.6.80.0000.04020.30
5.5.350.0200.04020.30
5.5.340.0070.06718.08
5.5.330.0030.09020.27
5.5.320.0270.07020.34
5.5.310.0300.07320.23
5.5.300.0030.08317.95
5.5.290.0000.05718.05
5.5.280.0030.04320.70
5.5.270.0170.07720.70
5.5.260.0030.04020.89
5.5.250.0100.07720.48
5.5.240.0130.06720.38

preferences:
65.86 ms | 400 KiB | 5 Q