[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-zile] Incremental search is dog slow in moderately-sized files

From: Reuben Thomas
Subject: Re: [Bug-zile] Incremental search is dog slow in moderately-sized files
Date: Tue, 21 Jan 2014 14:34:07 +0000

On 21 January 2014 12:12, Reuben Thomas <address@hidden> wrote:
On 21 January 2014 09:53, Gary V. Vaughan <address@hidden> wrote:
It took several hours of debugging, but finally I discovered that estr:line calls astr:find with out-of-bounds arguments at the end of a loop, expecting to get back a `nil`.  Adding guards to find and rfind and returning nil rather than letting memchr/memrchr race through random memory outside of the allocated buffer has fixed both my occasional crash in find, and the major test breakage in memrchr on Travis.  There are probably other instances of that assumption, but I guess I'll have a better chance of teasing those out as I spec out the apis with Specl in the coming months.

…and Zee has done away with estrs, hence no problem there.

You should be able to copy the memrchr + fallback code into Zee now to get a version that works on non-glibc systems :)  I still need to fix it to work with CRLF line endings in Zile, but that isn't something Zee supports.

Great, thanks!

I've done this. There are apparently some bugs similar to those you found in Zile, but a bit of testing showed those were already present, so I've not worried about it too much for now.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]