Re: [swift-evolution] [pitch] Atomics

2017-02-24 Thread Joe Groff via swift-evolution
> On Feb 23, 2017, at 1:44 PM, Guillaume Lessard via swift-evolution > wrote: > > There is no clean way to use atomic operations in Swift at the moment, even > less so after most of OSAtomic.h was deprecated in Sierra. Of course, the > OSAtomic calls were never

Re: [swift-evolution] [pitch] Atomics

2017-02-24 Thread Zach Waldowski via swift-evolution
Huge +1, and for the prototype as well. Atomic.Bool and Atomic.RawPointer would also be truly appreciated. An Atomic a la C++ would be even better but I don't know if we'd want to tie ourselves to that. I like the LLVM names for MemoryOrder et. al. better than the C std. ones, in general, and

Re: [swift-evolution] [pitch] Atomics

2017-02-24 Thread Anton Mironov via swift-evolution
+1 But I would also suggest using Int instead of Int64 in public interface. > On Feb 23, 2017, at 23:44, Guillaume Lessard via swift-evolution > wrote: > > There is no clean way to use atomic operations in Swift at the moment, even > less so after most of

[swift-evolution] [pitch] Atomics

2017-02-24 Thread Guillaume Lessard via swift-evolution
There is no clean way to use atomic operations in Swift at the moment, even less so after most of OSAtomic.h was deprecated in Sierra. Of course, the OSAtomic calls were never available in Linux, so there are no atomics at all on that side. It's technically possible to wrap clang’s C11 atomics