PCRE_JIT_STACK_ALLOC(3)
π NAME π
PCRE β Perl-compatible regular expressions β¨
π SYNOPSIS π
#include <pcre.h>
pcre_jit_stack *pcre_jit_stack_alloc(int startsize,
int maxsize);
pcre16_jit_stack *pcre16_jit_stack_alloc(int startsize,
int maxsize);
pcre32_jit_stack *pcre32_jit_stack_alloc(int startsize,
int maxsize);
π¦ DESCRIPTION π¦
okay bestie so listen β this function makes you a stack for the code that got compiled by the JIT optimization of pcre[16|32]_study(). that's it, that's the job π
the arguments are:
- a starting size for the stack, and
- a maximum size that it's allowed to grow up to.
and once you've got that lil stack in your hands? you can hand it over to the JIT run-time code via pcre[16|32]_assign_jit_stack(), OR that same function can set up a callback for getting a stack instead. either way works, pick your vibe π«Ά
ngl, a max stack size of 512K to 1M should be more than enough for any pattern. like, any pattern. don't overthink it, she's covered πβ¨
for more deets, go read the pcrejit page β it's giving lore.
there's a complete description of the PCRE native API in the pcreapi page, and a description of the POSIX API in the pcreposix page. yes both. go read them, they ate π
PCRE 8.30 π©· 24 June 2012 β yeah she's an icon from back in the day, still serving, still slaying, mwah π periodt.
π¦ where this page comes from
- alpine 3.22: pcre-doc 8.45-r4 Β· BSD-3-Clause
- alpine 3.23: pcre-doc 8.45-r4 Β· BSD-3-Clause
- alpine 3.24: pcre-doc 8.45-r4 Β· BSD-3-Clause
- arch rolling: pcre 8.45-5 Β· BSD
- centos-stream 9: pcre-devel 8.44-4.el9 Β· BSD
- centos-stream 9: pcre-devel 8.44-4.el9 Β· BSD
- debian bookworm: libpcre3-dev 2:8.39-15
- fedora 43: pcre-devel 8.45-1.fc43.9 Β· BSD-3-Clause
- fedora 43: pcre-devel 8.45-1.fc43.9 Β· BSD-3-Clause
- fedora 44: pcre-devel 8.45-1.fc43.9 Β· BSD-3-Clause
- fedora 44: pcre-devel 8.45-1.fc43.9 Β· BSD-3-Clause
- nixos 26.05: pcre 8.45
- nixos 26.05: pcre-cpp 8.45
- opensuse-leap 16.0: pcre-devel 8.45-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: pcre-devel 8.45-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: pcre-devel 8.45-160000.2.2 Β· BSD-3-Clause
- opensuse-leap 16.0: pcre-devel 8.45-160000.2.2 Β· BSD-3-Clause
- ubuntu jammy: libpcre3-dev 2:8.39-13build5
- ubuntu jammy: libpcre3-dev 2:8.39-13ubuntu0.22.04.1
- ubuntu noble: libpcre3-dev 2:8.39-15build1
- ubuntu questing: libpcre3-dev 2:8.39-15.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms