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]
Date:   Thu, 23 Feb 2017 07:43:37 +0900
From:   Stafford Horne <shorne@...il.com>
To:     Richard Henderson <rth@...ddle.net>
Cc:     Peter Zijlstra <peterz@...radead.org>,
        Jonas Bonn <jonas@...thpole.se>, openrisc@...ts.librecores.org,
        linux-kernel@...r.kernel.org, linux@...ck-us.net
Subject: Re: [OpenRISC] [PATCH v3 08/25] openrisc: add cmpxchg and xchg
 implementations

On Thu, Feb 23, 2017 at 04:30:35AM +1100, Richard Henderson wrote:
> On 02/23/2017 01:20 AM, Stafford Horne wrote:
> > On Wed, Feb 22, 2017 at 12:19:40PM +0100, Peter Zijlstra wrote:
> > > On Wed, Feb 22, 2017 at 04:11:37AM +0900, Stafford Horne wrote:
> > > > +	__asm__ __volatile__(
> > > > +		"1:	l.lwa %0, 0(%1)		\n"
> > > > +		"	l.sfeq %0, %2		\n"
> > > > +		"	l.bnf 1f		\n"
> > > > +		"	 l.nop			\n"
> > > > +		"	l.swa 0(%1), %3		\n"
> > > > +		"	l.bnf 1b		\n"
> > > > +		"1:	 l.nop			\n"
> > > > +		: "=&r"(old)
> > > > +		: "r"(ptr), "r"(old), "r"(new)
> > > > +		: "cc", "memory");
> > > 
> > > I just noticed this, but having both labels have the same name is
> > > somewhat confusing.
> > 
> > Right, better to use '2' for the second one.
> 
> Better still to put the second label after the delay-slot nop.
> You don't need to execute that on the way out.

Right, thats a good point, lots of cases like this.  I will go through
them.

> r~
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ