Messages in this thread | | | Date | Thu, 5 Sep 2013 12:50:42 -0700 | Subject | Re: [PATCH] lockref: remove cpu_relax() again | From | Linus Torvalds <> |
| |
On Thu, Sep 5, 2013 at 12:45 PM, Luck, Tony <tony.luck@intel.com> wrote: > > No. I can change the Linux code to say "cmpxchg.rel" here ... but the > h/w will do exactly the same thing it did when I had "cmpxchg.acq".
Oh, so when you said "So we had to back-pedal and keep the "legacy" behavior of a full fence", you meant the hardware design itself, not (as I assumed) the Linux kernel header behavior.
Oh well. Hopefully somebody in hardware learnt how stupid it is to expose weak memory ordering to software. But probably not.
Ugh. Your four-socket machine certainly should have been able to see the performance improvements of not spinning.
That said, another thing that strikes me is that you have 32 CPU threads, and the stupid test-program I sent out had MAX_THREADS set to 16. Did you change that? Becuase if not, then some of the extreme performance profile might be about how the threads get scheduled on your machine (HT threads vs full cores etc).
Linus
| |