cleanup and add support for atomic operations on windows