1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-04-29 16:23:09 +00:00

Fix TB PV extension and MultiPV

in the case of MultiPV, the first move of the Nth multiPV could actually turn a
winning position in a losing one, so don't attempt to correct it. Instead,
always perform the first move without correction.

Fixes #5505

Closes https://github.com/official-stockfish/Stockfish/pull/5506

No functional change
This commit is contained in:
Joost VandeVondele 2024-07-21 13:15:12 +02:00
parent 1fb4dc2e0f
commit e57fba7fc9

View file

@ -1948,8 +1948,12 @@ void syzygy_extend_pv(const OptionsMap& options,
std::list<StateInfo> sts;
// Step 0, do the rootMove, no correction allowed, as needed for MultiPV in TB.
auto& stRoot = sts.emplace_back();
pos.do_move(rootMove.pv[0], stRoot);
int ply = 1;
// Step 1, walk the PV to the last position in TB with correct decisive score
int ply = 0;
while (size_t(ply) < rootMove.pv.size())
{
Move& pvMove = rootMove.pv[ply];