[RFC PATCH 00/14] add our own qspinlock implementation
Nicholas Piggin
npiggin at gmail.com
Mon Jul 11 13:04:39 AEST 2022
The qspinlock conversion resulted in some latency regressions
particularly in the paravirt (SPLPAR) case. I haven't been able to
improve them much so for now I rewrite with a different paravirt
algorithm (as s390 does). This isn't the same as s390 but they have
some of the same concerns by the looks, so possibly if we can't
unify with generic code we could unify with them at some point.
Thanks,
Nick
Nicholas Piggin (14):
powerpc/qspinlock: powerpc qspinlock implementation
powerpc/qspinlock: add mcs queueing for contended waiters
powerpc/qspinlock: use a half-word store to unlock to avoid larx/stcx.
powerpc/qspinlock: convert atomic operations to assembly
powerpc/qspinlock: allow new waiters to steal the lock before queueing
powerpc/qspinlock: theft prevention to control latency
powerpc/qspinlock: store owner CPU in lock word
powerpc/qspinlock: paravirt yield to lock owner
powerpc/qspinlock: implement option to yield to previous node
powerpc/qspinlock: allow stealing when head of queue yields
powerpc/qspinlock: allow propagation of yield CPU down the queue
powerpc/qspinlock: add ability to prod new queue head CPU
powerpc/qspinlock: trylock and initial lock attempt may steal
powerpc/qspinlock: use spin_begin/end API
arch/powerpc/Kconfig | 1 -
arch/powerpc/include/asm/qspinlock.h | 130 ++--
arch/powerpc/include/asm/qspinlock_types.h | 65 ++
arch/powerpc/include/asm/spinlock_types.h | 2 +-
arch/powerpc/lib/Makefile | 4 +-
arch/powerpc/lib/qspinlock.c | 671 +++++++++++++++++++++
6 files changed, 829 insertions(+), 44 deletions(-)
create mode 100644 arch/powerpc/include/asm/qspinlock_types.h
create mode 100644 arch/powerpc/lib/qspinlock.c
--
2.35.1
More information about the Linuxppc-dev
mailing list