Add atomic_wrapper
Replace std::atomics with AtomicWrapper