netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Eric Dumazet <dada1@cosmosbay.com>
To: Andi Kleen <andi@firstfloor.org>
Cc: "David S. Miller" <davem@davemloft.net>,
	Linux Netdev List <netdev@vger.kernel.org>
Subject: Re: [PATCH] NET : rt_check_expire() can take a long time, add a cond_resched()
Date: Sat, 17 Nov 2007 17:23:37 +0100	[thread overview]
Message-ID: <473F1589.9080101@cosmosbay.com> (raw)
In-Reply-To: <p73fxz5auk5.fsf@bingen.suse.de>

Andi Kleen a écrit :
> Eric Dumazet <dada1@cosmosbay.com> writes:
> 
>> So it may sound unnecessary but in the rt_check_expire() case, with a
>> loop potentially doing XXX.XXX iterations, being able to bypass the
>> function call is a clear win (in my bench case, 25 ms instead of 88
>> ms). Impact on I-cache is irrelevant here as this rt_check_expires()
> 
> Measuring what? And really milli-seconds? The number does not sound plausible 
> to me.

You know Andi, I have seen production servers that needed several seconds to 
perform the flush. When you have millions of entries on this table, can you 
imagine the number of memory transactions (including atomic ops) needed to 
flush them all ?

The 25.000.000 ns and 88.000.000 ns numbers where on an empty table, but large 
(16 MB of memory)



  reply	other threads:[~2007-11-17 16:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-14 21:34 [PATCH] NET : rt_check_expire() can take a long time, add a cond_resched() Eric Dumazet
2007-11-15  0:13 ` David Miller
2007-11-15  7:30 ` Andi Kleen
2007-11-15  7:37   ` Herbert Xu
2007-11-15  8:25   ` Eric Dumazet
2007-11-15  8:57     ` David Miller
2007-11-17 13:08     ` Andi Kleen
2007-11-17 16:23       ` Eric Dumazet [this message]
2007-11-17 21:46         ` Andi Kleen
2007-11-18  0:27           ` David Miller
2007-11-15  8:52   ` David Miller

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=473F1589.9080101@cosmosbay.com \
    --to=dada1@cosmosbay.com \
    --cc=andi@firstfloor.org \
    --cc=davem@davemloft.net \
    --cc=netdev@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;
as well as URLs for NNTP newsgroup(s).