Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

pcre_study(3) [debian man page]

PCRE_STUDY(3)						     Library Functions Manual						     PCRE_STUDY(3)

NAME
PCRE - Perl-compatible regular expressions SYNOPSIS
#include <pcre.h> pcre_extra *pcre_study(const pcre *code, int options, const char **errptr); pcre16_extra *pcre16_study(const pcre16 *code, int options, const char **errptr); DESCRIPTION
This function studies a compiled pattern, to see if additional information can be extracted that might speed up matching. Its arguments are: code A compiled regular expression options Options for pcre[16]_study() errptr Where to put an error message If the function succeeds, it returns a value that can be passed to pcre[16]_exec() or pcre[16]_dfa_exec() via their extra arguments. If the function returns NULL, either it could not find any additional information, or there was an error. You can tell the difference by looking at the error value. It is NULL in first case. The only option is PCRE_STUDY_JIT_COMPILE. It requests just-in-time compilation if possible. If PCRE has been compiled without JIT support, this option is ignored. See the pcrejit page for further details. There is a complete description of the PCRE native API in the pcreapi page and a description of the POSIX API in the pcreposix page. PCRE_STUDY(3)

Check Out this Related Man Page

PCRE_ASSIGN_JIT_STACK(3)				     Library Functions Manual					  PCRE_ASSIGN_JIT_STACK(3)

NAME
PCRE - Perl-compatible regular expressions SYNOPSIS
#include <pcre.h> void pcre_assign_jit_stack(pcre_extra *extra, pcre_jit_callback callback, void *data); void pcre16_assign_jit_stack(pcre16_extra *extra, pcre16_jit_callback callback, void *data); DESCRIPTION
This function provides control over the memory used as a stack at runtime by a call to pcre[16]_exec() with a pattern that has been suc- cessfully compiled with JIT optimization. The arguments are: extra the data pointer returned by pcre[16]_study() callback a callback function data a JIT stack or a value to be passed to the callback function If callback is NULL and data is NULL, an internal 32K block on the machine stack is used. If callback is NULL and data is not NULL, data must be a valid JIT stack, the result of calling pcre[16]_jit_stack_alloc(). If callback not NULL, it is called with data as an argument at the start of matching, in order to set up a JIT stack. If the result is NULL, the internal 32K stack is used; otherwise the return value must be a valid JIT stack, the result of calling pcre[16]_jit_stack_alloc(). You may safely assign the same JIT stack to multiple patterns, as long as they are all matched in the same thread. In a multithread appli- cation, each thread must use its own JIT stack. For more details, see the pcrejit page. There is a complete description of the PCRE native API in the pcreapi page and a description of the POSIX API in the pcreposix page. PCRE_ASSIGN_JIT_STACK(3)
Man Page