Hi all,<br>
<br>
I've implemented a patch,&nbsp; please visit bug 1366311 for details. <br>
<br>
<a onclick="return top.js.OpenExtLink(window,event,this)" href="https://sourceforge.net/tracker/?func=detail&amp;atid=105470&amp;aid=1366311&amp;group_id=5470" target="_blank">https://sourceforge.net/tracker/?func=detail&amp;atid=105470&amp;aid=1366311&amp;group_id=5470
</a><br>
<br>This patch only release the GIL when the engine perform a low level
search *and* if the object searched is a string or a unicode string.
The GIL will not be released for any other kind of objects, as there is
no guarantee of immutability of the buffer during the run.<br>
<br>
I've tested this with a couple of simple tests, and also by running the
application Duncan talked about. My testing indicates that everything
works as before with the added value that our application is still responsive even
when processing some of the more egregious regular expressions.<br>
<br>
As it is my first foray into python module writing I'll welcome any feedback you may have on the patch.<br>
<br>
Regards,<br>
-- Eric<br>
<br><br><div><span class="gmail_quote">On 11/25/05, <b class="gmail_sendername">Fredrik Lundh</b> &lt;<a href="mailto:fredrik@pythonware.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">fredrik@pythonware.com
</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Martin v. Löwis wrote:<br><br>&gt; Formally: no; it access a Python string/Python unicode object all<br>&gt; the time.<br>&gt;<br>&gt; Now, since all the shared objects it accesses are immutable, likely<br>&gt; no harm would be done releasing the GIL. I think SRE was originally
<br>&gt; also intended to operate on array.array objects; this would have<br>&gt; caused bigger problems.<br><br>SRE can operate on anything that implements the buffer interface.<br><br>&lt;/F&gt;<br><br>
</blockquote></div><br>