This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author neologix
Recipients giampaolo.rodola, neologix, python-dev, sbt
Date 2013-09-06.19:01:00
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <CAH_1eM11fdekYtpqtS484rcgrOebrER1TP4vnoPQbrNGReup_w@mail.gmail.com>
In-reply-to <CAH_1eM3dEZ9YhrFWmojW2L=xMp5Gq1OHZZDk_Bd_g5MEbrcdHA@mail.gmail.com>
Content
I just realized that using DefaultSelector isn't optimal for Connection:
It's fine for forkserver, since it's a long lived process, but for
Connection.poll(), this means that it'll use epoll or kqueue: which
means allocating a new epoll/kqueue object for each conn.poll().
That's a couple syscalls more (epoll_create()/epoll_ctl()/close()),
but most important it uses an extra FD per connection.

The attached patch uses PollSelector if available, otherwise SelectSelector.
Files
File name Uploaded
connection_selector.diff neologix, 2013-09-06.19:01:00
History
Date User Action Args
2013-09-06 19:01:01neologixsetrecipients: + neologix, giampaolo.rodola, python-dev, sbt
2013-09-06 19:01:01neologixlinkissue18934 messages
2013-09-06 19:01:00neologixcreate