mirror of
https://github.com/official-stockfish/Stockfish.git
synced 2026-07-22 12:47:08 +00:00
Remove unnecessary deque allocation in perft
closes https://github.com/official-stockfish/Stockfish/pull/6182 No functional change.
This commit is contained in:
+3
-3
@@ -56,9 +56,9 @@ uint64_t perft(Position& pos, Depth depth) {
|
||||
}
|
||||
|
||||
inline uint64_t perft(const std::string& fen, Depth depth, bool isChess960) {
|
||||
StateListPtr states(new std::deque<StateInfo>(1));
|
||||
Position p;
|
||||
p.set(fen, isChess960, &states->back());
|
||||
StateInfo st;
|
||||
Position p;
|
||||
p.set(fen, isChess960, &st);
|
||||
|
||||
return perft<true>(p, depth);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user