lock in valgrind instead of try_lock