Shell Scripts v. Command Options (was: Re: small bug in who(1) of SVR3)

Dan Bernstein brnstnd at kramden.acf.nyu.edu
Fri Jan 18 22:37:39 AEST 1991


In article <18946 at rpp386.cactus.org> jfh at rpp386.cactus.org (John F Haugh II) writes:
> As for performance, benchmarks will indicate the fork() is an extremely
> expensive system call.  When I was a Pinnacle Systems, one of my jobs was
> to perform benchmarks on competitors equipment.  The average system that
> I evaluated fork()'d less than 100 times per second, with many well below
> 30 or 40.  A certain 3 letter company's product fork'd about 20 times
> per second.

Your test is extremely misleading. On one system I manage, the page size
is 64K, and practically every executable is at least two pages. Guess
what? fork() takes a *noticeable* amount of real time, simply because
the machine spends so long loading from disk. But with several users
running programs from several different disks, everything overlaps
nicely and the total time spent is relatively small. I suspect the same
is true of the systems you test---every fork() takes 30 or 50 ms, but
many of them can overlap at once.

---Dan



More information about the Comp.bugs.sys5 mailing list