<p dir="ltr">On 4 Jul 2015 11:12, "Iain Buclaw" <<a href="mailto:ibuclaw@gdcproject.org">ibuclaw@gdcproject.org</a>> wrote:<br>
><br>
> On 4 July 2015 at 10:39, rsw0x via Digitalmars-d <<a href="mailto:digitalmars-d@puremagic.com">digitalmars-d@puremagic.com</a>> wrote:<br>
>><br>
>> On Saturday, 4 July 2015 at 07:16:09 UTC, Iain Buclaw wrote:<br>
>>><br>
>>> On 4 Jul 2015 00:50, "rsw0x via Digitalmars-d" <<a href="mailto:digitalmars-d@puremagic.com">digitalmars-d@puremagic.com</a>> wrote:<br>
>>>>><br>
>>>>> [...]<br>
>>><br>
>>> __sync_* builtins to the new (more compatible with how core.atomics is supposed to function) __atomic_* builtins.<br>
>>>>><br>
>>>>> [...]<br>
>>><br>
>>> accepted as valid, but makes no sense.<br>
>>>>><br>
>>>>> [...]<br>
>>><br>
>>> both cases to throw a compilation error (using static assert).  However I'd like the core druntime team to be on board with this.<br>
>>>><br>
>>>> [...]<br>
>>><br>
>>> forgot until I read this.<br>
>>><br>
>>> [...]<br>
>><br>
>><br>
>> This is how it's currently implemented in C++ as of C++14, correct?<br>
>> acquire semantics on a write and release semantics on a load make no sense, so this probably should be changed.<br>
><br>
><br>
><br>
> Yes, that is correct.  I think closely matching the behaviour of C++14 is the safe option given that this module shares a lot in common with std::atomic.<br>
><br>
> std::atomic::atomic_compare_exchange_strong -> core.atomic.cas<br>
> std::atomic::memory_order -> core.atomic.MemoryOrder<br>
> std::atomic::atomic_load -> core.atomic.atomicLoad<br>
> std::atomic::atomic_store -> core.atomic.atomicStore<br>
> std::atomic::atomic_thread_fence -> core.atomic.atomicFence<br>
><br>
> Iain.<br>
><br>
></p>
<p dir="ltr">OK, I've added static asserts to my PR.</p>
<p dir="ltr">Iain.</p>