mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-19 16:46:30 +08:00
Do not modify alpha in split()
When calling split or we immediately return because unable to find available slaves, or we start searching on _all_ the moves of the node or until a cut-off occurs, so that when returning from split we immediately leave the moves loop. Because of this we don't need to change alpha inside split() and we can use a signature similar to search() so to better clarify that split() is actually a search on the remaining node's moves. No functional change with faked split. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
@@ -1228,8 +1228,8 @@ split_point_start: // At split points actual search starts from here
|
||||
&& Threads.available_slave_exists(pos.thread())
|
||||
&& !StopRequest
|
||||
&& !thread.cutoff_occurred())
|
||||
Threads.split<FakeSplit>(pos, ss, &alpha, beta, &bestValue, depth,
|
||||
threatMove, moveCount, &mp, NT);
|
||||
bestValue = Threads.split<FakeSplit>(pos, ss, alpha, beta, bestValue, depth,
|
||||
threatMove, moveCount, &mp, NT);
|
||||
}
|
||||
|
||||
// Step 20. Check for mate and stalemate
|
||||
|
||||
Reference in New Issue
Block a user