1<html> 2<head> 3<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> 4<title>Testing simple Perl matches (platform = linux, compiler = GNU C++ version 6.3.0)</title> 5<link rel="stylesheet" href="../../../../../../../doc/src/boostbook.css" type="text/css"> 6<meta name="generator" content="DocBook XSL Stylesheets V1.79.1"> 7<link rel="home" href="../../../index.html" title="Boost.Regex 5.1.4"> 8<link rel="up" href="../performance.html" title="Performance"> 9<link rel="prev" href="section_id3258595385.html" title="Testing leftmost-longest searches (platform = Windows x64, compiler = Microsoft Visual C++ version 14.1)"> 10<link rel="next" href="section_id3752650613.html" title="Testing Perl searches (platform = Windows x64, compiler = Microsoft Visual C++ version 14.1)"> 11</head> 12<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> 13<table cellpadding="2" width="100%"><tr> 14<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../boost.png"></td> 15<td align="center"><a href="../../../../../../../index.html">Home</a></td> 16<td align="center"><a href="../../../../../../../libs/libraries.htm">Libraries</a></td> 17<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td> 18<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td> 19<td align="center"><a href="../../../../../../../more/index.htm">More</a></td> 20</tr></table> 21<hr> 22<div class="spirit-nav"> 23<a accesskey="p" href="section_id3258595385.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../performance.html"><img src="../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="section_id3752650613.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a> 24</div> 25<div class="section"> 26<div class="titlepage"><div><div><h4 class="title"> 27<a name="boost_regex.background.performance.section_id3261825021"></a><a class="link" href="section_id3261825021.html" title="Testing simple Perl matches (platform = linux, compiler = GNU C++ version 6.3.0)">Testing 28 simple Perl matches (platform = linux, compiler = GNU C++ version 6.3.0)</a> 29</h4></div></div></div> 30<div class="table"> 31<a name="boost_regex.background.performance.section_id3261825021.table_Testing_simple_Perl_matches_platform_linux_compiler_GNU_C_version_6_3_0_"></a><p class="title"><b>Table 12. Testing simple Perl matches (platform = linux, compiler = GNU C++ 32 version 6.3.0)</b></p> 33<div class="table-contents"><table class="table" summary="Testing simple Perl matches (platform = linux, compiler = GNU C++ 34 version 6.3.0)"> 35<colgroup> 36<col> 37<col> 38<col> 39<col> 40<col> 41</colgroup> 42<thead><tr> 43<th> 44 <p> 45 Expression<br> Text 46 </p> 47 </th> 48<th> 49 <p> 50 boost 1.65 51 </p> 52 </th> 53<th> 54 <p> 55 std::regex 56 </p> 57 </th> 58<th> 59 <p> 60 boost::xpressive::cregex 61 </p> 62 </th> 63<th> 64 <p> 65 PCRE-10.21 66 </p> 67 </th> 68</tr></thead> 69<tbody> 70<tr> 71<td> 72 <p> 73 <code class="literal">([[:digit:]]{4}[- ]){3}[[:digit:]]{3,4}</code><br> 74 <code class="literal">1234-5678-1234-456</code> 75 </p> 76 </td> 77<td> 78 <p> 79 <span class="blue">2.65<br> (506ns)</span> 80 </p> 81 </td> 82<td> 83 <p> 84 <span class="blue">2.86<br> (546ns)</span> 85 </p> 86 </td> 87<td> 88 <p> 89 <span class="green">1.00<br> (191ns)</span> 90 </p> 91 </td> 92<td> 93 <p> 94 <span class="blue">1.37<br> (262ns)</span> 95 </p> 96 </td> 97</tr> 98<tr> 99<td> 100 <p> 101 <code class="literal">^([0-9]+)(\-| |$)(.*)$</code><br> <code class="literal">100- 102 this is a line of ftp response which contains a message string</code> 103 </p> 104 </td> 105<td> 106 <p> 107 <span class="blue">2.52<br> (353ns)</span> 108 </p> 109 </td> 110<td> 111 <p> 112 <span class="red">20.99<br> (2939ns)</span> 113 </p> 114 </td> 115<td> 116 <p> 117 <span class="green">1.00<br> (140ns)</span> 118 </p> 119 </td> 120<td> 121 <p> 122 <span class="blue">3.50<br> (490ns)</span> 123 </p> 124 </td> 125</tr> 126<tr> 127<td> 128 <p> 129 <code class="literal">^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\ 130 ...</code><br> <code class="literal">bob.smith@foo.tv</code> 131 </p> 132 </td> 133<td> 134 <p> 135 <span class="blue">1.98<br> (681ns)</span> 136 </p> 137 </td> 138<td> 139 <p> 140 <span class="grey">-</span> 141 </p> 142 </td> 143<td> 144 <p> 145 <span class="green">1.00<br> (344ns)</span> 146 </p> 147 </td> 148<td> 149 <p> 150 <span class="blue">1.32<br> (454ns)</span> 151 </p> 152 </td> 153</tr> 154<tr> 155<td> 156 <p> 157 <code class="literal">^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\ 158 ...</code><br> <code class="literal">foo12@foo.edu</code> 159 </p> 160 </td> 161<td> 162 <p> 163 <span class="blue">2.06<br> (695ns)</span> 164 </p> 165 </td> 166<td> 167 <p> 168 <span class="grey">-</span> 169 </p> 170 </td> 171<td> 172 <p> 173 <span class="green">1.00<br> (337ns)</span> 174 </p> 175 </td> 176<td> 177 <p> 178 <span class="blue">1.34<br> (451ns)</span> 179 </p> 180 </td> 181</tr> 182<tr> 183<td> 184 <p> 185 <code class="literal">^([a-zA-Z0-9_\-\.]+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-]+\.)+))([a-zA-Z]{2,4}|[0-9]{1,3})(\ 186 ...</code><br> <code class="literal">john@johnmaddock.co.uk</code> 187 </p> 188 </td> 189<td> 190 <p> 191 <span class="blue">1.93<br> (821ns)</span> 192 </p> 193 </td> 194<td> 195 <p> 196 <span class="grey">-</span> 197 </p> 198 </td> 199<td> 200 <p> 201 <span class="green">1.00<br> (425ns)</span> 202 </p> 203 </td> 204<td> 205 <p> 206 <span class="blue">1.24<br> (526ns)</span> 207 </p> 208 </td> 209</tr> 210<tr> 211<td> 212 <p> 213 <code class="literal">^[-+]?[[:digit:]]*\.?[[:digit:]]*$</code><br> 214 <code class="literal">+3.14159</code> 215 </p> 216 </td> 217<td> 218 <p> 219 <span class="blue">2.34<br> (243ns)</span> 220 </p> 221 </td> 222<td> 223 <p> 224 <span class="red">4.45<br> (463ns)</span> 225 </p> 226 </td> 227<td> 228 <p> 229 <span class="green">1.00<br> (104ns)</span> 230 </p> 231 </td> 232<td> 233 <p> 234 <span class="blue">1.62<br> (168ns)</span> 235 </p> 236 </td> 237</tr> 238<tr> 239<td> 240 <p> 241 <code class="literal">^[-+]?[[:digit:]]*\.?[[:digit:]]*$</code><br> 242 <code class="literal">-3.14159</code> 243 </p> 244 </td> 245<td> 246 <p> 247 <span class="blue">2.33<br> (245ns)</span> 248 </p> 249 </td> 250<td> 251 <p> 252 <span class="red">4.39<br> (461ns)</span> 253 </p> 254 </td> 255<td> 256 <p> 257 <span class="green">1.00<br> (105ns)</span> 258 </p> 259 </td> 260<td> 261 <p> 262 <span class="blue">1.60<br> (168ns)</span> 263 </p> 264 </td> 265</tr> 266<tr> 267<td> 268 <p> 269 <code class="literal">^[-+]?[[:digit:]]*\.?[[:digit:]]*$</code><br> 270 <code class="literal">123</code> 271 </p> 272 </td> 273<td> 274 <p> 275 <span class="blue">2.08<br> (208ns)</span> 276 </p> 277 </td> 278<td> 279 <p> 280 <span class="blue">3.31<br> (331ns)</span> 281 </p> 282 </td> 283<td> 284 <p> 285 <span class="green">1.00<br> (100ns)</span> 286 </p> 287 </td> 288<td> 289 <p> 290 <span class="blue">1.52<br> (152ns)</span> 291 </p> 292 </td> 293</tr> 294<tr> 295<td> 296 <p> 297 <code class="literal">^[[:digit:]]{1,2}/[[:digit:]]{1,2}/[[:digit:]]{4}$</code><br> 298 <code class="literal">12/12/2001</code> 299 </p> 300 </td> 301<td> 302 <p> 303 <span class="blue">2.28<br> (237ns)</span> 304 </p> 305 </td> 306<td> 307 <p> 308 <span class="blue">3.39<br> (353ns)</span> 309 </p> 310 </td> 311<td> 312 <p> 313 <span class="green">1.00<br> (104ns)</span> 314 </p> 315 </td> 316<td> 317 <p> 318 <span class="green">1.18<br> (123ns)</span> 319 </p> 320 </td> 321</tr> 322<tr> 323<td> 324 <p> 325 <code class="literal">^[[:digit:]]{1,2}/[[:digit:]]{1,2}/[[:digit:]]{4}$</code><br> 326 <code class="literal">4/1/2001</code> 327 </p> 328 </td> 329<td> 330 <p> 331 <span class="blue">2.12<br> (216ns)</span> 332 </p> 333 </td> 334<td> 335 <p> 336 <span class="blue">3.02<br> (308ns)</span> 337 </p> 338 </td> 339<td> 340 <p> 341 <span class="green">1.00<br> (102ns)</span> 342 </p> 343 </td> 344<td> 345 <p> 346 <span class="green">1.19<br> (121ns)</span> 347 </p> 348 </td> 349</tr> 350<tr> 351<td> 352 <p> 353 <code class="literal">^[a-zA-Z]{1,2}[0-9][0-9A-Za-z]{0,1} {0,1}[0-9][A-Za-z]{2}$</code><br> 354 <code class="literal">EH10 2QQ</code> 355 </p> 356 </td> 357<td> 358 <p> 359 <span class="blue">2.12<br> (257ns)</span> 360 </p> 361 </td> 362<td> 363 <p> 364 <span class="blue">2.66<br> (322ns)</span> 365 </p> 366 </td> 367<td> 368 <p> 369 <span class="green">1.00<br> (121ns)</span> 370 </p> 371 </td> 372<td> 373 <p> 374 <span class="green">1.17<br> (142ns)</span> 375 </p> 376 </td> 377</tr> 378<tr> 379<td> 380 <p> 381 <code class="literal">^[a-zA-Z]{1,2}[0-9][0-9A-Za-z]{0,1} {0,1}[0-9][A-Za-z]{2}$</code><br> 382 <code class="literal">G1 1AA</code> 383 </p> 384 </td> 385<td> 386 <p> 387 <span class="blue">2.00<br> (230ns)</span> 388 </p> 389 </td> 390<td> 391 <p> 392 <span class="blue">2.65<br> (305ns)</span> 393 </p> 394 </td> 395<td> 396 <p> 397 <span class="green">1.00<br> (115ns)</span> 398 </p> 399 </td> 400<td> 401 <p> 402 <span class="blue">1.22<br> (140ns)</span> 403 </p> 404 </td> 405</tr> 406<tr> 407<td> 408 <p> 409 <code class="literal">^[a-zA-Z]{1,2}[0-9][0-9A-Za-z]{0,1} {0,1}[0-9][A-Za-z]{2}$</code><br> 410 <code class="literal">SW1 1ZZ</code> 411 </p> 412 </td> 413<td> 414 <p> 415 <span class="blue">2.05<br> (244ns)</span> 416 </p> 417 </td> 418<td> 419 <p> 420 <span class="blue">2.81<br> (334ns)</span> 421 </p> 422 </td> 423<td> 424 <p> 425 <span class="green">1.00<br> (119ns)</span> 426 </p> 427 </td> 428<td> 429 <p> 430 <span class="blue">1.22<br> (145ns)</span> 431 </p> 432 </td> 433</tr> 434<tr> 435<td> 436 <p> 437 <code class="literal">abc</code><br> <code class="literal">abc</code> 438 </p> 439 </td> 440<td> 441 <p> 442 <span class="blue">1.65<br> (135ns)</span> 443 </p> 444 </td> 445<td> 446 <p> 447 <span class="blue">1.83<br> (150ns)</span> 448 </p> 449 </td> 450<td> 451 <p> 452 <span class="green">1.00<br> (82ns)</span> 453 </p> 454 </td> 455<td> 456 <p> 457 <span class="green">1.02<br> (84ns)</span> 458 </p> 459 </td> 460</tr> 461</tbody> 462</table></div> 463</div> 464<br class="table-break"> 465</div> 466<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr> 467<td align="left"></td> 468<td align="right"><div class="copyright-footer">Copyright © 1998-2013 John Maddock<p> 469 Distributed under the Boost Software License, Version 1.0. (See accompanying 470 file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>) 471 </p> 472</div></td> 473</tr></table> 474<hr> 475<div class="spirit-nav"> 476<a accesskey="p" href="section_id3258595385.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../performance.html"><img src="../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="section_id3752650613.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a> 477</div> 478</body> 479</html> 480