Re: Timings for optimised poll(2)

Richard Gooch (rgooch@atnf.CSIRO.AU)
Wed, 27 Aug 1997 14:05:53 +1000


James Mastros writes:
> On Tue, 26 Aug 1997, Richard Gooch wrote:
> [...]
> > Test 1: checking descriptors 24-1023:
> > select: 2202 microseconds
> > poll: 2680 microseconds
> > poll2: 2140 microseconds
> >
> > Test 2: checking descriptors 924-1023:
> > select: 513 microseconds
> > poll: 278 microseconds
> > poll2: 224 microseconds
> >
> > Test 3: checking descriptors 1014-1023:
> > select: 323 microseconds
> > poll: 60 microseconds
> > poll2: 47 microseconds
> [...]
>
> You missed an important test: a random 25% of fds 4-1023 (the same random
> set for all three, naturally). This (it would seem to me) is closest to
> what real-life programs do. Also, I have the feeling that gcc will optmize
> bitfeilds such that 101 is much slower than 011.

Yes, I know there are a number of other tests that still need t be
done. I think a random 1% is more common, but that can be a simple
parameter... no reason not to run a handfull of tests.
I don't intend to do any more benchmarks until the existing
bottlenecks are removed (i.e. use a poll_events field in struct file
rather than call the indirect poll function).
Stay tuned for a few patches that fix this...

Regards,

Richard....