3v4l.org

run code in 300+ PHP versions simultaneously
<?php $sc = 'hello 8491241 some text 6254841 some text 568241 414844:412'; preg_match_all('/([0-9]{5,10})(:[0-9]{1,5})?/', $sc, $matches, PREG_SET_ORDER); $all_matches = array_reduce($matches, function (array $all, array $match) { $all[] = ['batch' => $match[1], 'type' => '1']; if (isset($match[2])) { $all[] = ['batch' => $match[0], 'type' => '2']; } return $all; }, []); print_r($all_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.70.0040.01218.43
8.3.60.0070.01416.75
8.3.50.0180.00922.98
8.3.40.0120.00318.93
8.3.30.0090.00619.13
8.3.20.0000.00720.34
8.3.10.0070.00021.82
8.3.00.0070.00019.23
8.2.190.0070.00716.75
8.2.180.0110.00718.54
8.2.170.0100.00322.96
8.2.160.0030.01020.52
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0060.00321.00
8.2.110.0030.00721.10
8.2.100.0060.00617.97
8.2.90.0040.00419.34
8.2.80.0060.00317.97
8.2.70.0040.00418.05
8.2.60.0060.00317.88
8.2.50.0030.00518.18
8.2.40.0040.00420.42
8.2.30.0030.00520.60
8.2.20.0040.00417.99
8.2.10.0000.00718.16
8.2.00.0040.00417.88
8.1.280.0070.01025.92
8.1.270.0090.00019.00
8.1.260.0070.00026.35
8.1.250.0040.00428.09
8.1.240.0030.00619.22
8.1.230.0040.00717.83
8.1.220.0050.00317.74
8.1.210.0040.00418.77
8.1.200.0040.00417.35
8.1.190.0100.00317.35
8.1.180.0040.00418.10
8.1.170.0050.00518.60
8.1.160.0040.00418.98
8.1.150.0030.00720.24
8.1.140.0040.00417.59
8.1.130.0070.00017.79
8.1.120.0000.00717.54
8.1.110.0000.00817.66
8.1.100.0000.00817.50
8.1.90.0070.00017.71
8.1.80.0040.00417.55
8.1.70.0030.00317.63
8.1.60.0080.00317.80
8.1.50.0040.00417.69
8.1.40.0060.00317.66
8.1.30.0090.00017.67
8.1.20.0070.00017.84
8.1.10.0000.00817.79
8.1.00.0000.00717.54
8.0.300.0040.00419.15
8.0.290.0070.00016.75
8.0.280.0100.00018.34
8.0.270.0030.00317.27
8.0.260.0000.00617.21
8.0.250.0000.00717.03
8.0.240.0000.00717.05
8.0.230.0030.00316.94
8.0.220.0030.00317.02
8.0.210.0000.00716.98
8.0.200.0000.00717.09
8.0.190.0040.00417.05
8.0.180.0070.00017.09
8.0.170.0040.00417.02
8.0.160.0070.00017.03
8.0.150.0000.00816.97
8.0.140.0030.00517.05
8.0.130.0030.00313.52
8.0.120.0040.00417.09
8.0.110.0040.00416.90
8.0.100.0040.00417.03
8.0.90.0030.00317.09
8.0.80.0060.01417.01
8.0.70.0000.00816.99
8.0.60.0040.00417.05
8.0.50.0070.00017.01
8.0.30.0150.01017.34
8.0.20.0110.01117.45
8.0.10.0080.00016.97
8.0.00.0120.00916.98
7.4.330.0060.00015.03
7.4.320.0040.00416.77
7.4.300.0060.00016.65
7.4.290.0070.00016.75
7.4.280.0040.00416.80
7.4.270.0000.00816.88
7.4.260.0000.00816.70
7.4.250.0080.00016.68
7.4.240.0070.00116.80
7.4.230.0070.00016.57
7.4.220.0080.00816.79
7.4.210.0110.00416.80
7.4.200.0040.00416.86
7.4.160.0060.01216.55
7.4.150.0070.01417.40
7.4.140.0150.00517.86
7.4.130.0120.00516.79
7.4.120.0100.00816.68
7.4.110.0090.00916.83
7.4.100.0070.01116.61
7.4.90.0100.00716.59
7.4.80.0070.01319.39
7.4.70.0160.00616.75
7.4.60.0060.00916.85
7.4.50.0000.00516.53
7.4.40.0070.01016.78
7.4.30.0140.01016.40
7.4.00.0030.00915.05
7.3.330.0000.00813.47
7.3.320.0000.00513.32
7.3.310.0070.00016.69
7.3.300.0040.00416.44
7.3.290.0060.01016.48
7.3.280.0070.01116.44
7.3.270.0100.01017.40
7.3.260.0160.00716.54
7.3.250.0170.00416.74
7.3.240.0100.01016.78
7.3.230.0110.00616.86
7.3.210.0000.01716.71
7.3.200.0090.00819.39
7.3.190.0090.00916.71
7.3.180.0100.00716.43
7.3.170.0140.00616.70
7.3.160.0130.01016.80
7.3.00.0070.00716.55
7.2.330.0080.01416.69
7.2.320.0110.00616.80
7.2.310.0030.01616.81
7.2.300.0100.00716.73
7.2.290.0100.00716.84
7.2.130.0140.00017.11
7.2.120.0110.00417.00
7.2.110.0120.00417.16
7.2.100.0000.01017.04
7.2.90.0140.00417.18
7.2.80.0030.01417.10
7.2.70.0080.00516.89
7.2.60.0120.00816.84
7.2.50.0100.01417.04
7.2.40.0000.01316.57
7.2.30.0110.01116.96
7.2.20.0060.00616.84
7.2.10.0030.00916.85
7.2.00.0130.00618.42
7.1.250.0100.00315.84
7.1.240.0100.01015.88
7.1.230.0060.00616.09
7.1.220.0000.00916.01
7.1.210.0070.00715.96
7.1.200.0030.00615.65
7.1.190.0040.01115.98
7.1.180.0150.00315.90
7.1.170.0120.00615.86
7.1.160.0100.00616.12
7.1.150.0050.01015.88
7.1.140.0040.00715.73
7.1.130.0080.00816.05
7.1.120.0130.00815.84
7.1.110.0130.00615.95
7.1.100.0070.00916.93
7.1.90.0130.00915.67
7.1.80.0090.01515.63
7.1.70.0060.01116.50
7.1.60.0160.00717.72
7.1.50.0090.00816.43
7.1.40.0150.00315.72
7.1.30.0070.01015.66
7.1.20.0120.00615.79
7.1.10.0140.00315.89
7.1.00.0030.04519.19
7.0.330.0080.00815.45
7.0.320.0100.00715.61
7.0.310.0200.00015.67
7.0.300.0120.00715.61
7.0.290.0190.00315.57
7.0.280.0070.01015.53
7.0.270.0090.00615.37
7.0.260.0150.00415.34
7.0.250.0150.00615.45
7.0.240.0200.00315.42
7.0.230.0090.01015.52
7.0.220.0100.00615.47
7.0.210.0120.00915.71
7.0.200.0040.01016.08
7.0.190.0100.00715.60
7.0.180.0080.00415.36
7.0.170.0070.00415.70
7.0.160.0070.00715.59
7.0.150.0000.01615.54
7.0.140.0060.03018.81
7.0.130.0000.00915.76
7.0.120.0100.00315.71
7.0.110.0000.01315.59
7.0.100.0030.00615.84
7.0.90.0060.00315.65
7.0.80.0030.00915.55
7.0.70.0120.00615.80
7.0.60.0080.02317.74
7.0.50.0220.02516.79
7.0.40.0040.04617.04
7.0.30.0170.04316.95
7.0.20.0170.02716.85
7.0.10.0130.02816.84
7.0.00.0020.04816.75
5.6.380.0030.01014.50
5.6.370.0070.00414.57
5.6.360.0110.00414.14
5.6.350.0070.01014.61
5.6.340.0060.00914.48
5.6.330.0060.00614.41
5.6.320.0080.00614.19
5.6.310.0080.00814.39
5.6.300.0070.01014.20
5.6.290.0040.01114.87
5.6.280.0020.04217.85
5.6.270.0100.00314.57
5.6.260.0070.00714.48
5.6.250.0060.01014.71
5.6.240.0040.00814.64
5.6.230.0000.01514.68
5.6.220.0030.00614.31
5.6.210.0070.02017.49
5.6.200.0150.03616.27
5.6.190.0090.02917.44
5.6.180.0240.03817.51
5.6.170.0150.04317.43
5.6.160.0050.04317.50
5.6.150.0030.04616.52
5.6.140.0100.04316.46
5.6.130.0040.03616.35
5.6.120.0050.03017.80
5.6.110.0060.02117.70
5.6.100.0080.04417.88
5.6.90.0130.03717.66
5.6.80.0070.03517.39
5.6.70.0180.04317.31
5.6.60.0040.01114.43
5.6.50.0040.00814.28
5.6.40.0030.00914.66
5.6.30.0030.00914.23
5.6.20.0040.00814.68
5.6.10.0040.01114.33
5.6.00.0120.00314.59
5.5.380.0000.00611.18
5.5.370.0000.01111.31
5.5.360.0060.00611.18
5.5.350.0070.04315.76
5.5.340.0070.03214.71
5.5.330.0050.04515.83
5.5.320.0290.02515.75
5.5.310.0150.04415.76
5.5.300.0050.02014.62
5.5.290.0030.02714.72
5.5.280.0050.04516.17
5.5.270.0020.02516.08
5.5.260.0050.02515.94
5.5.250.0060.03515.98
5.5.240.0100.04115.78
5.5.230.0040.00711.34
5.5.220.0030.00911.18
5.5.210.0090.00311.18
5.5.200.0050.00511.29
5.5.190.0060.00611.36
5.5.180.0060.00611.32
5.5.170.0030.01011.18
5.5.160.0030.00611.18
5.5.150.0030.00311.34
5.5.140.0030.00311.42
5.5.130.0100.00311.21
5.5.120.0070.00311.27
5.5.110.0090.00311.18
5.5.100.0030.00311.18
5.5.90.0090.00311.23
5.5.80.0000.01011.46
5.5.70.0060.00611.25
5.5.60.0080.00411.40
5.5.50.0040.00711.32
5.5.40.0060.00311.27
5.5.30.0130.00011.18
5.5.20.0000.00811.18
5.5.10.0030.01011.33
5.5.00.0030.01011.36
5.4.450.0370.02615.54
5.4.440.0320.03515.50
5.4.430.0030.03515.37
5.4.420.0050.03515.41
5.4.410.0070.02915.34
5.4.400.0100.03615.20
5.4.390.0080.03015.15
5.4.380.0150.02515.01
5.4.370.0100.02814.93
5.4.360.0180.02215.03
5.4.350.0150.02515.01
5.4.340.0100.02814.89
5.4.330.0000.00911.31
5.4.320.0150.02714.96
5.4.310.0130.02614.97
5.4.300.0120.02814.89
5.4.290.0180.02114.88
5.4.280.0100.02715.00
5.4.270.0100.02914.84
5.4.260.0100.03015.02
5.4.250.0110.03014.88
5.4.240.0120.02714.89
5.4.230.0100.02714.96
5.4.220.0100.02814.92
5.4.210.0140.03514.95
5.4.200.0100.02713.94
5.4.190.0130.02314.86
5.4.180.0120.02814.96
5.4.170.0160.02514.83
5.4.160.0130.02314.97
5.4.150.0020.03714.86
5.4.140.0060.03113.87
5.4.130.0100.02813.78
5.4.120.0130.02313.75
5.4.110.0080.02813.73
5.4.100.0090.02813.73
5.4.90.0100.03013.71
5.4.80.0100.02513.72
5.4.70.0100.02713.76
5.4.60.0100.02813.83
5.4.50.0150.02513.72
5.4.40.0110.02713.72
5.4.30.0080.02713.71
5.4.20.0100.03013.65
5.4.10.0080.03013.71
5.4.00.0110.02613.48
5.3.290.0030.03513.03
5.3.280.0100.02812.93
5.3.270.0100.02812.94
5.3.260.0110.02812.90
5.3.250.0070.02812.90
5.3.240.0100.02712.99
5.3.230.0080.03012.96
5.3.220.0100.02512.89
5.3.210.0100.02812.90
5.3.200.0030.03412.93
5.3.190.0090.02912.90
5.3.180.0100.02612.89
5.3.170.0070.03012.94
5.3.160.0030.03112.88
5.3.150.0070.03012.95
5.3.140.0050.03312.86
5.3.130.0100.02812.94
5.3.120.0100.02912.88
5.3.110.0120.02712.91
5.3.100.0080.02912.66
5.3.90.0100.02712.70
5.3.80.0050.03312.71
5.3.70.0100.02512.62
5.3.60.0080.02712.61
5.3.50.0080.02912.60
5.3.40.0030.03212.61
5.3.30.0100.03012.54
5.3.20.0020.03512.52
5.3.10.0060.03112.43
5.3.00.0120.02612.47
5.2.170.0050.02511.18
5.2.160.0020.02811.18
5.2.150.0090.02211.17
5.2.140.0080.02411.17
5.2.130.0100.02011.21
5.2.120.0080.02211.13
5.2.110.0060.02211.17
5.2.100.0080.02511.13
5.2.90.0040.02511.21
5.2.80.0070.02311.11
5.2.70.0130.01811.15
5.2.60.0060.02511.13
5.2.50.0070.02211.08
5.2.40.0020.02711.16
5.2.30.0100.01811.07
5.2.20.0080.02011.14
5.2.10.0070.02011.09
5.2.00.0030.02311.03
5.1.60.0060.01810.62
5.1.50.0050.02010.57
5.1.40.0050.01810.59
5.1.30.0030.02210.75
5.1.20.0100.01710.81
5.1.10.0050.02010.65
5.1.00.0070.01910.63
5.0.50.0020.0179.92
5.0.40.0050.0159.83
5.0.30.0040.0249.72
5.0.20.0050.0159.78
5.0.10.0080.0139.72
5.0.00.0070.0209.69
4.4.90.0030.0128.54
4.4.80.0020.0138.54
4.4.70.0020.0148.51
4.4.60.0030.0148.55
4.4.50.0020.0148.54
4.4.40.0030.0208.56
4.4.30.0030.0128.54
4.4.20.0030.0128.58
4.4.10.0020.0148.57
4.4.00.0030.0208.54
4.3.110.0050.0128.50
4.3.100.0050.0128.49
4.3.90.0020.0128.49
4.3.80.0050.0168.49
4.3.70.0000.0148.50
4.3.60.0020.0138.49
4.3.50.0030.0138.48
4.3.40.0010.0208.48
4.3.30.0020.0127.92
4.3.20.0020.0127.89
4.3.10.0030.0127.84
4.3.00.0030.0149.11

preferences:
48.48 ms | 401 KiB | 5 Q