From: James Chapman <jchapman@katalix.com>
To: hadi@cyberus.ca, Bill Fink <billfink@mindspring.com>
Cc: netdev@vger.kernel.org, davem@davemloft.net, jeff@garzik.org,
mandeep.baines@gmail.com, ossthema@de.ibm.com,
Stephen Hemminger <shemminger@osdl.org>
Subject: Re: RFC: possible NAPI improvements to reduce interrupt rates for low traffic rates
Date: Wed, 12 Sep 2007 14:50:01 +0100 [thread overview]
Message-ID: <46E7EE89.9060006@katalix.com> (raw)
In-Reply-To: <1189599142.4326.38.camel@localhost>
jamal wrote:
> On Wed, 2007-12-09 at 03:04 -0400, Bill Fink wrote:
>> On Fri, 07 Sep 2007, jamal wrote:
>
>>> I am going to be the devil's advocate[1]:
>> So let me be the angel's advocate. :-)
>
> I think this would make you God's advocate ;->
> (http://en.wikipedia.org/wiki/God%27s_advocate)
>
>> I view his results much more favorably.
>
> The challenge is, under _low traffic_: bad bad CPU use.
> Thats what is at stake, correct?
By low traffic, I assume you mean a rate at which the NAPI driver
doesn't stay in polled mode. The problem is that that rate is getting
higher all the time, as interface and CPU speeds increase. This results
in too many interrupts and NAPI thrashing in/out of polled mode very
quickly.
> Lets bury the stats for a sec ...
Yes please. We need an analysis of what happens to cpu usage, latency,
pps etc when various factors are changed, e.g. input pps, NAPI busy-idle
delay etc. The main purpose of my RFC wasn't to push a patch into the
kernel right now, it was to highlight the issue and to find out if
others were already working on it. The feedback has been good so far. I
just need to find some time to do some testing. :)
> People are bitching about NAPI abusing CPU, is the
> answer to abuse more CPU than NAPI?;->
Jamal, do you have more details? Are people saying NAPI gets too much of
the CPU pie because they profiled it? Are they complaining that system
behavior degrades too much under certain network traffic conditions?
Mouse cursor movement jittery? Real-time apps such as music/video
players starved of CPU? Is it possible they blame NAPI because they see
tangible effects on their system, not because measured CPU usage is
high? I say this because my music/video player and mouse cursor behave
_much_ better with my NAPI changes during general use, despite the
increase in measured cpu load. Even ftp can make my system's mouse
cursor jitter...
> The answer could be "I am not solving that problem anymore" - at least
> thats what James is saying;->
I'm investigating whether the symptoms I describe above can be reduced
or eliminated without resorting to hardware interrupt mitigation.
Specifically, I want to do more testing on the idle polling scheme which
seems to improve system behavior in my tests. This will involve more
than doing a flood ping or two. :)
>> Sometimes there
>> are tradeoffs to be made to be decided by the user based on what's most
>> important to that user and his specific workload. And the suggested
>> ethtool option (defaulting to current behavior) would enable the user
>> to make that decision.
>
> And the challenge is:
> What workload is willing to invest that much cpu for low traffic?
> Can you name one? One that may come close is database benchmarks for
> latency - but those folks wouldnt touch this with a mile-long pole if
> you told them their cpu use is going to get worse than what NAPI (that
> big bad CPU hog under low traffic) is giving them.
I agree with both of you. But we need more test results first to know
whether it will be useful to offer NAPI idle polling as an _option_.
--
James Chapman
Katalix Systems Ltd
http://www.katalix.com
Catalysts for your Embedded Linux software development
next prev parent reply other threads:[~2007-09-12 13:50 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-06 14:16 RFC: possible NAPI improvements to reduce interrupt rates for low traffic rates James Chapman
2007-09-06 14:37 ` Stephen Hemminger
2007-09-06 15:30 ` James Chapman
2007-09-06 15:37 ` Stephen Hemminger
2007-09-06 16:07 ` James Chapman
2007-09-06 23:06 ` jamal
2007-09-07 9:31 ` James Chapman
2007-09-07 13:22 ` jamal
2007-09-10 9:20 ` James Chapman
2007-09-10 12:27 ` jamal
2007-09-12 7:04 ` Bill Fink
2007-09-12 12:12 ` jamal
2007-09-12 13:50 ` James Chapman [this message]
2007-09-12 14:02 ` Stephen Hemminger
2007-09-12 16:26 ` James Chapman
2007-09-12 16:47 ` Mandeep Baines
2007-09-13 6:57 ` David Miller
2007-09-14 13:14 ` jamal
2007-09-07 21:20 ` Jason Lunz
2007-09-10 9:25 ` James Chapman
2007-09-07 3:55 ` Mandeep Singh Baines
2007-09-07 9:38 ` James Chapman
2007-09-08 16:42 ` Mandeep Singh Baines
2007-09-10 9:33 ` James Chapman
2007-09-10 12:12 ` jamal
2007-09-08 16:32 ` Andi Kleen
2007-09-10 9:25 ` James Chapman
2007-09-12 15:12 ` David Miller
2007-09-12 16:39 ` James Chapman
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=46E7EE89.9060006@katalix.com \
--to=jchapman@katalix.com \
--cc=billfink@mindspring.com \
--cc=davem@davemloft.net \
--cc=hadi@cyberus.ca \
--cc=jeff@garzik.org \
--cc=mandeep.baines@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=ossthema@de.ibm.com \
--cc=shemminger@osdl.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;
as well as URLs for NNTP newsgroup(s).