All of lore.kernel.org
 help / color / mirror / Atom feed
* inlined spinlocks on sparc64
@ 2009-08-13  8:20 Jens Axboe
  2009-08-13  9:08 ` David Miller
  2009-08-13 17:08 ` Heiko Carstens
  0 siblings, 2 replies; 4+ messages in thread
From: Jens Axboe @ 2009-08-13  8:20 UTC (permalink / raw)
  To: Linux Kernel, heiko.carstens; +Cc: David Miller

Hi,

I deleted the original thread, so I can't reply there. Just a heads up
on the spinlock inlining on sparc64. I decided to give your patches a
shot, since one of my IO benchmarks here basically degenerates into a
spinlock microbenchmark with > 50% time spent there (unlock part,
according to perf). Some of that is surely caching effects, but still.

For this particular workload, I get a net improvement of about 3.5% with
the inlined functions. Not bad.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: inlined spinlocks on sparc64
  2009-08-13  8:20 inlined spinlocks on sparc64 Jens Axboe
@ 2009-08-13  9:08 ` David Miller
  2009-08-13 11:56   ` Jens Axboe
  2009-08-13 17:08 ` Heiko Carstens
  1 sibling, 1 reply; 4+ messages in thread
From: David Miller @ 2009-08-13  9:08 UTC (permalink / raw)
  To: jens.axboe; +Cc: linux-kernel, heiko.carstens

From: Jens Axboe <jens.axboe@oracle.com>
Date: Thu, 13 Aug 2009 10:20:58 +0200

> I deleted the original thread, so I can't reply there. Just a heads up
> on the spinlock inlining on sparc64. I decided to give your patches a
> shot, since one of my IO benchmarks here basically degenerates into a
> spinlock microbenchmark with > 50% time spent there (unlock part,
> according to perf). Some of that is surely caching effects, but still.
> 
> For this particular workload, I get a net improvement of about 3.5% with
> the inlined functions. Not bad.

Doesn't surprise me, any function call can result in a register
window spill onto the stack, and that's 128 bytes of writes.

Later when you leave the code path you have to refill that spilled
window and you get 128 bytes of reads for each one of those.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: inlined spinlocks on sparc64
  2009-08-13  9:08 ` David Miller
@ 2009-08-13 11:56   ` Jens Axboe
  0 siblings, 0 replies; 4+ messages in thread
From: Jens Axboe @ 2009-08-13 11:56 UTC (permalink / raw)
  To: David Miller; +Cc: linux-kernel, heiko.carstens

On Thu, Aug 13 2009, David Miller wrote:
> From: Jens Axboe <jens.axboe@oracle.com>
> Date: Thu, 13 Aug 2009 10:20:58 +0200
> 
> > I deleted the original thread, so I can't reply there. Just a heads up
> > on the spinlock inlining on sparc64. I decided to give your patches a
> > shot, since one of my IO benchmarks here basically degenerates into a
> > spinlock microbenchmark with > 50% time spent there (unlock part,
> > according to perf). Some of that is surely caching effects, but still.
> > 
> > For this particular workload, I get a net improvement of about 3.5% with
> > the inlined functions. Not bad.
> 
> Doesn't surprise me, any function call can result in a register
> window spill onto the stack, and that's 128 bytes of writes.
> 
> Later when you leave the code path you have to refill that spilled
> window and you get 128 bytes of reads for each one of those.

Good thing it's not register starved ;-)

Forgot to mention that it grew my kernel image by exactly 80KB, total
size is around 5.5MB.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: inlined spinlocks on sparc64
  2009-08-13  8:20 inlined spinlocks on sparc64 Jens Axboe
  2009-08-13  9:08 ` David Miller
@ 2009-08-13 17:08 ` Heiko Carstens
  1 sibling, 0 replies; 4+ messages in thread
From: Heiko Carstens @ 2009-08-13 17:08 UTC (permalink / raw)
  To: Jens Axboe; +Cc: Linux Kernel, David Miller

On Thu, Aug 13, 2009 at 10:20:58AM +0200, Jens Axboe wrote:
> Hi,
> 
> I deleted the original thread, so I can't reply there. Just a heads up
> on the spinlock inlining on sparc64. I decided to give your patches a
> shot, since one of my IO benchmarks here basically degenerates into a
> spinlock microbenchmark with > 50% time spent there (unlock part,
> according to perf). Some of that is surely caching effects, but still.
> 
> For this particular workload, I get a net improvement of about 3.5% with
> the inlined functions. Not bad.

That sounds good! Btw. Andrew added the patches to his -mm tree, so it
looks like the patches will be merged during the next merge window.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-08-13 17:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-08-13  8:20 inlined spinlocks on sparc64 Jens Axboe
2009-08-13  9:08 ` David Miller
2009-08-13 11:56   ` Jens Axboe
2009-08-13 17:08 ` Heiko Carstens

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.