Add an atomic increment and decrement implementation, which will be used for