mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Shai Fultheim" <shai@scalex86.org>
To: "'Andrew Morton'" <akpm@osdl.org>
Cc: <anton@samba.org>, <linux-kernel@vger.kernel.org>,
	<jes@trained-monkey.org>, <mort@wildopensource.com>
Subject: RE: [PATCH] PER_CPU [4/4] - PER_CPU-irq_stat
Date: Sun, 11 Jul 2004 22:19:42 -0700	[thread overview]
Message-ID: <S266732AbUGLFT6/20040712051958Z+1468@vger.kernel.org> (raw)
In-Reply-To: <20040711221126.198ec0ac.akpm@osdl.org>

"Andrew Morton" <akpm@osdl.org>:
> 
> "Shai Fultheim" <shai@scalex86.org> wrote:
> >
> > > > diff -Nru a/kernel/softirq.c b/kernel/softirq.c
> > > > --- a/kernel/softirq.c	2004-07-09 01:34:13 -07:00
> > > > +++ b/kernel/softirq.c	2004-07-09 01:34:13 -07:00
> > > > @@ -36,8 +36,8 @@
> > > >   */
> > > >
> > > >  #ifndef __ARCH_IRQ_STAT
> > > > -irq_cpustat_t irq_stat[NR_CPUS] ____cacheline_aligned;
> > > > -EXPORT_SYMBOL(irq_stat);
> > > > +DEFINE_PER_CPU(irq_cpustat_t, irq_stat)
> > > ____cacheline_maxaligned_in_smp;
> > > > +EXPORT_PER_CPU_SYMBOL(irq_stat);
> > > >  #endif
> > >
> > > Is there a need for the cacheline alignment? We want to keep that per
> > > cpu data area as packed as possible, we only want to explicitly pad if
> > > we need to (eg other cpus are accessing that variable a lot).
> > >
> > > Also it looks like we will have to push the above change into the
> other
> > > architectures.
> > >
> > > Anton
> > >
> >
> > IMHO, we want to keep irq_stat aligned from performance perspectives.
> You
> > can never know if the info before and after it in the per-cpu area are
> going
> > to be cached (and thefore crossing cache-line boundary will cost us
> more).
> >
> > Anyhow, since that also accesses by other CPUs (not a lot...), I think
> it's
> > better to keep it aligned (the utilization of per-cpu areas is so low
> now
> > that it doesn't really matter).
> >
> 
> That seems a bit debatable.
> 
> But anyway, as Anton points out, the patch breaks !x86 architectures.
> 

It seems that I missed that, will send update soon.
 
-----------------
Shai Fultheim
Scalex86.org


  reply	other threads:[~2004-07-12  5:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-09  9:54 Shai Fultheim
2004-07-12  0:02 ` Anton Blanchard
2004-07-12  4:44   ` Shai Fultheim
     [not found]   ` <200407120444.i6C4iAws031156@fire-2.osdl.org>
2004-07-12  5:11     ` Andrew Morton
2004-07-12  5:19       ` Shai Fultheim [this message]
     [not found]   ` <20040712044410.46293162B72@lists.samba.org>
2004-07-12  8:57     ` Anton Blanchard

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=S266732AbUGLFT6/20040712051958Z+1468@vger.kernel.org \
    --to=shai@scalex86.org \
    --cc=akpm@osdl.org \
    --cc=anton@samba.org \
    --cc=jes@trained-monkey.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mort@wildopensource.com \
    /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

all inboxes | Powered by JetHome®