3v4l.org

run code in 300+ PHP versions simultaneously
<?php $strings = [ "This is a (first) test with the first hit", "This is a (first] test with the first hit" ]; foreach ($strings as $str) { preg_match( '/(?:\(first\)|\[first]|{first})(*SKIP)(*FAIL)|\bfirst\b/', $str, $matches, PREG_OFFSET_CAPTURE); print_r($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.4.130.0100.01019.00
8.4.120.0120.00824.07
8.4.110.0140.00718.70
8.4.100.0090.00820.82
8.4.90.0110.00820.48
8.4.80.0060.00318.62
8.4.70.0090.00718.37
8.4.60.0110.01018.82
8.4.50.0090.01119.63
8.4.40.0190.00018.52
8.4.30.0100.01018.68
8.4.20.0090.00919.07
8.4.10.0080.00022.42
8.3.250.0110.00818.73
8.3.240.0090.00818.78
8.3.230.0090.00216.56
8.3.220.0060.00219.09
8.3.210.0080.00716.85
8.3.200.0060.00316.82
8.3.190.0110.00717.09
8.3.180.0090.00616.43
8.3.170.0090.00019.19
8.3.160.0120.00918.41
8.3.150.0070.01120.79
8.3.140.0070.00316.53
8.3.130.0080.00018.38
8.3.120.0060.00318.98
8.3.110.0060.00320.94
8.3.100.0000.00816.68
8.3.90.0110.00026.77
8.3.80.0030.00616.75
8.3.70.0040.01116.75
8.3.60.0160.00618.43
8.3.50.0110.00823.66
8.3.40.0040.01118.76
8.3.30.0070.01118.91
8.3.20.0060.00324.18
8.3.10.0030.00524.66
8.3.00.0040.00426.16
8.2.290.0090.01018.63
8.2.280.0110.00518.33
8.2.270.0090.00917.41
8.2.260.0040.00418.62
8.2.250.0130.00716.75
8.2.240.0040.00417.08
8.2.230.0100.00022.58
8.2.220.0060.00324.06
8.2.210.0000.01526.77
8.2.200.0040.00716.88
8.2.190.0040.01117.00
8.2.180.0100.01025.92
8.2.170.0210.00022.96
8.2.160.0030.01022.96
8.2.150.0000.00825.66
8.2.140.0040.00424.66
8.2.130.0060.00326.16
8.2.120.0040.00426.35
8.2.110.0100.00019.21
8.2.100.0080.00419.23
8.2.90.0040.00418.16
8.2.80.0040.00420.23
8.2.70.0040.00417.50
8.2.60.0040.00417.75
8.2.50.0000.00817.88
8.2.40.0030.00519.60
8.2.30.0000.00718.06
8.2.20.0030.00618.04
8.2.10.0040.00419.18
8.2.00.0040.00419.33
8.1.330.0090.00918.60
8.1.320.0020.00618.01
8.1.310.0000.00816.79
8.1.300.0150.00318.08
8.1.290.0060.00330.84
8.1.280.0030.01325.92
8.1.270.0090.00023.99
8.1.260.0030.00528.09
8.1.250.0000.00728.09
8.1.240.0110.00021.72
8.1.230.0120.00020.89
8.1.220.0080.00017.74
8.1.210.0050.00318.89
8.1.200.0070.00417.48
8.1.190.0080.00017.35
8.1.180.0000.00818.10
8.1.170.0040.00417.62
8.1.160.0070.00018.92
8.1.150.0000.00718.93
8.1.140.0040.00418.97
8.1.130.0080.00020.09
8.1.120.0000.00717.51
8.1.110.0040.00417.52
8.1.100.0070.00017.57
8.1.90.0000.00717.61
8.1.80.0030.00617.68
8.1.70.0000.00717.51
8.1.60.0050.00317.73
8.1.50.0030.00517.64
8.1.40.0060.00317.68
8.1.30.0030.00617.82
8.1.20.0040.00417.80
8.1.10.0000.00817.63
8.1.00.0040.00417.52
8.0.300.0000.00820.15
8.0.290.0080.00016.88
8.0.280.0000.00718.47
8.0.270.0050.00318.16
8.0.260.0070.00020.27
8.0.250.0030.00317.17
8.0.240.0030.00317.13
8.0.230.0000.00717.07
8.0.220.0000.00717.09
8.0.210.0000.00716.95
8.0.200.0040.00417.15
8.0.190.0040.00417.12
8.0.180.0040.00417.07
8.0.170.0090.00016.95
8.0.160.0030.00617.01
8.0.150.0040.00717.00
8.0.140.0000.00717.06
8.0.130.0060.00013.56
8.0.120.0030.00517.01
8.0.110.0040.00416.92
8.0.100.0000.00817.12
8.0.90.0040.00416.92
8.0.80.0070.01017.05
8.0.70.0000.00717.08
8.0.60.0000.00817.16
8.0.50.0040.00417.04
8.0.30.0030.01417.14
8.0.20.0130.00517.19
8.0.10.0040.00417.02
8.0.00.0120.01216.85
7.4.330.0000.00515.55
7.4.320.0030.00316.88
7.4.300.0030.00316.65
7.4.290.0040.00416.62
7.4.280.0000.00716.84
7.4.270.0070.00016.88
7.4.260.0000.00613.42
7.4.250.0070.00016.71
7.4.240.0000.00816.84
7.4.230.0080.00016.94
7.4.220.0040.00416.77
7.4.210.0090.00416.83
7.4.200.0040.00416.85
7.4.130.0110.00516.70
7.4.120.0100.01016.75
7.4.110.0150.00316.54
7.4.100.0170.00016.62
7.4.90.0140.00316.82
7.4.80.0100.00719.39
7.4.70.0090.00916.66
7.4.60.0090.00616.93
7.4.50.0120.00716.70
7.4.40.0150.00316.63
7.4.30.0110.00716.56
7.4.20.0090.00916.64
7.4.10.0040.01416.69
7.4.00.0040.01416.68
7.3.330.0070.00016.29
7.3.320.0000.00513.33
7.3.310.0030.00316.28
7.3.300.0030.00316.31
7.3.290.0100.00816.45
7.3.280.0100.00616.43
7.3.260.0100.01016.40
7.3.240.0060.01316.57
7.3.230.0040.01416.52
7.3.210.0040.01516.38
7.3.200.0110.00616.49
7.3.190.0100.00716.63
7.3.180.0100.00716.53
7.3.170.0200.00016.56
7.3.160.0080.01216.46
7.3.150.0170.00016.34
7.3.140.0100.00616.49
7.3.130.0060.01216.51
7.3.120.0030.01416.58
7.3.110.0110.00616.75
7.3.100.0160.00316.71
7.3.90.0140.00316.42
7.3.80.0140.00616.56
7.3.70.0040.01416.42
7.3.60.0130.00616.49
7.3.50.0130.00616.55
7.3.40.0100.01016.34
7.3.30.0160.00316.57
7.3.20.0030.01716.60
7.3.10.0100.01016.58
7.3.00.0090.00916.36
7.2.330.0060.01216.66
7.2.320.0100.00716.84
7.2.310.0170.00016.68
7.2.300.0100.01016.63
7.2.290.0110.00716.55
7.2.280.0100.00716.61
7.2.270.0100.01316.79
7.2.260.0090.00916.74
7.2.250.0150.00316.67
7.2.240.0060.01516.49
7.2.230.0140.00516.61
7.2.220.0160.01016.68
7.2.210.0070.01116.61
7.2.200.0060.01216.64
7.2.190.0100.01016.47
7.2.180.0140.00816.80
7.2.170.0070.01316.54
7.2.160.0170.00316.67
7.2.150.0140.00716.66
7.2.140.0260.00416.60
7.2.130.0190.00016.71
7.2.120.0110.00816.76
7.2.110.0110.01116.64
7.2.100.0190.00316.82
7.2.90.0120.00916.63
7.2.80.0030.01616.61
7.2.70.0060.01516.78
7.2.60.0140.00616.74
7.2.50.0080.01116.71
7.2.40.0120.00916.78
7.2.30.0130.00616.77
7.2.20.0130.01016.68
7.2.10.0060.01216.71
7.2.00.0060.01216.64

preferences:
29.39 ms | 403 KiB | 5 Q