Change bool to std::atomic_bool shortening code
It seems to make it more readable whether it is faster or not. An
improvement, still not quite ideal.