[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87ab60rh8t.fsf@basil.nowhere.org>
Date: Tue, 28 Apr 2009 16:21:38 +0200
From: Andi Kleen <andi@...stfloor.org>
To: Eric Dumazet <dada1@...mosbay.com>
Cc: David Miller <davem@...emloft.net>, cl@...ux.com,
jesse.brandeburg@...el.com, netdev@...r.kernel.org,
haoki@...hat.com, mchan@...adcom.com, davidel@...ilserver.org
Subject: Re: [PATCH] poll: Avoid extra wakeups
Eric Dumazet <dada1@...mosbay.com> writes:
>
> When scheduled, thread does a full scan of all polled fds and
> can sleep again, because nothing is really available. If number
> of fds is large, this cause significant load.
I wonder if the key could be used for more state. For example if you
two processes are in recvmsg() on a socket and there's only a single
packet incoming we only need to wake up the first waiter. Could that
be done with keys too?
> This patch makes select()/poll() aware of keyed wakeups and
> useless wakeups are avoided. This reduces number of context
> switches by about 50% on some setups, and work performed
> by sofirq handlers.
I'm late, but: very cool patch too.
Acked-by: Andi Kleen <ak@...ux.intel.com>
-Andi
--
ak@...ux.intel.com -- Speaking for myself only.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists