From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: [PATCH 3/4] x86,asm: Re-work smp_store_mb() Date: Tue, 12 Jan 2016 14:55:35 -0800 Message-ID: <56958467.6010808@zytor.com> References: <1445975631-17047-4-git-send-email-dave@stgolabs.net> <20151027223744.GB11242@worktop.amr.corp.intel.com> <20151102201535.GB1707@linux-uzut.site> <20160112150032-mutt-send-email-mst@redhat.com> <56956276.1090705@kernel.org> <20160113001824-mutt-send-email-mst@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20160113001824-mutt-send-email-mst@redhat.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: virtualization-bounces@lists.linux-foundation.org Errors-To: virtualization-bounces@lists.linux-foundation.org To: "Michael S. Tsirkin" , Andy Lutomirski Cc: Davidlohr Bueso , Davidlohr Bueso , Peter Zijlstra , the arch/x86 maintainers , Linux Kernel Mailing List , virtualization , Andy Lutomirski , Thomas Gleixner , "Paul E. McKenney" , Linus Torvalds , Ingo Molnar List-Id: virtualization@lists.linuxfoundation.org On 01/12/16 14:21, Michael S. Tsirkin wrote: > > OK so I'll have to tweak the test to put something > on stack to measure the difference: my test tweaks a > global variable instead. > I'll try that by tomorrow. > > I couldn't measure any difference between mfence and lock+addl > except in a micro-benchmark, but hey since we are tweaking this, > let's do the optimal thing. > Be careful with this: if it only shows up in a microbenchmark, we may introduce a hard-to-debug regression for no real benefit. -hpa