Use atomics for refcounts.