[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1317022420.9084.57.camel@twins>
Date: Mon, 26 Sep 2011 09:33:40 +0200
From: Peter Zijlstra <a.p.zijlstra@...llo.nl>
To: Gilad Ben-Yossef <gilad@...yossef.com>
Cc: linux-kernel@...r.kernel.org,
Frederic Weisbecker <fweisbec@...il.com>,
Russell King <linux@....linux.org.uk>,
Chris Metcalf <cmetcalf@...era.com>, linux-mm@...ck.org,
Christoph Lameter <cl@...ux-foundation.org>,
Pekka Enberg <penberg@...nel.org>,
Matt Mackall <mpm@...enic.com>
Subject: Re: [PATCH 5/5] slub: Only IPI CPUs that have per cpu obj to flush
On Sun, 2011-09-25 at 11:54 +0300, Gilad Ben-Yossef wrote:
> + if (likely(zalloc_cpumask_var(&cpus, GFP_ATOMIC))) {
> + for_each_online_cpu(cpu) {
> + c = per_cpu_ptr(s->cpu_slab, cpu);
> + if (c && c->page)
> + cpumask_set_cpu(cpu, cpus);
> + }
> + on_each_cpu_mask(cpus, flush_cpu_slab, s, 1);
> + free_cpumask_var(cpus);
Right, having to do that for_each_oneline_cpu() loop only to then IPI
them can cause a massive cacheline bounce fest.. Ideally you'd want to
keep a cpumask per kmem_cache, although I bet the memory overhead of
that isn't attractive.
Also, what Pekka says, having that alloc here isn't good either.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists