Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!seismo!columbia!rutgers!sri-spam!mordor!lll-tis!ames!amdahl!nsc!nsta!amos
From: amos@nsta.UUCP (Amos Shapir)
Newsgroups: comp.sources.d
Subject: Re: Fastest `grep'?? Really? - (nf)
Message-ID: <303@nsta.UUCP>
Date: Thu, 25-Jun-87 06:41:53 EDT
Article-I.D.: nsta.303
Posted: Thu Jun 25 06:41:53 1987
Date-Received: Sat, 27-Jun-87 02:11:21 EDT
References: <7200003@iaoobelix.UUCP>
Reply-To: amos%nsta@nsc.com (Amos Shapir)
Distribution: world
Organization: National Semiconductor (Israel) Ltd. Home of the 32532
Lines: 17
Summary: You have to know what to grep for
Hdate: 28 Sivan 5747



It probably depends on what you are grepping for. I tried grepping for a
simple word (i.e. no magic characters) through *.c on a source directory
- 50  files, 22k lines, 448Kb  total size - on  a vax 750 using  all the
4.3BSD  standard grep's  and the  new one.  Sys time  was about  2.2-2.3
seconds for all; execution (user) times were: fgrep - 20.4 seconds, grep
- 15.1, egrep - 11.6, and - hold on  to your seats - the new grep: 1.2 !
(yes, one-decimal-two).

Naturally, I was  just as fast installing  it. It seems the  new grep is
faster on  simple (and common)  searches; for more complicated  cases it
just exec's the appropriate old grep.
-- 
	Amos Shapir
National Semiconductor (Israel)
6 Maskit st. P.O.B. 3007, Herzlia 46104, Israel  Tel. (972)52-522261
amos%nsta@nsc.com @{hplabs,pyramid,sun,decwrl} 34 48 E / 32 10 N