mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-19 16:46:30 +08:00
Try to prefetch as soon as position key is ready
Move prefetching code inside do_move() so to allow a very early prefetching and to put as many instructions as possible between prefetching and following retrieve(). With this patch retrieve() times are cutted of another 25% No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
@@ -98,6 +98,7 @@ struct StateInfo {
|
||||
StateInfo* previous;
|
||||
};
|
||||
|
||||
class TranspositionTable;
|
||||
|
||||
/// The position data structure. A position consists of the following data:
|
||||
///
|
||||
@@ -258,6 +259,7 @@ public:
|
||||
void undo_move(Move m);
|
||||
void do_null_move(StateInfo& st);
|
||||
void undo_null_move();
|
||||
void setTranspositionTable(TranspositionTable* tt);
|
||||
|
||||
// Static exchange evaluation
|
||||
int see(Square from, Square to) const;
|
||||
@@ -356,6 +358,7 @@ private:
|
||||
File initialKFile, initialKRFile, initialQRFile;
|
||||
StateInfo startState;
|
||||
StateInfo* st;
|
||||
TranspositionTable* TT;
|
||||
|
||||
// Static variables
|
||||
static int castleRightsMask[64];
|
||||
|
||||
Reference in New Issue
Block a user