[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87r1zfxtne.fsf@nanos.tec.linutronix.de>
Date: Fri, 31 Jan 2020 21:23:01 +0100
From: Thomas Gleixner <tglx@...utronix.de>
To: Davidlohr Bueso <dave@...olabs.net>,
Alex Shi <alex.shi@...ux.alibaba.com>
Cc: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>, Will Deacon <will@...nel.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] locking/rtmutex: remove unused cmpxchg_relaxed
Davidlohr Bueso <dave@...olabs.net> writes:
> On Tue, 21 Jan 2020, Alex Shi wrote:
Subject: locking/rtmutex: remove unused cmpxchg_relaxed
should be
Subject: locking/rtmutex: Remove unused rt_mutex_cmpxchg_relaxed()
You're not removing cmpxchg_relaxed, right?
>> No one use this macro after it was introduced. Better to remove it?
Please make that factual.
The macro was never used at all. Remove it.
> You also need to remove it for the CONFIG_DEBUG_RT_MUTEXES=y case.
Yes.
> Hmm unrelated, but do we want CCAS for rtmutex fastpath? Ie:
>
> (l->owner == c && cmpxchg_acquire(&l->owner, c, n) == c)
>
> That would optimize for the contended case and avoid the cmpxchg - it would
> also help if we ever do the top-waiter spin thing.
Not sure if it buys much, but it kinda makes sense.
Thanks,
tglx
Powered by blists - more mailing lists