bitmap: add atomic test and clear