3v4l.org

run code in 300+ PHP versions simultaneously
<?PHP $paths = [ '/cars$', '.*/cars$', '^cars/.*/', '/trucks$', '.*/trucks$' ]; $url = 'some-site.com/cars'; $res = array_filter($paths, function ($v) USE ($url) { return preg_match('~'.$v.'~', $url); }); echo count($res)." patterns matched:\n"; print_r($res); ?>

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.130.0050.00318.50
8.3.120.0060.00318.78
8.3.110.0000.00920.94
8.3.100.0060.00924.06
8.3.90.0040.00826.77
8.3.80.0030.00718.31
8.3.70.0040.01116.58
8.3.60.0120.00318.49
8.3.50.0080.01217.43
8.3.40.0130.01019.01
8.3.30.0120.00318.66
8.3.20.0030.00621.93
8.3.10.0050.00318.98
8.3.00.0050.00321.86
8.2.250.0130.00716.69
8.2.240.0040.00417.14
8.2.230.0000.01022.58
8.2.220.0120.00437.54
8.2.210.0000.00826.77
8.2.200.0090.00016.75
8.2.190.0100.01016.63
8.2.180.0070.01125.92
8.2.170.0000.01522.96
8.2.160.0070.00720.38
8.2.150.0040.00824.18
8.2.140.0060.00324.66
8.2.130.0040.00426.16
8.2.120.0040.00419.82
8.2.110.0100.00022.44
8.2.100.0060.00618.03
8.2.90.0050.00322.28
8.2.80.0060.00317.97
8.2.70.0000.00817.93
8.2.60.0110.00217.85
8.2.50.0100.00318.28
8.2.40.0050.00818.48
8.2.30.0120.00118.27
8.2.20.0080.00417.79
8.2.10.0100.00318.32
8.2.00.0040.00718.41
8.1.300.0120.00318.10
8.1.290.0060.00630.84
8.1.280.0110.00325.92
8.1.270.0100.00020.39
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0000.00920.77
8.1.230.0120.00019.22
8.1.220.0070.00817.53
8.1.210.0000.00818.90
8.1.200.0060.00617.59
8.1.190.0050.01017.47
8.1.180.0080.00617.61
8.1.170.0110.00117.96
8.1.160.0030.00918.06
8.1.150.0090.00418.11
8.1.140.0080.00418.20
8.1.130.0090.00318.45
8.1.120.0080.00517.54
8.1.110.0090.00317.37
8.1.100.0070.00517.43
8.1.90.0080.00417.43
8.1.80.0080.00617.48
8.1.70.0120.00117.58
8.1.60.0080.00717.61
8.1.50.0110.00417.54
8.1.40.0110.00517.57
8.1.30.0100.00617.61
8.1.20.0100.00517.65
8.1.10.0100.00617.49
8.1.00.0110.00517.49
8.0.300.0000.00819.98
8.0.290.0090.00016.88
8.0.280.0080.00317.61
8.0.270.0100.00217.04
8.0.260.0080.00316.92
8.0.250.0020.00916.90
8.0.240.0060.00616.83
8.0.230.0080.00416.85
8.0.220.0080.00316.81
8.0.210.0100.00516.79
8.0.200.0060.00616.85
8.0.190.0090.00416.67
8.0.180.0090.00416.69
8.0.170.0100.00216.89
8.0.160.0090.00516.95
8.0.150.0080.00816.75
8.0.140.0090.00416.79
8.0.130.0070.00415.49
8.0.120.0080.00516.82
8.0.110.0060.00616.79
8.0.100.0070.00516.88
8.0.90.0070.00416.92
8.0.80.0080.00816.89
8.0.70.0080.00416.87
8.0.60.0080.00316.76
8.0.50.0060.00416.77
8.0.30.0100.00516.99
8.0.20.0070.00716.85
8.0.10.0070.00416.98
8.0.00.0090.00716.92
7.4.330.0080.00116.03
7.4.320.0080.00416.69
7.4.300.0060.00416.62
7.4.290.0060.00616.65
7.4.280.0070.00416.62
7.4.270.0110.00216.55
7.4.260.0070.00516.50
7.4.250.0080.00416.60
7.4.240.0100.00316.61
7.4.230.0050.00616.69
7.4.220.0060.00516.68
7.4.210.0060.00616.66
7.4.200.0040.00716.71
7.4.190.0080.00416.63
7.4.180.0080.00416.72
7.4.160.0100.00516.62
7.4.150.0070.00516.59
7.4.140.0070.00616.91
7.4.130.0080.00616.69
7.4.120.0090.00516.67
7.4.110.0090.00516.66
7.4.100.0070.00616.63
7.4.90.0080.00516.60
7.4.80.0090.00617.24
7.4.70.0090.00516.65
7.4.60.0050.00816.57
7.4.50.0080.00516.38
7.4.40.0090.00416.58
7.4.30.0090.00516.51
7.4.20.0080.00516.49
7.4.10.0090.00216.52
7.4.00.0080.00415.97
7.3.330.0090.00415.40
7.3.320.0070.00615.42
7.3.310.0080.00516.49
7.3.300.0070.00416.43
7.3.290.0120.00216.43
7.3.280.0080.00816.40
7.3.270.0030.00916.41
7.3.260.0110.00616.61
7.3.250.0080.00416.41
7.3.240.0080.00716.49
7.3.230.0090.00516.51
7.3.220.0080.00516.43
7.3.210.0100.00416.39
7.3.200.0100.00316.43
7.3.190.0090.00416.39
7.3.180.0090.00616.43
7.3.170.0060.00816.42
7.3.160.0100.00216.46
7.3.150.0100.00316.38
7.3.140.0050.00816.43
7.3.130.0080.00516.39
7.3.120.0060.00816.22
7.3.110.0060.00816.08
7.3.100.0070.00616.17
7.3.90.0070.00516.31
7.3.80.0080.00616.19
7.3.70.0070.00716.22
7.3.60.0060.00716.29
7.3.50.0090.00615.93
7.3.40.0070.00915.88
7.3.30.0100.00615.84
7.3.20.0200.00716.63
7.3.10.0090.00616.57
7.3.00.0080.00616.57
7.2.340.0080.00516.54
7.2.330.0050.01016.70
7.2.320.0090.00516.68
7.2.310.0090.00616.66
7.2.300.0080.00616.58
7.2.290.0080.00716.66
7.2.280.0100.00416.59
7.2.270.0110.00316.54
7.2.260.0080.00616.58
7.2.250.0060.00916.25
7.2.240.0100.00616.37
7.2.230.0100.00416.40
7.2.220.0050.00916.33
7.2.210.0050.00816.38
7.2.200.0100.00516.48
7.2.190.0100.00416.41
7.2.180.0100.00616.07
7.2.170.0100.00716.03
7.2.160.0110.00716.21
7.2.150.0090.00916.82
7.2.140.0130.00616.85
7.2.130.0110.00616.95
7.2.120.0100.00516.82
7.2.110.0100.01016.86
7.2.100.0110.00716.88
7.2.90.0130.00516.98
7.2.80.0100.00716.91
7.2.70.0090.00916.87
7.2.60.0130.00816.92
7.2.50.0150.00516.89
7.2.40.0120.00616.86
7.2.30.0180.00716.88
7.2.20.0100.00716.96
7.2.10.0120.00616.86
7.2.00.0070.00716.93
7.1.330.0080.00516.30
7.1.320.0060.00816.23
7.1.310.0150.00716.32
7.1.300.0090.00516.19
7.1.290.0070.00616.28
7.1.280.0100.00615.87
7.1.270.0120.00415.87
7.1.260.0100.00715.90
7.1.250.0100.00615.75
7.1.240.0110.00415.60
7.1.230.0100.00415.61
7.1.220.0100.00615.60
7.1.210.0110.00615.64
7.1.200.0140.00215.59
7.1.190.0120.00915.66
7.1.180.0100.00615.48
7.1.170.0130.00415.61
7.1.160.0130.00415.57
7.1.150.0130.00315.67
7.1.140.0090.00515.48
7.1.130.0120.00415.56
7.1.120.0130.00415.64
7.1.110.0160.00315.74
7.1.100.0130.00215.71
7.1.90.0150.00516.14
7.1.80.0100.00516.21
7.1.70.0160.00315.90
7.1.60.0160.00516.15
7.1.50.0150.00416.26
7.1.40.0110.00416.18
7.1.30.0160.00316.30
7.1.20.0080.00716.17
7.1.10.0110.00416.09
7.1.00.0110.00516.16

preferences:
29.24 ms | 403 KiB | 5 Q