lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFyevZQG5pEz-iJF6MFEMpwJD=biB-x852ki0spOM293Sg@mail.gmail.com>
Date:	Thu, 5 Sep 2013 10:53:07 -0700
From:	Linus Torvalds <torvalds@...ux-foundation.org>
To:	"Luck, Tony" <tony.luck@...el.com>
Cc:	Heiko Carstens <heiko.carstens@...ibm.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] lockref: remove cpu_relax() again

On Thu, Sep 5, 2013 at 10:35 AM, Luck, Tony <tony.luck@...el.com> wrote:
>
> So Linus is right that the cpu_relax() makes things less fair ... but without it performance sucks so
> much that I don't want to use the clever cmpxchg at all - I'm much better off without it!

Hmm. Is this single-socket? The thing really only is supposed to help
if there's tons of contention.

Also, it strikes me that ia64 has tons of different versions of
cmpxchg, and the one you use by default is the one with "acquire"
semantics. That may well be the right thing to do, but I have this
possibly unfounded gut feeling that you might want to try using a
relaxed cmpxchg and then perhaps have a memory barrier *after* it has
successfully executed.

I'll have to think a bit more about what the exact memory ordering
requirements for lockref's are, but my gut feel is that just for
incrementing the reference count you don't actually have any real
memory ordering requirements.

                 Linus
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ