3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace Temple\Modules\Content\Controllers; class Controller { /* private $request; public function __construct(Request $request = null) { $this->request = $request; } protected function getRequest() { return $this->request; } */ protected function render($file) { if (strpos($file, ':') !== false) { list($module, $file) = explode(':', $file); if ($module == 'CoreApp') { $path = CORE_APP_PATH; } else { $path = MODULES_PATH . '/' . $module; } } else { $module = preg_replace('#\\\?Temple\\\Modules\\\([^\\\]+)\\\.*#', '\1', get_called_class()); $path = MODULES_PATH . '/' . $module; } $path = str_replace('\\', DIRECTORY_SEPARATOR, $path); $path .= '/Views/'; $exp = explode('.', $file); $engine = array_pop($exp); $type = array_pop($exp); echo $path . $file; echo "\n"; } } class PagesController extends Controller { public function indexAction() { //return new Response('Ciao! :)'); } public function showAction($id) { // $page = Page::find($id); // // echo $page->category->route->url; $this->render('show.html.twig'); $this->render('admin/new.html.twig'); $this->render('CoreApp:path/to/file.html.twig'); $this->render('Module:path/to/file.html.twig'); $this->render('file.js.twig'); $this->render('file.json.twig'); $this->render('file.css.twig'); $this->render('file.xml.twig'); } } $x = new PagesController(); $x->showAction(4);

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.0120.00618.80
8.3.50.0050.01021.20
8.3.40.0040.01118.92
8.3.30.0040.01219.22
8.3.20.0040.00420.29
8.3.10.0000.00822.09
8.3.00.0070.00020.75
8.2.180.0110.00416.88
8.2.170.0120.00322.96
8.2.160.0070.00719.25
8.2.150.0040.00424.18
8.2.140.0050.00324.66
8.2.130.0080.00026.16
8.2.120.0080.00019.61
8.2.110.0050.00519.21
8.2.100.0070.00418.03
8.2.90.0030.00519.17
8.2.80.0030.00617.97
8.2.70.0000.00817.75
8.2.60.0000.00818.03
8.2.50.0040.00418.07
8.2.40.0060.00318.16
8.2.30.0080.00018.09
8.2.20.0040.00417.79
8.2.10.0050.00217.86
8.2.00.0080.00018.04
8.1.280.0130.00725.92
8.1.270.0040.00422.14
8.1.260.0050.00326.35
8.1.250.0060.00328.09
8.1.240.0100.00022.17
8.1.230.0080.00319.18
8.1.220.0000.00817.78
8.1.210.0060.00318.77
8.1.200.0030.00717.47
8.1.190.0040.00417.43
8.1.180.0040.00418.92
8.1.170.0040.00418.90
8.1.160.0000.00722.24
8.1.150.0000.00818.92
8.1.140.0080.00317.55
8.1.130.0030.00317.83
8.1.120.0030.00317.62
8.1.110.0000.00817.61
8.1.100.0040.00417.64
8.1.90.0040.00417.68
8.1.80.0000.00717.62
8.1.70.0040.00417.65
8.1.60.0090.00017.82
8.1.50.0030.00517.60
8.1.40.0000.00817.63
8.1.30.0000.00817.78
8.1.20.0000.00817.94
8.1.10.0040.00417.65
8.1.00.0030.00517.68
8.0.300.0060.00318.77
8.0.290.0000.00917.30
8.0.280.0040.00418.57
8.0.270.0000.00717.34
8.0.260.0070.00017.06
8.0.250.0070.00017.15
8.0.240.0000.00717.23
8.0.230.0000.00717.11
8.0.220.0040.00417.14
8.0.210.0070.00017.12
8.0.200.0030.00317.17
8.0.190.0080.00017.12
8.0.180.0070.00017.14
8.0.170.0000.00817.19
8.0.160.0000.00717.20
8.0.150.0000.00717.11
8.0.140.0050.00317.00
8.0.130.0000.00613.60
8.0.120.0000.00817.01
8.0.110.0080.00017.15
8.0.100.0080.00017.04
8.0.90.0060.00316.95
8.0.80.0150.00017.08
8.0.70.0040.00416.98
8.0.60.0000.00717.11
8.0.50.0080.00017.18
8.0.30.0100.01017.16
8.0.20.0090.01317.40
8.0.10.0040.00417.21
8.0.00.0090.01016.88
7.4.330.0030.00315.11
7.4.320.0000.00616.79
7.4.300.0030.00316.66
7.4.290.0000.00716.89
7.4.280.0000.00916.88
7.4.270.0030.00316.76
7.4.260.0070.00016.75
7.4.250.0080.00016.81
7.4.240.0040.00416.75
7.4.230.0070.00016.96
7.4.220.0120.00916.80
7.4.210.0080.00816.83
7.4.200.0040.00416.86
7.4.190.0030.00316.93
7.4.160.0040.01216.81
7.4.150.0000.01717.40
7.4.140.0100.01117.86
7.4.130.0080.01016.65
7.4.120.0090.01116.74
7.4.110.0130.00716.79
7.4.100.0110.00716.84
7.4.90.0120.00816.78
7.4.80.0000.01719.39
7.4.70.0070.01416.75
7.4.60.0090.01216.88
7.4.50.0020.00216.66
7.4.40.0000.01522.77
7.4.30.0060.01216.93
7.4.00.0070.00715.37
7.3.330.0050.00013.64
7.3.320.0060.00013.55
7.3.310.0000.00716.61
7.3.300.0030.00316.61
7.3.290.0060.01216.62
7.3.280.0120.00716.61
7.3.270.0090.00917.40
7.3.260.0090.01616.82
7.3.250.0100.00716.63
7.3.240.0060.01216.73
7.3.230.0060.01216.79
7.3.210.0060.01016.71
7.3.200.0160.00619.39
7.3.190.0060.01516.67
7.3.180.0060.00916.97
7.3.170.0110.00616.70
7.3.160.0060.01016.81
7.3.120.0070.01114.97
7.2.330.0090.01216.79
7.2.320.0120.00616.74
7.2.310.0140.00316.87
7.2.300.0120.00916.77
7.2.290.0110.00716.85
7.2.60.0090.01016.71
7.2.00.0030.00919.54
7.1.200.0060.00616.02
7.1.100.0060.00917.90
7.1.70.0060.00617.55
7.1.60.0070.01819.82
7.1.50.0110.01117.22
7.1.00.0070.09022.34
7.0.200.0000.00916.95
7.0.140.0030.07322.16
7.0.60.0070.09019.99
7.0.50.0100.07717.91
7.0.40.0070.09020.13
7.0.30.0370.07720.28
7.0.20.0230.07720.25
7.0.10.0270.06720.16
7.0.00.0070.04020.25
5.6.280.0100.06721.04
5.6.210.0070.08320.55
5.6.200.0200.07318.28
5.6.190.0100.07320.46
5.6.180.3330.04020.63
5.6.170.0170.04320.57
5.6.160.0070.04320.71
5.6.150.0100.05318.18
5.6.140.0030.07318.21
5.6.130.0030.07718.18
5.6.120.0130.08321.04
5.6.110.0000.07321.00
5.6.100.0070.05021.13
5.6.90.0130.07320.99
5.6.80.0100.08020.44
5.6.70.4370.03720.29
5.5.350.0070.06020.42
5.5.340.0030.04717.98
5.5.330.0100.08020.29
5.5.320.0400.05320.57
5.5.310.0200.07720.38
5.5.300.0030.08718.02
5.5.290.0130.07317.97
5.5.280.0130.07720.79
5.5.270.0200.07020.99
5.5.260.0070.08720.70
5.5.250.0270.06720.71
5.5.240.0070.06720.28
5.4.450.0800.04719.17
5.4.440.0630.06719.43
5.4.430.0630.06719.16
5.4.420.0700.05719.60
5.4.410.0870.05719.45
5.4.400.0970.05319.11
5.4.390.0800.05719.15
5.4.380.0230.05018.78
5.4.370.0270.05018.73
5.4.360.0200.04318.74
5.4.350.0080.03512.03
5.4.340.0080.03712.03
5.4.320.0060.03712.52
5.4.310.0100.04412.52
5.4.300.0070.04212.52
5.4.290.0070.04612.52
5.4.280.0050.03712.42
5.4.270.0110.03512.42
5.4.260.0070.05318.78
5.4.250.0030.05318.92
5.4.240.0070.05018.73
5.4.230.0070.07018.93
5.4.220.0000.06018.64
5.4.210.0100.05318.98
5.4.200.0100.04718.61
5.4.190.0100.05019.00
5.4.180.0100.05018.93
5.4.170.0100.05018.93
5.4.160.0000.06018.93
5.4.150.0030.07718.72
5.4.140.0030.08016.38
5.4.130.0070.04716.37
5.4.120.0100.04316.56
5.4.110.0000.05716.46
5.4.100.0200.03716.50
5.4.90.0100.04716.55
5.4.80.0070.04716.58
5.4.70.0100.04316.44
5.4.60.0070.04716.34
5.4.50.0030.05016.58
5.4.40.0030.05016.46
5.4.30.0070.05016.61
5.4.20.0170.04016.41
5.4.10.0100.06316.41
5.4.00.0200.05715.77
5.3.290.0060.05512.80
5.3.280.0100.04714.65
5.3.270.0070.05314.75
5.3.260.0030.05714.75
5.3.250.0100.04714.62
5.3.240.0100.07014.67
5.3.230.0070.05014.81
5.3.220.0100.05314.64
5.3.210.0100.05014.70
5.3.200.0100.04714.63
5.3.190.0030.06314.60
5.3.180.0100.05014.64
5.3.170.0130.04314.77
5.3.160.0000.05314.64
5.3.150.0030.05314.77
5.3.140.0070.06014.53
5.3.130.0030.05314.57
5.3.120.0030.05714.52
5.3.110.0030.05714.61
5.3.100.0070.05014.19
5.3.90.0130.04314.09
5.3.80.0070.05014.08
5.3.70.0070.04714.00
5.3.60.0030.06014.18
5.3.50.0070.04713.97
5.3.40.0030.07013.98
5.3.30.0170.06014.11
5.3.20.0070.05713.71
5.3.10.0070.04713.71
5.3.00.0070.05713.66
5.2.170.0000.04711.02
5.2.160.0100.04711.12
5.2.150.0070.05311.14
5.2.140.0100.03310.89
5.2.130.0030.04011.22
5.2.120.0030.04010.93
5.2.110.0070.04310.93
5.2.100.0070.05310.83
5.2.90.0100.03311.01
5.2.80.0130.03311.17
5.2.70.0070.03710.97
5.2.60.0070.03711.02
5.2.50.0030.05711.00
5.2.40.0070.04710.97
5.2.30.0030.04011.09
5.2.20.0130.03011.08
5.2.10.0030.05710.91
5.2.00.0070.03710.70
5.1.60.0070.03310.20
5.1.50.0070.0479.88
5.1.40.0000.03710.04
5.1.30.0070.03710.17
5.1.20.0070.04310.38
5.1.10.0000.05010.23
5.1.00.0100.04710.18
5.0.50.0000.0308.57
5.0.40.0030.0378.41
5.0.30.0070.0408.24
5.0.20.0000.0278.21
5.0.10.0030.0378.18
5.0.00.0030.0438.36
4.4.90.0070.0236.70
4.4.80.0000.0276.70
4.4.70.0000.0236.70
4.4.60.0030.0236.70
4.4.50.0030.0206.70
4.4.40.0000.0336.70
4.4.30.0030.0176.70
4.4.20.0030.0306.70
4.4.10.0030.0206.70
4.4.00.0000.0376.70
4.3.110.0070.0176.70
4.3.100.0070.0206.70
4.3.90.0030.0276.70
4.3.80.0030.0336.70
4.3.70.0030.0236.70
4.3.60.0030.0206.70
4.3.50.0000.0236.70
4.3.40.0000.0306.70
4.3.30.0070.0176.70
4.3.20.0000.0236.70
4.3.10.0030.0276.70
4.3.00.0070.0307.04

preferences:
44.5 ms | 401 KiB | 5 Q