mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-21 01:27:16 +08:00
Use a per-thread array for generated moves
This greately reduces stack usage and is a prerequisite for next patch. Verified with 40K games both in single and SMP case that there are no regressions. No functional change.
This commit is contained in:
@@ -87,6 +87,7 @@ public:
|
||||
MovePicker(const Position&, Move, Depth, const HistoryStats&, Square);
|
||||
MovePicker(const Position&, Move, const HistoryStats&, PieceType);
|
||||
MovePicker(const Position&, Move, Depth, const HistoryStats&, Move*, Search::Stack*);
|
||||
~MovePicker();
|
||||
|
||||
template<bool SpNode> Move next_move();
|
||||
|
||||
@@ -103,8 +104,7 @@ private:
|
||||
ExtMove killers[4];
|
||||
Square recaptureSquare;
|
||||
int captureThreshold, stage;
|
||||
ExtMove *cur, *end, *endQuiets, *endBadCaptures;
|
||||
ExtMove moves[MAX_MOVES];
|
||||
ExtMove *moves, *cur, *end, *endQuiets, *endBadCaptures;
|
||||
};
|
||||
|
||||
#endif // #ifndef MOVEPICK_H_INCLUDED
|
||||
|
||||
Reference in New Issue
Block a user