mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-21 09:37:16 +08:00
Retire history.h
And move the contents to movepick.cpp, where they are mostly used. Idea from DiscoCheck. No functional change (bench 5379503)
This commit is contained in:
@@ -26,7 +26,6 @@
|
||||
|
||||
#include "book.h"
|
||||
#include "evaluate.h"
|
||||
#include "history.h"
|
||||
#include "movegen.h"
|
||||
#include "movepick.h"
|
||||
#include "notation.h"
|
||||
@@ -1071,13 +1070,13 @@ split_point_start: // At split points actual search starts from here
|
||||
|
||||
// Increase history value of the cut-off move
|
||||
Value bonus = Value(int(depth) * int(depth));
|
||||
H.add(pos.piece_moved(bestMove), to_sq(bestMove), bonus);
|
||||
H.update(pos.piece_moved(bestMove), to_sq(bestMove), bonus);
|
||||
|
||||
// Decrease history of all the other played non-capture moves
|
||||
for (int i = 0; i < playedMoveCount - 1; i++)
|
||||
{
|
||||
Move m = movesSearched[i];
|
||||
H.add(pos.piece_moved(m), to_sq(m), -bonus);
|
||||
H.update(pos.piece_moved(m), to_sq(m), -bonus);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user