Hi,

I am sorry I forgot to reply. Philip guess was right, JIT can only use 64K 
machine stack, and it cannot compile the pattern if it runs out of it. The 
exact rules are not documented since they may change any time when new 
optimizations are introduced (e.g. a capturing bracket may use 2 or 3 machine 
words depending on certain conditions). Currently each a* uses two machine 
words (16 bytes on 64 bit). I suggest to split your patterns to smaller ones, 
and do multiple matches. In general JIT can reject any patterns (e.g. it 
rejects \C), and there are tests for rejected patterns in the test suite.

Regards,
Zoltan

ND <nad...@mail.ru> írta:
>On 2015-10-25 17:53, ph10 wrote:
>> On Tue, 20 Oct 2015, ND wrote:
>>> This pattern is 8426 times repeated '.*a'
>> > Why there is no '(JIT)' in answer. Why JIT don't work for this pattern?
>>I'm guessing, but I suspect the pattern is just too big. If you run it 
>> under pcretest with the -i option you get:
>>Capturing subpattern count = 0
>> Options: anchored caseless extended multiline dotall
>> No first char
>> Need char = 'a' (caseless)
>> Subject length lower bound = 8428
>> No starting char list
>> JIT study was not successful
>>If you make it a lot shorter, JIT does compile it.
>>
>
>
>Thanks. I use many giant patterns. How can I be sure that JIT can work  
>with they? What conditions are? Maximum pattern length in bytes or some  
>else?
>
>I found no docs about this silent JIT-off.
>
>Can you clarify this please?
>
>-- 
>## List details at https://lists.exim.org/mailman/listinfo/pcre-dev 


-- 
## List details at https://lists.exim.org/mailman/listinfo/pcre-dev 

Reply via email to