From: Nikolai ZHUBR <zhubr@mail.ru>
To: Davide Libenzi <davidel@xmailserver.org>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re[3]: epoll'ing tcp sockets for reading
Date: Sun, 20 Dec 2009 03:26:10 +0300 [thread overview]
Message-ID: <1059651918.20091220032610@mail.ru> (raw)
In-Reply-To: <alpine.DEB.2.00.0912191437530.4482@makko.or.mcafeemobile.com>
Sunday, December 20, 2009, 1:56:22 AM, Davide Libenzi wrote:
[trim]
> The kernel cannot make decisions based on something whose knowledge is
> userspace bound.
I didn't mean that. I just meant it would be usefull to let the caller
of epoll know also the size of data related to specific EPOLLIN event in
some "atomic" manner immediately, because the kernel probably knows this
size already.
The same thing can approximately be "emulated" by requesting FIOREAD for
all EPOLLIN-ready sockets just after epoll returns, before any other work.
It just would look not very elegant IMHO.
> What you define as "abstract/imprecise/overcomplicated" are simply
> decisions that you, as implementor of the upper layer protocol, have to
> take in order to implement your userspace code.
> And I, personally, see nothing even close to be defined complicated in
> such code.
> Whenever you're asking for an abstraction/API to implement a kind
> of software which exist in large quantities on a system, you've got to ask
> yourself how relevant such abstraction is at the end, if all the existing
> software have done w/out it.
Ok, maybe that's what I should have asked at the first place. What would
you recommend as a reference implementation showing clean, efficient,
fail-safe usage of epoll with sockets?
Actually I've been googling for about 2 weeks to find some, but the results
are rather scarce and dubious.
Thank you!
Nikolai ZHUBR
> - Davide
next prev parent reply other threads:[~2009-12-20 0:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-12-19 12:02 epoll'ing tcp sockets for reading Nikolai ZHUBR
2009-12-19 18:07 ` Davide Libenzi
2009-12-19 22:38 ` Re[2]: " Nikolai ZHUBR
2009-12-19 22:56 ` Davide Libenzi
2009-12-20 0:26 ` Nikolai ZHUBR [this message]
2009-12-20 15:54 ` Re[3]: " Davide Libenzi
2009-12-20 16:14 ` Willy Tarreau
2009-12-20 23:26 ` Re[2]: " Nikolai ZHUBR
2009-12-21 5:46 ` Willy Tarreau
2009-12-21 9:34 ` Re[2]: " Nikolai ZHUBR
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1059651918.20091220032610@mail.ru \
--to=zhubr@mail.ru \
--cc=davidel@xmailserver.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox