linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <brouer@redhat.com>
To: Christoph Lameter <cl@linux.com>
Cc: Eric Dumazet <eric.dumazet@gmail.com>,
	Joonsoo Kim <iamjoonsoo.kim@lge.com>,
	Alexander Duyck <alexander.duyck@gmail.com>,
	linux-mm@kvack.org, netdev@vger.kernel.org, brouer@redhat.com
Subject: Re: [RFC PATCH] slub: RFC: Improving SLUB performance with 38% on NO-PREEMPT
Date: Mon, 8 Jun 2015 11:58:42 +0200	[thread overview]
Message-ID: <20150608115842.694856ff@redhat.com> (raw)
In-Reply-To: <alpine.DEB.2.11.1506080438570.10781@east.gentwo.org>

On Mon, 8 Jun 2015 04:39:38 -0500 (CDT)
Christoph Lameter <cl@linux.com> wrote:

> On Mon, 8 Jun 2015, Jesper Dangaard Brouer wrote:
> 
> > My real question is if disabling local interrupts is enough to avoid this?
> 
> Yes the initial release of slub used interrupt disable in the fast paths.

Thanks for the confirmation.

For this code path we would need the save/restore variant, which is
more expensive than the local cmpxchg16b.   In case of bulking, we
should be able to use the less expensive local_irq_{disable,enable}.

Cost of local IRQ toggling (CPU E5-2695):
 *  local_irq_{disable,enable}:  7 cycles(tsc) -  2.861 ns
 *  local_irq_{save,restore}  : 37 cycles(tsc) - 14.846 ns

p.s. I'm back working on bulking API...

> > And, does local irq disabling also stop preemption?
> 
> Of course.

Thanks for confirming this.

-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Sr. Network Kernel Developer at Red Hat
  Author of http://www.iptv-analyzer.org
  LinkedIn: http://www.linkedin.com/in/brouer

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

      reply	other threads:[~2015-06-08  9:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-04 10:31 [RFC PATCH] slub: RFC: Improving SLUB performance with 38% on NO-PREEMPT Jesper Dangaard Brouer
2015-06-05  2:37 ` Eric Dumazet
2015-06-08  9:23   ` Jesper Dangaard Brouer
2015-06-08  9:39     ` Christoph Lameter
2015-06-08  9:58       ` Jesper Dangaard Brouer [this message]

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=20150608115842.694856ff@redhat.com \
    --to=brouer@redhat.com \
    --cc=alexander.duyck@gmail.com \
    --cc=cl@linux.com \
    --cc=eric.dumazet@gmail.com \
    --cc=iamjoonsoo.kim@lge.com \
    --cc=linux-mm@kvack.org \
    --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).