[lkml]   [1999]   [Sep]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: POSIX aio vs completion ports
Steve Underwood writes:
> Completion ports have one substantial benefit over the POSIX RT
> signal queues - they will never overflow. Messy, and ultimately
> somewhat futile, schemes for recovering from overflows are
> unnecessary. It seems to me that any recovery is going to be slow,
> and maybe a little unpredictable. This will be happening at a very
> busy time (otherwise there wouldn't have been an overflow), so
> clumsy recoveries just won't cut it.

Fundamentally, this is just a matter of allocating sufficient buffer
space. If you experience an overflow, increase the buffer space.

And if you think about it, you'll realise that completion ports have
the same problem, just pushed back a bit. If for each event you have
to allocate an entry in the queue, your allocation may either:
- fail due to insufficient resources
- block until resources are available.

The former case is just like Linux RT signal queues. The latter means
the problem is pushed deeper into the networking code. If you block,
you're going to have trouble receiving new packets, because you're
already in a low-memory situation. Hence you start dropping packets.

So you have the choice of dropping notification events (with a safe
recovery method), or you can drop data. I know which I'd prefer...



To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:53    [W:0.036 / U:5.160 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site