3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace Aydin; class Directory { public $dir = ''; public $parts = []; } class Vhost { public $directories = []; } $vhost =' <Directory "/srv/httpd/htdocs/mydomain.com"> Options Indexes FollowSymLinks AllowOverride All Order deny,allow Allow from 127.0.0.1 Allow from xxx.xxx.xxx.xxx Allow from xxx.xxx.xxx.xxx Deny from all </Directory> <Directory "/srv/httpd/htdocs/myseconddomain"> Options Indexes FollowSymLinks AllowOverride All Order deny,allow Allow from 127.0.0.1 Allow from xxx.xxx.xxx.xxx Allow from xxx.xxx.xxx.xxx Deny from all </Directory> '; $matches = []; $directory = preg_match_all('/<Directory "(.*")>([\s\S]*?)<\/Directory>/', $vhost, $matches, PREG_SET_ORDER); $vhost = new Vhost; foreach ($matches as $match) { $dir = new Directory; $dir->dir = $match[1]; echo "Directory: " . $match[1] . "\n"; $lines = explode($match[2], "\n"); foreach ($lines as $line) { $parts = preg_split('/\s+/', $line); $dir->parts = $parts; } $vhost->directories[] = $dir; } //var_dump($matches);

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.00619.02
8.3.30.0110.00419.05
8.3.20.0000.00820.35
8.3.10.0000.00820.64
8.3.00.0080.00019.51
8.2.170.0040.01222.96
8.2.160.0100.00319.20
8.2.150.0080.00024.18
8.2.140.0030.00524.66
8.2.130.0030.00626.16
8.2.120.0080.00022.18
8.2.110.0100.00022.38
8.2.100.0040.00717.97
8.2.90.0050.00319.26
8.2.80.0000.00917.97
8.2.70.0030.00617.88
8.2.60.0000.00818.05
8.2.50.0040.00418.07
8.2.40.0030.00618.22
8.2.30.0000.00819.25
8.2.20.0000.00817.95
8.2.10.0000.00718.20
8.2.00.0080.00017.94
8.1.270.0100.00023.96
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0060.00323.92
8.1.230.0110.00019.22
8.1.220.0000.00817.78
8.1.210.0030.00518.77
8.1.200.0000.00817.35
8.1.190.0000.00817.48
8.1.180.0030.00618.10
8.1.170.0050.00318.68
8.1.160.0070.00021.95
8.1.150.0040.00418.98
8.1.140.0070.00017.59
8.1.130.0030.00317.85
8.1.120.0000.00717.66
8.1.110.0000.00717.48
8.1.100.0000.00717.49
8.1.90.0070.00017.59
8.1.80.0070.00017.48
8.1.70.0030.00317.60
8.1.60.0030.00517.66
8.1.50.0030.00517.57
8.1.40.0060.00317.66
8.1.30.0050.00317.81
8.1.20.0030.00517.86
8.1.10.0040.00417.72
8.1.00.0000.00817.58
8.0.300.0000.00918.77
8.0.290.0000.00716.88
8.0.280.0000.00718.51
8.0.270.0040.00417.28
8.0.260.0000.00717.14
8.0.250.0000.00717.11
8.0.240.0060.00017.09
8.0.230.0070.00017.04
8.0.220.0030.00317.04
8.0.210.0040.00417.08
8.0.200.0060.00317.09
8.0.190.0060.00317.03
8.0.180.0040.00417.04
8.0.170.0040.00416.95
8.0.160.0070.00017.04
8.0.150.0070.00017.02
8.0.140.0080.00016.99
8.0.130.0030.00313.54
8.0.120.0000.00917.03
8.0.110.0040.00416.97
8.0.100.0000.00716.84
8.0.90.0040.00416.93
8.0.80.0100.01017.05
8.0.70.0000.00717.04
8.0.60.0040.00416.93
8.0.50.0070.00016.85
8.0.30.0100.01317.08
8.0.20.0080.01217.41
8.0.10.0050.00217.22
8.0.00.0090.01116.84
7.4.330.0000.00515.10
7.4.320.0060.00016.78
7.4.300.0000.00616.77
7.4.290.0040.00416.84
7.4.280.0000.00816.78
7.4.270.0000.00716.80
7.4.260.0050.00316.69
7.4.250.0050.00216.76
7.4.240.0030.00516.76
7.4.230.0000.00716.56
7.4.220.0140.00716.71
7.4.210.0030.01016.77
7.4.200.0030.00716.80
7.4.160.0120.00416.66
7.4.150.0090.00917.40
7.4.140.0140.00517.86
7.4.130.0140.00516.68
7.4.120.0100.00816.66
7.4.110.0090.01516.75
7.4.100.0090.00916.62
7.4.90.0210.00416.59
7.4.80.0070.01119.04
7.4.70.0030.01416.94
7.4.60.0100.00616.71
7.4.50.0030.00516.54
7.4.40.0110.00516.82
7.4.30.0100.00716.77
7.4.00.0070.00715.30
7.3.330.0050.00013.58
7.3.320.0060.00013.58
7.3.310.0040.00416.55
7.3.300.0000.00716.43
7.3.290.0120.00316.54
7.3.280.0060.00916.47
7.3.270.0150.01117.40
7.3.260.0110.00716.56
7.3.250.0100.00916.67
7.3.240.0110.00716.73
7.3.230.0070.01016.67
7.3.210.0140.00416.89
7.3.200.0030.01319.39
7.3.190.0030.01316.85
7.3.180.0080.00816.77
7.3.170.0170.00016.83
7.3.160.0060.01016.67
7.3.10.0130.01016.68
7.3.00.0110.00816.79
7.2.330.0070.01016.87
7.2.320.0150.00416.96
7.2.310.0090.00916.77
7.2.300.0050.01116.69
7.2.290.0070.01516.85
7.2.130.0090.00916.90
7.2.120.0090.00917.12
7.2.110.0220.01116.74
7.2.100.0060.01217.10
7.2.90.0180.00717.06
7.2.80.0100.00617.11
7.2.70.0080.00517.11
7.2.60.0150.00417.13
7.2.50.0140.00717.01
7.2.40.0060.00717.19
7.2.30.0040.01517.14
7.2.20.0060.00917.14
7.2.10.0110.00716.88
7.2.00.0090.00817.91
7.1.250.0190.00715.86
7.1.240.0000.00915.84
7.1.230.0110.00415.96
7.1.220.0000.01316.20
7.1.210.0070.00716.06
7.1.200.0090.00416.07
7.1.190.0090.00615.93
7.1.180.0100.00616.08
7.1.170.0070.00716.13
7.1.160.0090.00915.99
7.1.150.0110.00415.89
7.1.140.0040.01215.98
7.1.130.0070.00716.11
7.1.120.0100.00315.94
7.1.110.0040.00815.75
7.1.100.0090.00517.34
7.1.90.0110.00416.14
7.1.80.0110.00416.11
7.1.70.0050.00616.71
7.1.60.0060.01317.66
7.1.50.0090.00916.66
7.1.40.0070.00715.97
7.1.30.0060.01016.11
7.1.20.0100.00416.01
7.1.10.0090.00315.95
7.1.00.0070.03919.20
7.0.330.0100.00715.40
7.0.320.0030.00615.36
7.0.310.0070.01015.51
7.0.300.0030.01015.39
7.0.290.0090.00315.41
7.0.280.0050.00515.19
7.0.270.0040.00415.69
7.0.260.0000.01415.38
7.0.250.0070.00715.73
7.0.240.0070.00415.50
7.0.230.0130.00315.52
7.0.220.0090.00615.75
7.0.210.0060.00615.49
7.0.200.0030.01016.23
7.0.190.0040.00815.68
7.0.180.0040.01115.32
7.0.170.0030.01015.75
7.0.160.0000.01415.60
7.0.150.0000.01315.65
7.0.140.0010.04318.83
7.0.130.0060.00315.50
7.0.120.0040.00815.71
7.0.110.0000.00715.43
7.0.100.0080.00815.63
7.0.90.0070.00315.78
7.0.80.0000.00815.61
7.0.70.0030.00715.50
7.0.60.0020.04817.88
7.0.50.0030.02516.77
7.0.40.0080.02216.97
7.0.30.0200.04116.96
7.0.20.0180.04217.10
7.0.10.0080.03816.92
7.0.00.0070.02916.96
5.6.380.0120.00414.83
5.6.370.0040.00714.39
5.6.360.0030.01014.67
5.6.350.0000.00914.60
5.6.340.0030.01014.55
5.6.330.0090.00614.80
5.6.320.0040.01214.46
5.6.310.0090.00614.57
5.6.300.0110.00414.63
5.6.290.0000.01714.79
5.6.280.0070.04017.79
5.6.270.0040.00814.46
5.6.260.0110.00014.34
5.6.250.0070.00314.59
5.6.240.0000.01414.31
5.6.230.0000.01314.63
5.6.220.0040.00414.47
5.6.210.0160.03817.53
5.6.200.0030.04516.15
5.6.190.0030.02617.48
5.6.180.0280.02317.63
5.6.170.0220.02817.40
5.6.160.0060.03117.49
5.6.150.0100.04016.21
5.6.140.0050.03816.29
5.6.130.0030.03216.44
5.6.120.0060.02517.65
5.6.110.0060.05117.75
5.6.100.0080.04317.81
5.6.90.0090.04017.63
5.6.80.0090.04217.30
5.6.70.0000.01314.11
5.6.60.0080.00814.25
5.6.50.0000.01614.06
5.6.40.0100.00014.59
5.6.30.0070.00714.19
5.6.20.0060.00614.27
5.6.10.0070.00714.46
5.6.00.0030.00714.25
5.5.380.0040.00411.18
5.5.370.0090.00311.18
5.5.360.0070.00011.24
5.5.350.0120.04415.79
5.5.340.0060.04514.68
5.5.330.0020.02715.86
5.5.320.0030.04815.90
5.5.310.0130.03615.90
5.5.300.0050.04314.60
5.5.290.0070.02714.59
5.5.280.0110.04216.16
5.5.270.0070.04216.00
5.5.260.0070.03816.09
5.5.250.0050.03816.04
5.5.240.0120.04115.85
5.5.230.0040.00711.47
5.5.220.0000.01011.18
5.5.210.0040.00411.37
5.5.200.0060.00611.60
5.5.190.0000.00911.29
5.5.180.0000.00811.22
5.5.170.0090.00011.37
5.5.160.0000.01111.41
5.5.150.0060.00611.36
5.5.140.0000.00811.46
5.5.130.0090.00311.18
5.5.120.0040.00711.24
5.5.110.0000.00811.35
5.5.100.0040.00711.48
5.5.90.0070.00011.18
5.5.80.0060.00611.22
5.5.70.0080.00311.22
5.5.60.0040.00411.25
5.5.50.0000.01311.20
5.5.40.0040.00711.44
5.5.30.0000.01211.42
5.5.20.0030.00911.18
5.5.10.0060.00311.18
5.5.00.0070.00711.18
5.4.450.0100.02515.36
5.4.440.0520.03215.62
5.4.430.0370.03315.37
5.4.420.0330.00315.36
5.4.410.0320.00515.29
5.4.400.0330.00415.05
5.4.390.0340.00215.20
5.4.380.0160.03115.06
5.4.370.0250.02714.99
5.4.360.0160.02915.03
5.4.350.0200.02714.94
5.4.340.0270.03714.92
5.4.330.0070.00011.34
5.4.320.0080.01911.84
5.4.310.0030.02311.95
5.4.300.0040.02011.89
5.4.290.0050.02311.88
5.4.280.0070.01911.79
5.4.270.0070.01911.79
5.4.260.0020.02411.84
5.4.250.0040.02611.91
5.4.240.0040.02011.79
5.4.230.0040.02211.84
5.4.220.0030.02211.87
5.4.210.0010.02211.81
5.4.200.0040.02111.88
5.4.190.0040.02211.81
5.4.180.0040.02211.78
5.4.170.0060.01911.82
5.4.160.0040.02211.81
5.4.150.0020.02311.83
5.4.140.0030.02111.68
5.4.130.0040.01911.72
5.4.120.0110.01611.65
5.4.110.0070.01911.68
5.4.100.0030.02311.77
5.4.90.0030.02311.67
5.4.80.0040.02411.66
5.4.70.0070.01811.59
5.4.60.0020.02211.72
5.4.50.0050.01911.62
5.4.40.0060.02011.74
5.4.30.0050.02111.75
5.4.20.0040.02011.74
5.4.10.0040.02111.59
5.4.00.0040.02211.39
5.3.290.0040.02511.99
5.3.280.0050.02611.94
5.3.270.0080.02311.95
5.3.260.0060.02111.95
5.3.250.0040.02511.95
5.3.240.0080.01811.95
5.3.230.0060.02011.94
5.3.220.0060.01911.93
5.3.210.0050.02211.93
5.3.200.0060.02011.93
5.3.190.0060.02011.93
5.3.180.0040.01911.93
5.3.170.0040.02311.92
5.3.160.0040.02111.92
5.3.150.0070.01811.92
5.3.140.0050.01911.92
5.3.130.0020.02411.92
5.3.120.0050.02111.92
5.3.110.0040.02211.92
5.3.100.0050.01811.65
5.3.90.0020.02311.64
5.3.80.0020.02311.63
5.3.70.0060.02011.63
5.3.60.0020.02211.63
5.3.50.0040.02111.60
5.3.40.0040.02211.60
5.3.30.0030.02011.59
5.3.20.0040.02011.47
5.3.10.0050.02011.45
5.3.00.0050.02011.45
5.2.170.0060.01410.18
5.2.160.0020.01810.18
5.2.150.0060.01710.18
5.2.140.0010.02010.18
5.2.130.0040.01810.16
5.2.120.0020.01910.16
5.2.110.0040.01710.16
5.2.100.0020.01610.16
5.2.90.0040.01510.16
5.2.80.0040.01810.16
5.2.70.0030.01710.16
5.2.60.0030.01810.13
5.2.50.0030.01910.12
5.2.40.0040.01710.11
5.2.30.0030.02110.10
5.2.20.0050.01710.09
5.2.10.0030.02110.05
5.2.00.0070.0149.98
5.1.60.0030.0159.62
5.1.50.0090.0159.62
5.1.40.0060.0149.61
5.1.30.0020.0179.79
5.1.20.0050.0169.80
5.1.10.0010.0179.66
5.1.00.0040.0149.66
5.0.50.0030.0128.90
5.0.40.0040.0118.83
5.0.30.0020.0208.73
5.0.20.0020.0128.72
5.0.10.0030.0138.71
5.0.00.0040.0158.71
4.4.90.0020.0097.98
4.4.80.0020.0097.97
4.4.70.0010.0117.97
4.4.60.0030.0077.97
4.4.50.0010.0117.97
4.4.40.0010.0167.94
4.4.30.0050.0077.97
4.4.20.0030.0098.01
4.4.10.0010.0128.01
4.4.00.0060.0127.97
4.3.110.0030.0097.92
4.3.100.0010.0147.92
4.3.90.0030.0097.91
4.3.80.0020.0167.88
4.3.70.0040.0087.90
4.3.60.0040.0077.90
4.3.50.0010.0127.90
4.3.40.0020.0147.86
4.3.30.0020.0127.23
4.3.20.0010.0157.21
4.3.10.0010.0117.20
4.3.00.0050.00613.39

preferences:
43.81 ms | 400 KiB | 5 Q