mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 08:43:09 +00:00
Output PV if last iteration does not complete
Instead of outputting "info nodes ... time ..." when the last iteration is interrupted, simply call UCI::pv() to output the PV. I thought about calling UCI:pv() with bounds -VALUE_INFINITE, VALUE_INFINITE to avoid "lowerbound" or "upperbound" appearing in it, but I'm not sure that would be any better. This patch fixes rare inconsistencies between the first move of the last PV output and the bestmove played. It also makes sure that all the latest statistics are sent to the GUI (not only nodes and time but also nps, tbhits, hashfull). No functional change.
This commit is contained in:
parent
818b4a126d
commit
e18e557e77
1 changed files with 1 additions and 5 deletions
|
@ -461,11 +461,7 @@ void Thread::search() {
|
|||
if (!mainThread)
|
||||
continue;
|
||||
|
||||
if (Signals.stop)
|
||||
sync_cout << "info nodes " << Threads.nodes_searched()
|
||||
<< " time " << Time.elapsed() << sync_endl;
|
||||
|
||||
else if (PVIdx + 1 == multiPV || Time.elapsed() > 3000)
|
||||
if (Signals.stop || PVIdx + 1 == multiPV || Time.elapsed() > 3000)
|
||||
sync_cout << UCI::pv(rootPos, rootDepth, alpha, beta) << sync_endl;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue