Use acquire() and release() for spinlocks

It is more idiomatick than lock() and unlock()

No functional change.
This commit is contained in:
Marco Costalba
2015-03-15 07:39:10 +01:00
parent bae4679de2
commit 13d4df95cd
4 changed files with 31 additions and 30 deletions

View File

@@ -162,9 +162,9 @@ void MovePicker::score<CAPTURES>() {
template<>
void MovePicker::score<QUIETS>() {
Square prevMoveSq = to_sq((ss-1)->currentMove);
Piece prevMovePiece = pos.piece_on(prevMoveSq);
const HistoryStats &cmh = counterMovesHistory[prevMovePiece][prevMoveSq];
Square prevSq = to_sq((ss-1)->currentMove);
const HistoryStats& cmh = counterMovesHistory[pos.piece_on(prevSq)][prevSq];
for (auto& m : *this)
m.value = history[pos.moved_piece(m)][to_sq(m)]