3v4l.org

run code in 300+ PHP versions simultaneously
<?php $keywordRegex = '(?<key>-?mock)'; $valueRegex = '"(?<quoted>(?:[^"]|\\\")*)"|(?<unquoted>[^"\s]+)'; $regex = "/(?<=^|\\s){$keywordRegex}:\\s*{$valueRegex}/"; echo $regex, "\n\n"; $inputs = array( 'mock:"foo"', 'mock:""foo', 'mock:""foo""' ); foreach ( $inputs as $term ) { $matches = null; echo $term, "\n"; preg_match( $regex, $term, $matches ); 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.60.0070.00716.61
8.3.50.0140.00923.08
8.3.40.0040.01118.76
8.3.30.0090.00618.98
8.3.20.0040.00422.09
8.3.10.0080.00023.52
8.3.00.0050.00319.85
8.2.180.0070.01118.66
8.2.170.0110.00422.96
8.2.160.0140.00021.14
8.2.150.0050.00324.18
8.2.140.0060.00324.66
8.2.130.0080.00022.43
8.2.120.0030.00526.35
8.2.110.0000.00921.17
8.2.100.0090.00318.16
8.2.90.0080.00019.09
8.2.80.0030.00617.97
8.2.70.0000.00917.73
8.2.60.0080.00317.90
8.2.50.0060.00318.10
8.2.40.0000.00822.27
8.2.30.0030.00520.98
8.2.20.0040.00717.90
8.2.10.0000.00718.02
8.2.00.0070.00018.14
8.1.280.0110.00325.92
8.1.270.0040.00423.83
8.1.260.0040.00428.09
8.1.250.0080.00028.09
8.1.240.0090.00022.24
8.1.230.0090.00319.48
8.1.220.0050.00317.79
8.1.210.0030.00618.77
8.1.200.0030.00617.48
8.1.190.0000.00817.48
8.1.180.0080.00018.10
8.1.170.0000.00818.74
8.1.160.0040.00422.18
8.1.150.0080.00020.71
8.1.140.0000.00719.70
8.1.130.0000.00717.73
8.1.120.0040.00417.57
8.1.110.0000.00817.55
8.1.100.0000.00817.49
8.1.90.0060.00317.59
8.1.80.0000.00817.61
8.1.70.0030.00317.51
8.1.60.0000.00917.75
8.1.50.0060.00317.57
8.1.40.0030.00517.56
8.1.30.0000.00817.77
8.1.20.0060.00317.82
8.1.10.0040.00417.67
8.1.00.0080.00017.49
8.0.300.0070.00018.77
8.0.290.0000.00716.75
8.0.280.0000.00718.46
8.0.270.0070.00017.32
8.0.260.0000.00917.19
8.0.250.0000.00717.10
8.0.240.0000.00717.00
8.0.230.0080.00017.13
8.0.220.0000.00817.05
8.0.210.0070.00017.05
8.0.200.0070.00417.10
8.0.190.0000.00817.02
8.0.180.0040.00417.04
8.0.170.0000.00816.97
8.0.160.0020.00517.09
8.0.150.0070.00016.99
8.0.140.0050.00216.95
8.0.130.0030.00313.46
8.0.120.0000.00917.00
8.0.110.0050.00216.96
8.0.100.0040.00416.90
8.0.90.0040.00416.91
8.0.80.0090.00617.08
8.0.70.0040.00417.03
8.0.60.0000.00717.00
8.0.50.0030.00516.99
8.0.30.0080.01317.41
8.0.20.0120.00717.54
8.0.10.0030.00517.18
8.0.00.0170.00716.94
7.4.330.0020.00215.15
7.4.320.0060.00016.66
7.4.300.0030.00316.72
7.4.290.0060.00316.71
7.4.280.0040.00416.72
7.4.270.0040.00416.82
7.4.260.0080.00016.72
7.4.250.0070.00016.73
7.4.240.0000.00716.74
7.4.230.0080.00016.66
7.4.220.0030.01416.75
7.4.210.0100.00616.72
7.4.200.0050.00216.72
7.4.160.0120.00616.67
7.4.150.0040.01617.40
7.4.140.0170.01117.86
7.4.130.0080.00916.72
7.4.120.0090.01016.75
7.4.110.0100.01316.62
7.4.100.0110.00816.74
7.4.90.0060.01216.64
7.4.80.0090.00919.39
7.4.70.0120.00916.53
7.4.60.0200.00416.68
7.4.50.0060.00616.55
7.4.40.0090.01416.61
7.4.30.0090.00916.76
7.4.10.0060.01315.20
7.4.00.0070.01115.05
7.3.330.0050.00013.21
7.3.320.0050.00013.28
7.3.310.0000.00716.41
7.3.300.0000.00716.37
7.3.290.0030.00316.46
7.3.280.0100.01116.49
7.3.270.0030.01417.40
7.3.260.0140.00816.39
7.3.250.0100.01116.79
7.3.240.0170.00416.52
7.3.230.0100.01616.86
7.3.210.0080.00816.34
7.3.200.0030.01916.72
7.3.190.0100.00716.72
7.3.180.0170.00316.48
7.3.170.0090.00916.63
7.3.160.0100.01416.66
7.3.130.0160.00314.95
7.3.120.0040.01514.67
7.3.110.0070.01015.16
7.3.100.0030.01015.13
7.3.90.0060.00315.17
7.3.80.0070.00715.30
7.3.70.0030.00614.90
7.3.60.0030.01315.13
7.3.50.0060.00914.89
7.3.40.0120.00614.85
7.3.30.0110.00414.86
7.3.20.0040.01116.93
7.3.10.0050.01016.56
7.3.00.0060.00816.76
7.2.330.0030.01516.75
7.2.320.0130.00316.72
7.2.310.0140.00416.83
7.2.300.0120.00916.99
7.2.290.0080.01116.74
7.2.260.0030.01515.29
7.2.250.0030.01015.17
7.2.240.0060.01214.93
7.2.230.0040.01115.36
7.2.220.0070.00715.26
7.2.210.0060.00615.04
7.2.200.0070.01015.31
7.2.190.0040.00715.11
7.2.180.0080.00415.05
7.2.170.0030.00615.30
7.2.160.0030.01015.09
7.2.150.0090.00617.18
7.2.140.0150.00017.21
7.2.130.0070.00616.96
7.2.120.0030.01017.05
7.2.110.0080.00516.99
7.2.100.0080.00817.14
7.2.90.0050.00817.20
7.2.80.0060.00617.11
7.2.70.0030.01217.02
7.2.60.0030.01317.03
7.2.50.0060.00617.04
7.2.40.0030.01017.07
7.2.30.0080.00617.00
7.2.20.0050.01017.02
7.2.10.0050.00716.96
7.2.00.0070.00917.71
7.1.330.0090.00615.73
7.1.320.0120.00015.76
7.1.310.0070.00715.95
7.1.300.0120.00615.96
7.1.290.0120.00616.00
7.1.280.0030.00915.86
7.1.270.0100.00715.65
7.1.260.0060.00915.77
7.1.250.0070.00616.03
7.1.240.0060.00815.76
7.1.230.0090.00215.99
7.1.220.0060.00616.03
7.1.210.0070.00515.98
7.1.200.0040.00815.87
7.1.190.0080.00816.04
7.1.180.0050.01015.97
7.1.170.0050.00915.96
7.1.160.0070.00416.07
7.1.150.0060.00515.92
7.1.140.0070.00716.01
7.1.130.0050.00916.04
7.1.120.0070.00716.03
7.1.110.0090.00516.10
7.1.100.0050.00616.02
7.1.90.0060.00816.01
7.1.80.0100.00215.98
7.1.70.0060.00616.44
7.1.60.0070.00616.41
7.1.50.0070.00316.02
7.1.40.0020.01116.10
7.1.30.0050.00515.97
7.1.20.0060.00815.93
7.1.10.0060.00516.07
7.1.00.0090.02818.21
7.0.330.0080.00715.39
7.0.320.0080.00415.44
7.0.310.0050.00515.64
7.0.300.0100.00515.55
7.0.290.0050.00915.54
7.0.280.0090.00715.61
7.0.270.0020.01015.40
7.0.260.0070.00515.62
7.0.250.0050.00715.37
7.0.240.0070.00515.58
7.0.230.0030.01015.54
7.0.220.0090.00415.61
7.0.210.0050.01015.49
7.0.200.0040.00716.04
7.0.190.0070.00715.66
7.0.180.0050.00715.54
7.0.170.0000.01215.59
7.0.160.0090.00515.35
7.0.150.0070.00715.27
7.0.140.0030.00715.45
7.0.130.0090.00515.49
7.0.120.0040.00915.65
7.0.110.0040.01115.62
7.0.100.0080.00715.46
7.0.90.0260.00717.15
7.0.80.0250.00917.03
7.0.70.0240.00716.93
7.0.60.0230.00717.15
7.0.50.0290.00417.14
7.0.40.0290.00515.90
7.0.30.0230.00915.80
7.0.20.0270.00515.83
7.0.10.0270.00815.93
7.0.00.0300.00215.84
5.6.400.0100.00714.43
5.6.390.0060.00814.30
5.6.380.0080.00514.28
5.6.370.0080.00314.53
5.6.360.0030.00714.29
5.6.350.0090.00514.47
5.6.340.0050.00714.47
5.6.330.0060.00614.28
5.6.320.0030.01014.62
5.6.310.0060.01014.43
5.6.300.0070.00314.18
5.6.290.0020.01114.19
5.6.280.0070.00714.35
5.6.270.0030.00814.20
5.6.260.0040.01114.35
5.6.250.0070.00414.38
5.6.240.0300.00416.48
5.6.230.0300.00616.48
5.6.220.0250.00416.55
5.6.210.0270.00416.32
5.6.200.0310.00616.54
5.6.190.0320.00316.55
5.6.180.0280.00316.63
5.6.170.0270.00316.64
5.6.160.0280.00416.57
5.6.150.0370.00416.59
5.6.140.0300.00116.59
5.6.130.0270.00416.50
5.6.120.0280.00516.69
5.6.110.0300.00116.68
5.6.100.0280.00416.67
5.6.90.0280.00316.54
5.6.80.0220.00616.35
5.6.70.0270.00516.30
5.6.60.0250.00416.36
5.6.50.0230.00616.34
5.6.40.0240.00716.13
5.6.30.0260.00616.34
5.6.20.0310.00216.38
5.6.10.0250.00516.31
5.6.00.0290.00116.35

preferences:
103.84 ms | 401 KiB | 5 Q