Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-10-20 Thread Richard Henderson
On 10/20/2016 12:07 PM, Pranith Kumar wrote: On Thu, Oct 20, 2016 at 3:02 PM, Richard Henderson wrote: On 10/20/2016 11:58 AM, Pranith Kumar wrote: Indeed, I was looking at atomic-6 on github. atomic-7 is not there yet :) I've rebased atomic-6 (no -7). It should be there. Am I looking

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-10-20 Thread Pranith Kumar
On Thu, Oct 20, 2016 at 3:02 PM, Richard Henderson wrote: > On 10/20/2016 11:58 AM, Pranith Kumar wrote: >> >> Indeed, I was looking at atomic-6 on github. atomic-7 is not there yet :) > > > I've rebased atomic-6 (no -7). It should be there. > Am I looking at the right file? https://github.com/

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-10-20 Thread Richard Henderson
On 10/20/2016 11:58 AM, Pranith Kumar wrote: Indeed, I was looking at atomic-6 on github. atomic-7 is not there yet :) I've rebased atomic-6 (no -7). It should be there. r~

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-10-20 Thread Pranith Kumar
On Thu, Oct 20, 2016 at 2:00 PM, Richard Henderson wrote: > On 10/20/2016 10:51 AM, Pranith Kumar wrote: >>> >>> Added back >>> >>> /* Load/Store exclusive instructions are implemented by remembering >>>the value/address loaded, and seeing if these are the same >>>when the store is perform

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-10-20 Thread Richard Henderson
On 10/20/2016 10:51 AM, Pranith Kumar wrote: Added back /* Load/Store exclusive instructions are implemented by remembering the value/address loaded, and seeing if these are the same when the store is performed. This should be sufficient to implement the architecturally mandated semant

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-10-20 Thread Pranith Kumar
On Wed, Sep 14, 2016 at 12:38 PM, Richard Henderson wrote: > On 09/14/2016 09:03 AM, Alex Bennée wrote: >>> > -/* Load/Store exclusive instructions are implemented by remembering >>> > - the value/address loaded, and seeing if these are the same >>> > - when the store is performed. This should

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-09-14 Thread Richard Henderson
On 09/14/2016 09:03 AM, Alex Bennée wrote: >> > -/* Load/Store exclusive instructions are implemented by remembering >> > - the value/address loaded, and seeing if these are the same >> > - when the store is performed. This should be sufficient to implement >> > - the architecturally mandated

Re: [Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-09-14 Thread Alex Bennée
Richard Henderson writes: > From: "Emilio G. Cota" > > Emulating LL/SC with cmpxchg is not correct, since it can > suffer from the ABA problem. Portable parallel code, however, > is written assuming only cmpxchg--and not LL/SC--is available. > This means that in practice emulating LL/SC with cm

[Qemu-devel] [PATCH v3 27/34] target-arm: emulate LL/SC using cmpxchg helpers

2016-09-03 Thread Richard Henderson
From: "Emilio G. Cota" Emulating LL/SC with cmpxchg is not correct, since it can suffer from the ABA problem. Portable parallel code, however, is written assuming only cmpxchg--and not LL/SC--is available. This means that in practice emulating LL/SC with cmpxchg is a viable alternative. The appe