time test
David Relson
relson at osagesoftware.com
Sun Nov 24 14:36:18 CET 2002
At 07:42 AM 11/24/02, Greg Louis wrote:
>On 20021123 (Sat) at 1807:40 -0500, David Relson wrote:
>
> > For laughs, I built bogofilter with four different optimization
> > levels. The compiler switches used were '-G' (no optimization), '-O1,
> > '-O2', and '-O3'. bogofilter was run 1000 times on a test message.
> >
> > g O1 O2 O3
> > user 18.17 15.69 15.05 14.89
> > system 3.24 3.40 3.17 3.11
> > elapsed 21.44 19.32 18.23 18.00
> >
> > It appears that maximum speed is about 1/7 (14%) better than worst code.
> >
> > Notes: tests run on 500 mhz Pentium III with 256mb ram, kernel
> > linux-2.4.19-16mdk.
>
>On reading the above, I decided "just for kicks" to try my
>0.8.0-derived production version with -O3. Variation from run to run
>of the "time" command is about 2% so it's hard to be sure, but any two
>adjacent runs (alternating between -O2 and -O3) show the -O3 version
>(./bogofilter) being about 35-50 microseconds (~1%) faster:
>
># time for i in `seq 1 2000`; do bogofilter </root/testmsg; done
>
>real 0m15.290s user 0m10.650s sys 0m4.610s
>
># time for i in `seq 1 2000`; do ./bogofilter </root/testmsg; done
>
>real 0m15.218s user 0m10.590s sys 0m4.600s
Given you're running 2000 reps in 15 sec, vs my 1000 in 18, you're running
bogofilter about 2.4 times faster than I am. Interesting.
>That's on a 1.1 GHz (500 millihertz is a bit slow, no? :) PIII/mobile with
>512Mb RAM / kernel 2.4.20-rc2-ac3.
When I got the machine 3 years ago, the state of the art was about 2 speed
steps faster than 500 mhz, which made the cost/performance ration of 500
mhz very attractive. I've had no need since then to upgrade, though some
of the large bogofilter tests of the last 2 months have got me thinking
about upgrading to a dual athlon 1.0+ ghz. However finances are tight and
I can't justify that.
More information about the Bogofilter
mailing list