Date: Sun, 15 Aug 2010 01:04:52 +0200 From: Ivan Voras <ivoras@freebsd.org> To: freebsd-current@freebsd.org Subject: Re: Official request: Please make GNU grep the default Message-ID: <i477eo$i4d$1@dough.gmane.org> In-Reply-To: <4C651192.9020403@FreeBSD.org> References: <4C6505A4.9060203@FreeBSD.org> <4C650B75.3020800@FreeBSD.org> <4C651192.9020403@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On 13.8.2010 11:34, Doug Barton wrote: > On 08/13/2010 02:08, Gabor Kovesdan wrote: >> Ok, I'll take care of this soon, and make GNU grep default, again with a >> knob to build BSD grep. I agree with you that we cannot allow such a big >> performance drawback but I my measures only showed significant >> differences for very big searches and I didn't imagine that it could add >> up to such a big diference. > > To be fair, I didn't notice a performance difference either until I > started revamping this code that calls my parse_index() for every single > installed port. Given a 22,042 line INDEX file, that's enough to add up > to something noticeable. Wouldn't this might, just might, be an indication that one of the following is true: 1) writing complex performance-sensitive utilities in shell code simply sucks because it's too sensitive to issues like borderline behaviours of utilities 2) implementing complex data structures that might save you reparsing on the order of complexity of O(npkg * nlines) is too demanding in shell code and this means it's not exactly the best tool for the job ? This post brought to you by The Legue for Retiring Shell Scripts Longer Than 100 Lines - our motto is "Fighting against the tide - why not?" :)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?i477eo$i4d$1>