Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!wuarchive!uunet!mcsun!ukc!axion!uzi-9mm.fulcrum.bt.co.uk!igb From: igb@fulcrum.bt.co.uk (Ian G Batten) Newsgroups: comp.bugs.sys5 Subject: SVR3 Utilities (Was: Re: small bug in who(1) of SVR3) Message-ID: Date: 15 Jan 91 09:32:28 GMT References: <1991Jan13.004843.18650@zoo.toronto.edu> <18899@rpp386.cactus.org> <1991Jan14.202053.20054@zoo.toronto.edu> Sender: isode@fulcrum.bt.co.uk (Isode Hackers) Organization: BT Fulcrum, Birmingham Lines: 29 In article <1991Jan14.202053.20054@zoo.toronto.edu> henry@zoo.toronto.edu (Henry Spencer) writes: > Incidentally, it turns out that one can often rewrite Berkeley or AT&T > C programs as shell files and find that they run *faster*. I don't doubt it. I had to use ``sum'' in a small utility and was shocked at its performance. When I rewrote it as a function --- rather than running it down a pipe --- and removed some obvious infelicitudes it ran about three times faster. That with, oh, half an hour's effort. Script started on Tue Jan 15 09:27:34 1991 $ time sum /unix 23454 2098 /unix real 3.2 user 2.3 sys 0.8 $ time ./csm /unix 23454 2098 real 1.1 user 0.3 sys 0.7 $ script done on Tue Jan 15 09:27:53 1991 Other commands are as bad. [[ This on a machine using gcc as the only compiler, as well! ]] ian