Re: aio-core in 2.5 - io_queue_wait and io_getevents

Suparna Bhattacharya
2002-09-03T12:18:41Z

Changed the title to reflect the latest discussion. Just wanted
to comment on the nwait bit.

On Mon, Sep 02, 2002 at 08:40:43PM +0200, Andrea Arcangeli wrote:
>
> then about the 2.5 API we have such min_nr that allows the "at least
> min_nr", instead of the previous default of "at least 1", so that it
> allows implementing the aio_nwait of aix.

Partly, in the sense that the implementation still doesn't avoid
extra wakeups when less than min_nr events are available at a time
(if we are unlucky enough to have the min_nr events dripping in
slowly one at a time, we'd still have all those context switches,
won't we ?), though it saves on the extra user-kernel transitions
on those wakeups compared to if this were implemented in user-space
over an at-least-one primitive.

It is possible to play around with the implementation later though.
The important bit is having "at least N" in the interface exported
by the kernel, which is good.

Regards
Suparna

> Andrea