Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [BUG] Long line makes pattern matching (by //) hog Zsh
- X-seq: zsh-workers 38620
- From: Sebastian Gniazdowski <sgniazdowski@xxxxxxxxx>
- To: Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
- Subject: Re: [BUG] Long line makes pattern matching (by //) hog Zsh
- Date: Sun, 5 Jun 2016 23:21:13 +0200
- Cc: Zsh hackers list <zsh-workers@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=xdRCvoPGx208bAfggi+UtvoaKEJcomM2xgewuV92qsY=; b=B4K/Rsg6I9Dbtr4sGXu+eiJchoSVyv8osDI79VdpjpIfYszt8yD7pGOuRM3te7CUlJ pmb/2K6IoBzC0TlPcIC/xK6EsxR1mgo3uR9V5z3XIS6w5xzRoF1laQlP6wHx+Pf6RHhr BqeD4LdejX4vxmT4A3IXh8BGVxFV6Mz6ayibJzvgeyMXKCqI/NZShoF6eshOubEoIbng LgOshc+q6Wt3/PC9Jn53nR5l089oNsxwxkpRxL9ua7eVDwT4v9UZZZvJRsL7Kgz2PHGt ChpP6FSB80tNqP+odJXsM73GWpjlpFw0znr1SD21XoQrduUOR0NYVLpRfKbDqg1eBk1n lZqw==
- In-reply-to: <20160605213951.4af7294a@ntlworld.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CAKc7PVC=AES1LhY7tYTXrPsefX3CXgtUsxiVbDaxmc5o2iHnVw@mail.gmail.com> <160605121020.ZM7727@torch.brasslantern.com> <20160605203708.3701c7a2@ntlworld.com> <20160605213951.4af7294a@ntlworld.com>
On 5 June 2016 at 22:39, Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx> wrote:
> We are maybe being naive in treating [...] expressions as if they are
> "simple". I think we have better protection against pathological
> backtracking for more complicated patterns.
>
> Does the following help?
It's slower with this patch:
3,02s user 0,02s system 99% cpu 3,064 total
vs
1,55s user 0,24s system 93% cpu 1,909 total
for pattern with first segment removed, i.e.: ([^0-9/\\\\ ]##[^/\\\\]#(#e))
Best regards,
Sebastian Gniazdowski
Messages sorted by:
Reverse Date,
Date,
Thread,
Author