3v4l.org

run code in 300+ PHP versions simultaneously
<?php $time = microtime(true); for ($i = 0; $i < 10000; $i++) { preg_match('/^label-(.+)/', 'label-en_US', $matches); } $time = microtime(true) - $time; echo 'preg_match() took ' . number_format($time, 3) . ' seconds' . "\n"; $time = microtime(true); for ($i = 0; $i < 10000; $i++) { explode('-', 'label-en_US'); } $time = microtime(true) - $time; echo 'explode() took ' . number_format($time, 3) . ' seconds' . "\n";

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)
7.4.10.0030.02014.69
7.4.00.0090.01215.00
7.3.130.0060.00914.84
7.3.120.0070.01415.24
7.3.110.0040.01814.51
7.3.100.0040.01414.93
7.3.90.0040.01815.22
7.3.80.0040.01515.12
7.3.70.0120.01215.04
7.3.60.0080.01214.96
7.3.50.0140.00714.84
7.3.40.0030.01314.76
7.3.30.0000.02014.73
7.3.20.0100.01616.73
7.3.10.0030.02216.37
7.3.00.0000.01816.66
7.2.260.0150.01115.29
7.2.250.0060.01215.35
7.2.240.0070.01315.30
7.2.230.0110.01115.25
7.2.220.0090.01614.88
7.2.210.0030.01315.37
7.2.200.0070.01015.15
7.2.190.0000.01415.18
7.2.180.0090.01215.29
7.2.170.0060.01515.05
7.2.160.0030.01914.79
7.2.150.0030.02216.83
7.2.140.0100.01616.65
7.2.130.0030.01616.84
7.2.120.0100.01716.96
7.2.110.0000.02016.86
7.2.100.0030.02016.82
7.2.90.0040.01416.98
7.2.80.0090.01516.87
7.2.70.0030.01717.03
7.2.60.0060.01216.54
7.2.50.0040.01516.79
7.2.40.0000.02017.16
7.2.30.0000.01717.16
7.2.20.0100.01316.82
7.2.10.0100.01616.89
7.2.00.0070.01418.24
7.1.330.0100.01015.52
7.1.320.0100.01316.01
7.1.310.0100.01715.80
7.1.300.0130.01315.98
7.1.290.0070.01715.90
7.1.280.0040.01616.00
7.1.270.0100.01315.63
7.1.260.0090.01515.57
7.1.250.0060.01715.90
7.1.240.0030.02715.63
7.1.230.0070.01115.52
7.1.220.0030.01715.47
7.1.210.0070.01615.76
7.1.200.0070.01115.76
7.1.190.0070.01415.98
7.1.180.0090.01715.76
7.1.170.0030.01715.34
7.1.160.0060.01615.60
7.1.150.0040.01815.80
7.1.140.0070.02015.86
7.1.130.0040.01715.70
7.1.120.0070.01715.82
7.1.110.0030.02015.84
7.1.100.0060.01616.10
7.1.90.0000.02315.58
7.1.80.0070.02315.92
7.1.70.0030.01516.65
7.1.60.0090.01917.59
7.1.50.0050.02616.58
7.1.40.0030.01615.69
7.1.30.0030.01715.79
7.1.20.0040.01415.70
7.1.10.0000.02015.45
7.1.00.0020.02919.02
7.0.330.0000.02415.22
7.0.320.0040.01815.54
7.0.310.0070.01415.40
7.0.300.0060.01515.26
7.0.290.0000.02115.20
7.0.280.0030.01015.50
7.0.270.0110.01815.56
7.0.260.0040.01415.66
7.0.250.0060.01515.60
7.0.240.0000.01915.16
7.0.230.0040.02215.15
7.0.220.0060.01215.32
7.0.210.0130.01015.38
7.0.200.0020.01616.02
7.0.190.0070.01715.28
7.0.180.0090.00915.31
7.0.170.0080.01915.40
7.0.160.0060.02315.43
7.0.150.0090.01615.54
7.0.140.0000.04918.71
7.0.130.0030.02415.50
7.0.120.0070.03718.71
7.0.110.0090.01315.49
7.0.100.0000.01315.42
7.0.90.0030.02115.30
7.0.80.0040.01715.25
7.0.70.0030.01615.17
7.0.60.0100.04617.53
7.0.50.0030.03216.82
7.0.40.0120.03316.77
7.0.30.0120.03416.81
7.0.20.0160.04216.99
7.0.10.0130.02916.78
7.0.00.0120.05016.86
5.6.400.0100.02113.99
5.6.390.0070.03014.16
5.6.380.0000.02414.26
5.6.370.0070.02014.50
5.6.360.0030.02814.40
5.6.350.0070.02714.40
5.6.340.0000.03013.91
5.6.330.0100.01913.61
5.6.320.0060.02214.16
5.6.310.0040.03714.29
5.6.300.0120.01513.91
5.6.290.0070.02414.14
5.6.280.0070.05617.49
5.6.270.0070.02114.26
5.6.260.0030.03314.16
5.6.250.0040.03214.33
5.6.240.0030.03013.98
5.6.230.0030.02714.21
5.6.220.0090.02514.55
5.6.210.0100.05917.54
5.6.200.0100.04716.16
5.6.190.0070.03917.52
5.6.180.0180.05017.29
5.6.170.0120.03817.56
5.6.160.0050.05917.55
5.6.150.0080.03916.07
5.6.140.0020.06616.31
5.6.130.0100.05916.29
5.6.120.0130.05317.51
5.6.110.0100.05717.70
5.6.100.0080.05917.61
5.6.90.0030.04217.57
5.6.80.0050.06017.33
5.6.70.0150.05917.29
5.6.60.0070.02414.00
5.6.50.0100.02014.06
5.6.40.0030.03314.09
5.6.30.0100.02614.00
5.6.20.0070.02314.27
5.6.10.0100.02314.28
5.6.00.0030.03713.98
5.5.380.0060.02614.34
5.5.370.0110.01814.29
5.5.360.0060.02214.05
5.5.350.0130.05417.22
5.5.340.0080.05416.10
5.5.330.0050.06317.35
5.5.320.0220.04017.30
5.5.310.0080.04217.21
5.5.300.0050.04216.30
5.5.290.0070.06115.99
5.5.280.0100.05817.49
5.5.270.0070.05617.76
5.5.260.0060.03717.53
5.5.250.0070.03517.38
5.5.240.0100.05317.28
5.5.230.0000.03214.36
5.5.220.0030.02714.24
5.5.210.0000.03014.05
5.5.200.0100.02714.34
5.5.190.0060.03114.43
5.5.180.0030.02714.18
5.5.170.0000.03614.08
5.5.160.0030.03014.30
5.5.150.0030.02614.29
5.5.140.0060.02614.50
5.5.130.0030.02714.36
5.5.120.0040.02514.22
5.5.110.0130.01914.11
5.5.100.0030.02513.86
5.5.90.0070.02414.37
5.5.80.0070.02314.18
5.5.70.0000.03913.91
5.5.60.0090.01814.56
5.5.50.0040.01814.01
5.5.40.0030.02614.25
5.5.30.0070.02314.30
5.5.20.0030.03814.28
5.5.10.0110.01814.03
5.5.00.0030.02414.24
5.4.450.0050.03215.38
5.4.440.0050.03615.33
5.4.430.0000.03515.15
5.4.420.0080.03115.24
5.4.410.0100.03315.20
5.4.400.0070.05714.92
5.4.390.0080.05814.92
5.4.380.0030.04515.00
5.4.370.0030.05514.99
5.4.360.0030.04415.07
5.4.350.0100.04814.76
5.4.340.0000.05415.09
5.4.330.0070.02410.88
5.4.320.0070.03615.12
5.4.310.0080.04114.93
5.4.300.0050.03914.79
5.4.290.0100.05314.80
5.4.280.0110.04914.95
5.4.270.0100.03814.93
5.4.260.0070.03814.74
5.4.250.0030.06014.94
5.4.240.0020.03814.84
5.4.230.0030.06014.99
5.4.220.0100.04715.00
5.4.210.0070.05015.06
5.4.200.0080.05815.11
5.4.190.0030.05515.01
5.4.180.0030.05614.93
5.4.170.0120.05215.00
5.4.160.0100.04515.05
5.4.150.0030.06015.19
5.4.140.0050.05513.70
5.4.130.0080.05213.71
5.4.120.0070.04113.62
5.4.110.0030.03513.51
5.4.100.0050.05213.56
5.4.90.0100.05113.75
5.4.80.0080.04013.64
5.4.70.0000.05213.65
5.4.60.0080.03813.76
5.4.50.0080.05413.60
5.4.40.0070.04113.50
5.4.30.0030.04713.63
5.4.20.0080.05213.66
5.4.10.0050.05613.66
5.4.00.0030.05313.30
5.3.290.0000.05912.67
5.3.280.0030.05712.51
5.3.270.0070.05512.54
5.3.260.0080.03912.59
5.3.250.0070.05512.60
5.3.240.0020.04012.58
5.3.230.0050.03612.46
5.3.220.0080.05312.48
5.3.210.0030.03912.44
5.3.200.0050.04812.51
5.3.190.0000.05512.46
5.3.180.0050.04412.56
5.3.170.0070.05612.61
5.3.160.0020.04512.57
5.3.150.0050.04112.57
5.3.140.0080.05012.51
5.3.130.0100.05312.53
5.3.120.0050.03812.59
5.3.110.0030.04212.43
5.3.100.0050.06512.32
5.3.90.0080.05912.22
5.3.80.0120.05112.12
5.3.70.0070.04712.18
5.3.60.0030.05812.23
5.3.50.0050.05212.03
5.3.40.0050.04112.07
5.3.30.0020.04012.17
5.3.20.0030.04312.02
5.3.10.0030.05711.87
5.3.00.0060.03911.91
5.2.170.0070.05311.32
5.2.160.0070.08011.21
5.2.150.0030.08011.28
5.2.140.0070.04311.24
5.2.130.0030.04011.20
5.2.120.0000.04711.12
5.2.110.0070.07311.16
5.2.100.0030.05011.25
5.2.90.0000.04011.28
5.2.80.0130.03711.04
5.2.70.0000.04711.21
5.2.60.0030.05010.99
5.2.50.0030.05311.08
5.2.40.0000.05311.15
5.2.30.0100.04311.09
5.2.20.0000.07311.01
5.2.10.0100.07011.06
5.2.00.0000.05010.82
5.1.60.0130.04710.19
5.1.50.0030.05310.25
5.1.40.0030.05310.05
5.1.30.0030.05010.45
5.1.20.0100.06310.55
5.1.10.0070.06710.09
5.1.00.0100.04710.14
5.0.50.0070.0608.79
5.0.40.0070.0638.66
5.0.30.0030.0538.52
5.0.20.0030.0478.52
5.0.10.0030.0578.52
5.0.00.0000.0608.52
4.4.90.0070.0308.52
4.4.80.0000.0608.52
4.4.70.0000.0278.52
4.4.60.0030.0338.52
4.4.50.0030.0508.52
4.4.40.0030.0738.52
4.4.30.0000.0608.52
4.4.20.0030.0578.52
4.4.10.0000.0378.52
4.4.00.0000.0438.52
4.3.110.0000.0508.52
4.3.100.0030.0438.52
4.3.90.0030.0538.52
4.3.80.0030.0538.52
4.3.70.0000.0338.52
4.3.60.0070.0308.52
4.3.50.0070.0278.52
4.3.40.0000.0438.52
4.3.30.0000.0508.52
4.3.20.0000.0508.52
4.3.10.0000.0508.52
4.3.00.0000.0538.52

preferences:
36.77 ms | 401 KiB | 5 Q