grepping for "Subject" in /usr/spool/news

Henry Spencer henry at utzoo.UUCP
Fri Oct 5 01:26:42 AEST 1984


> ....  Folks may recall articles
> that went around a while back asking why "grep" wasn't smart enough to use
> the "fast fgrep" algorithm when appropriate.  The above results show that
> grep may be smarter than was thought.

It's been well-known for quite a while that fgrep is the slowest of the
three greps for simple cases.  It really shines only when the list of
words it is looking for is substantial, in which case it is much faster
than the others (assuming you can even convince the others to work under
those conditions).

The Bell folks are rumored to have developed/discovered a new matching
algorithm that invalidates the "we don't know a single algorithm that
spans a wide enough range of space-time tradeoffs" comment in the grep
manual page; anybody know anything about this?  References?
-- 
				Henry Spencer @ U of Toronto Zoology
				{allegra,ihnp4,linus,decvax}!utzoo!henry



More information about the Comp.unix mailing list