From owner-freebsd-hackers Thu Jul 29 16:56:21 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from metriclient-2.uoregon.edu (metriclient-2.uoregon.edu [128.223.172.2]) by hub.freebsd.org (Postfix) with ESMTP id CC1801564E for ; Thu, 29 Jul 1999 16:56:14 -0700 (PDT) (envelope-from gurney_j@efn.org) Received: (from jmg@localhost) by metriclient-2.uoregon.edu (8.9.1/8.8.7) id QAA24194; Thu, 29 Jul 1999 16:54:58 -0700 (PDT) Message-ID: <19990729165458.29326@hydrogen.fircrest.net> Date: Thu, 29 Jul 1999 16:54:58 -0700 From: John-Mark Gurney To: Tim Vanderhoek Cc: James Howard , "Daniel C. Sobral" , freebsd-hackers@FreeBSD.ORG Subject: Re: replacing grep(1) References: <19990729182229.E24296@mad> <19990729192330.B25978@mad> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.69 In-Reply-To: <19990729192330.B25978@mad>; from Tim Vanderhoek on Thu, Jul 29, 1999 at 07:23:30PM -0400 Reply-To: John-Mark Gurney Organization: Cu Networking X-Operating-System: FreeBSD 3.0-RELEASE i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Tim Vanderhoek scribbled this message on Jul 29: > On Thu, Jul 29, 1999 at 07:05:57PM -0400, James Howard wrote: > > > > > > > > DES tells me he has a new version (0.10) which mmap()s. It supposedly > > cuts the run time down significantly, I do not have the numbers in front > > of me. > > I do. Still far too slow. I'll work on this tomorrow, since that > seems the only way to convince people that mmap is not such a big > win. :-( I just managed to get a five time speed increase by removing an uncessary copy... and now, grep spends 50% of it's time in regexc, 37.2% of it's time in mmfgetln, and this is because of the scanning for a new line character... > Hmm... Maybe I'll even turn-out to be wrong. ;-) I really believe > mmap falls into the category of "might be nice, but not necessary and > does complicate things..." I think it is a big win... it shaved off around a half second from 3 seconds down to 2 and a half seconds... -- John-Mark Gurney Voice: +1 541 684 8449 Cu Networking P.O. Box 5693, 97405 "The soul contains in itself the event that shall presently befall it. The event is only the actualizing of its thought." -- Ralph Waldo Emerson To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message