1*22dc650dSSadaf Ebrahimi<html> 2*22dc650dSSadaf Ebrahimi<head> 3*22dc650dSSadaf Ebrahimi<title>pcre2_jit_match specification</title> 4*22dc650dSSadaf Ebrahimi</head> 5*22dc650dSSadaf Ebrahimi<body bgcolor="#FFFFFF" text="#00005A" link="#0066FF" alink="#3399FF" vlink="#2222BB"> 6*22dc650dSSadaf Ebrahimi<h1>pcre2_jit_match man page</h1> 7*22dc650dSSadaf Ebrahimi<p> 8*22dc650dSSadaf EbrahimiReturn to the <a href="index.html">PCRE2 index page</a>. 9*22dc650dSSadaf Ebrahimi</p> 10*22dc650dSSadaf Ebrahimi<p> 11*22dc650dSSadaf EbrahimiThis page is part of the PCRE2 HTML documentation. It was generated 12*22dc650dSSadaf Ebrahimiautomatically from the original man page. If there is any nonsense in it, 13*22dc650dSSadaf Ebrahimiplease consult the man page, in case the conversion went wrong. 14*22dc650dSSadaf Ebrahimi<br> 15*22dc650dSSadaf Ebrahimi<br><b> 16*22dc650dSSadaf EbrahimiSYNOPSIS 17*22dc650dSSadaf Ebrahimi</b><br> 18*22dc650dSSadaf Ebrahimi<P> 19*22dc650dSSadaf Ebrahimi<b>#include <pcre2.h></b> 20*22dc650dSSadaf Ebrahimi</P> 21*22dc650dSSadaf Ebrahimi<P> 22*22dc650dSSadaf Ebrahimi<b>int pcre2_jit_match(const pcre2_code *<i>code</i>, PCRE2_SPTR <i>subject</i>,</b> 23*22dc650dSSadaf Ebrahimi<b> PCRE2_SIZE <i>length</i>, PCRE2_SIZE <i>startoffset</i>,</b> 24*22dc650dSSadaf Ebrahimi<b> uint32_t <i>options</i>, pcre2_match_data *<i>match_data</i>,</b> 25*22dc650dSSadaf Ebrahimi<b> pcre2_match_context *<i>mcontext</i>);</b> 26*22dc650dSSadaf Ebrahimi</P> 27*22dc650dSSadaf Ebrahimi<br><b> 28*22dc650dSSadaf EbrahimiDESCRIPTION 29*22dc650dSSadaf Ebrahimi</b><br> 30*22dc650dSSadaf Ebrahimi<P> 31*22dc650dSSadaf EbrahimiThis function matches a compiled regular expression that has been successfully 32*22dc650dSSadaf Ebrahimiprocessed by the JIT compiler against a given subject string, using a matching 33*22dc650dSSadaf Ebrahimialgorithm that is similar to Perl's. It is a "fast path" interface to JIT, and 34*22dc650dSSadaf Ebrahimiit bypasses some of the sanity checks that <b>pcre2_match()</b> applies. 35*22dc650dSSadaf Ebrahimi</P> 36*22dc650dSSadaf Ebrahimi<P> 37*22dc650dSSadaf EbrahimiIn UTF mode, the subject string is not checked for UTF validity. Unless 38*22dc650dSSadaf EbrahimiPCRE2_MATCH_INVALID_UTF was set when the pattern was compiled, passing an 39*22dc650dSSadaf Ebrahimiinvalid UTF string results in undefined behaviour. Your program may crash or 40*22dc650dSSadaf Ebrahimiloop or give wrong results. In the absence of PCRE2_MATCH_INVALID_UTF you 41*22dc650dSSadaf Ebrahimishould only call <b>pcre2_jit_match()</b> in UTF mode if you are sure the 42*22dc650dSSadaf Ebrahimisubject is valid. 43*22dc650dSSadaf Ebrahimi</P> 44*22dc650dSSadaf Ebrahimi<P> 45*22dc650dSSadaf EbrahimiThe arguments for <b>pcre2_jit_match()</b> are exactly the same as for 46*22dc650dSSadaf Ebrahimi<a href="pcre2_match.html"><b>pcre2_match()</b>,</a> 47*22dc650dSSadaf Ebrahimiexcept that the subject string must be specified with a length; 48*22dc650dSSadaf EbrahimiPCRE2_ZERO_TERMINATED is not supported. 49*22dc650dSSadaf Ebrahimi</P> 50*22dc650dSSadaf Ebrahimi<P> 51*22dc650dSSadaf EbrahimiThe supported options are PCRE2_NOTBOL, PCRE2_NOTEOL, PCRE2_NOTEMPTY, 52*22dc650dSSadaf EbrahimiPCRE2_NOTEMPTY_ATSTART, PCRE2_PARTIAL_HARD, and PCRE2_PARTIAL_SOFT. Unsupported 53*22dc650dSSadaf Ebrahimioptions are ignored. 54*22dc650dSSadaf Ebrahimi</P> 55*22dc650dSSadaf Ebrahimi<P> 56*22dc650dSSadaf EbrahimiThe return values are the same as for <b>pcre2_match()</b> plus 57*22dc650dSSadaf EbrahimiPCRE2_ERROR_JIT_BADOPTION if a matching mode (partial or complete) is requested 58*22dc650dSSadaf Ebrahimithat was not compiled. For details of partial matching, see the 59*22dc650dSSadaf Ebrahimi<a href="pcre2partial.html"><b>pcre2partial</b></a> 60*22dc650dSSadaf Ebrahimipage. 61*22dc650dSSadaf Ebrahimi</P> 62*22dc650dSSadaf Ebrahimi<P> 63*22dc650dSSadaf EbrahimiThere is a complete description of the PCRE2 native API in the 64*22dc650dSSadaf Ebrahimi<a href="pcre2api.html"><b>pcre2api</b></a> 65*22dc650dSSadaf Ebrahimipage and a description of the JIT API in the 66*22dc650dSSadaf Ebrahimi<a href="pcre2jit.html"><b>pcre2jit</b></a> 67*22dc650dSSadaf Ebrahimipage. 68*22dc650dSSadaf Ebrahimi<p> 69*22dc650dSSadaf EbrahimiReturn to the <a href="index.html">PCRE2 index page</a>. 70*22dc650dSSadaf Ebrahimi</p> 71