add free lock algorithm : loop buffer