From 1bdb4eda0d868223bd6b3d92db4545a02f5e14f9 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 26 Feb 2013 21:02:34 +0000 Subject: epoll/*: remove user-space array as active queue This prevents pathological starvation cases where the user-space ready-list can be repopulated infinitely. With EPOLLONESHOT, epoll itself may be used for this task (at a slightly higher cost) by enabling read/write checks, as the epoll ready-list preserves event ordering when used with EPOLLONESHOT. --- lib/rainbows/xepoll/client.rb | 3 --- 1 file changed, 3 deletions(-) (limited to 'lib/rainbows/xepoll') diff --git a/lib/rainbows/xepoll/client.rb b/lib/rainbows/xepoll/client.rb index 4f15a73..f518db5 100644 --- a/lib/rainbows/xepoll/client.rb +++ b/lib/rainbows/xepoll/client.rb @@ -27,9 +27,6 @@ module Rainbows::XEpoll::Client def self.loop begin EP.wait(nil, 1000) { |_, obj| obj.epoll_run } - while obj = ReRun.shift - obj.epoll_run - end Rainbows::Epoll::Client.expire rescue Errno::EINTR rescue => e -- cgit v1.2.3-24-ge0c7