Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:87271 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 90836 invoked from network); 24 Jul 2015 12:58:10 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 24 Jul 2015 12:58:10 -0000 Authentication-Results: pb1.pair.com smtp.mail=pierre.php@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=pierre.php@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.192.54 as permitted sender) X-PHP-List-Original-Sender: pierre.php@gmail.com X-Host-Fingerprint: 209.85.192.54 mail-qg0-f54.google.com Received: from [209.85.192.54] ([209.85.192.54:36014] helo=mail-qg0-f54.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 04/D4-57278-06632B55 for ; Fri, 24 Jul 2015 08:58:09 -0400 Received: by qgy5 with SMTP id 5so9949197qgy.3 for ; Fri, 24 Jul 2015 05:58:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=V0SeZEiFwOo/YL01GZDt8L/X8Sk4vMUZpEoIqjn9+mk=; b=mhZMDsPwdtuPov+bbR5udi1TLGKz0CX/iVKEBGX98I0LQCDk2IlSN9o4lDgg081UNz w9CvaRkrhOEXhI4nxOLk7TmxEY6hn6ffR46fI8+mG9lO1JzWONSa/wpL4dhEHX0QH4HZ l8YTQoccx3a1Y/LYrLvKbsCQ4yoWq3VXwDNpFlV89ZfiY0M2+DuVPhOc7v1n6jPlOnUm gQa/nTtsD+oRC2DUq8FrUl76s20B40BEbVZpvgoznkCb0MtsW262PIxYUmYC4PVFXQb6 HUrWH3pPV4bNLDrom0p4wE8i0z8YhHI3iy0KGf1SWt6eWhT+KJer5am0Cykzjqhx7ysN OxTQ== MIME-Version: 1.0 X-Received: by 10.140.40.38 with SMTP id w35mr20235363qgw.96.1437742685878; Fri, 24 Jul 2015 05:58:05 -0700 (PDT) Received: by 10.96.151.5 with HTTP; Fri, 24 Jul 2015 05:58:05 -0700 (PDT) Received: by 10.96.151.5 with HTTP; Fri, 24 Jul 2015 05:58:05 -0700 (PDT) In-Reply-To: <787E3411-1213-44C0-809D-D1D8CA89277A@heroku.com> References: <55B0CADD.8000807@gmx.de> <55B136BE.8010006@gmx.de> <787E3411-1213-44C0-809D-D1D8CA89277A@heroku.com> Date: Fri, 24 Jul 2015 19:58:05 +0700 Message-ID: To: David Zuelke Cc: Christoph Becker , Adam Harvey , PHP internals Content-Type: multipart/alternative; boundary=001a11c11776120255051b9e8eee Subject: Re: [PHP-DEV] PCRE JIT stack size limit From: pierre.php@gmail.com (Pierre Joye) --001a11c11776120255051b9e8eee Content-Type: text/plain; charset=UTF-8 On Jul 24, 2015 3:32 PM, "David Zuelke" wrote: > > On 24.07.2015, at 09:33, Adam Harvey wrote: > > > > On 23 July 2015 at 11:47, Christoph Becker wrote: > > > >> Therefore I tend to prefer a new ini setting (say, pcre.jitstack_limit). > >> That would mean, however, to add yet another ini setting, of which > >> there are already so many. > > > > I'm not a big fan of that, although it's at least in the spirit of > > what configuration settings are meant to be used for. > > > > What if we added the PCRE_ERROR_JIT_STACKLIMIT error constant to those > > exposed to userland so that it's more easily noticed via > > preg_last_error(), and adding a modifier that can be used to disable > > the JIT on a per-pattern basis (by setting PCRE_NO_START_OPTIMIZE, > > which admittedly disables other stuff too, but at least the regex will > > run)? At least then users could check the error when the regex fails > > and re-run the regex without the JIT if they chose to. > > But this might mean that patterns which previously worked, because no JIT was used, suddenly fail in existing code with a new error constant. Which I guess is a BC break. Such things happened in the past with normal updates, both ways. Simple code changes, fixes etc may have led to changes in the stack usage. I can remember issues with some specific updates. --001a11c11776120255051b9e8eee--