Re: [pcre-dev] JIT access violation

Góra strony
Delete this message
Autor: Ralf Junker
Data:  
CC: pcre-dev@exim.org
Temat: Re: [pcre-dev] JIT access violation
On 13.05.2013 12:36, Zoltán Herczeg wrote:

> this is quite interesting. Am I see right, that your pattern only
> contains two fixed characters (backslash and space)? On a 32 bit
> Linux system, in 8 bit mode, that is 67 bytes long (56 bytes for
> header, 11 for pattern) instead of 69. That read access reads byte
> 63, which is perfect.


The pattern contains, without leading / trailing slahes:

\Q\ \E

The core pattern is one backslash and one space each.

> This is the interesting part: size = sizeof(REAL_PCRE) + (length +
> cd->names_found * cd->name_entry_size) * sizeof(pcre_uchar);
>
> Could you print sizeof(REAL_PCRE), length, and size here?


After this line, the numbers are as follows:

  sizeof(REAL_PCRE) = 56
  length            = 13
  size              = 69


I now remember that I compiled with LINK_SIZE=3. Does this matter?

Yes, it does. If I recompile with LINK_SIZE=2 (the default), I get these
numbers:

  sizeof(REAL_PCRE) = 56
  length            = 11
  size              = 67


Does this help?

Ralf