Use atomicModifyIORef' rather than atomicModifyIORef

I don't know of any particular problems that this fixes, but as far as I
know it's not wrong, and it should be safer.
expose new Word operation to swap endianness for Word{16,32,64}

Patch from Vincent Hanquez.