Re: [Qemu-devel] [RFC PATCH 3/3] mttcg: Implement implicit ordering semantics

2017-08-28 Thread Richard Henderson
On 08/28/2017 02:41 PM, Pranith Kumar wrote: > On Mon, Aug 28, 2017 at 1:57 PM, Richard Henderson wrote: >> On 08/27/2017 08:53 PM, Pranith Kumar wrote: >>> diff --git a/tcg/aarch64/tcg-target.h b/tcg/aarch64/tcg-target.h >>> index 55a46ac825..b41a248bee 100644 >>> --- a/tcg/aarch64/tcg-target.h >

Re: [Qemu-devel] [RFC PATCH 3/3] mttcg: Implement implicit ordering semantics

2017-08-28 Thread Pranith Kumar
On Mon, Aug 28, 2017 at 1:57 PM, Richard Henderson wrote: > On 08/27/2017 08:53 PM, Pranith Kumar wrote: >> diff --git a/tcg/aarch64/tcg-target.h b/tcg/aarch64/tcg-target.h >> index 55a46ac825..b41a248bee 100644 >> --- a/tcg/aarch64/tcg-target.h >> +++ b/tcg/aarch64/tcg-target.h >> @@ -117,4 +117,

Re: [Qemu-devel] [RFC PATCH 3/3] mttcg: Implement implicit ordering semantics

2017-08-28 Thread Richard Henderson
On 08/27/2017 08:53 PM, Pranith Kumar wrote: > diff --git a/tcg/aarch64/tcg-target.h b/tcg/aarch64/tcg-target.h > index 55a46ac825..b41a248bee 100644 > --- a/tcg/aarch64/tcg-target.h > +++ b/tcg/aarch64/tcg-target.h > @@ -117,4 +117,6 @@ static inline void flush_icache_range(uintptr_t start, > uin

[Qemu-devel] [RFC PATCH 3/3] mttcg: Implement implicit ordering semantics

2017-08-27 Thread Pranith Kumar
Currently, we cannot use mttcg for running strong memory model guests on weak memory model hosts due to missing ordering semantics. We implicitly generate fence instructions for stronger guests if an ordering mismatch is detected. We generate fences only for the orders for which fence instructions