lock now works; had to switch compare_and_swap in acquire(...) with test(fetch)_and_set