Skip to content

Commit

Permalink
Don't reset increaseDepth back to true after it has been set to false
Browse files Browse the repository at this point in the history
Resetting increaseDepth back to true each time on the very next iteration was not intended so this is a bug fix and a simplification.
Thanks to xoto10
  • Loading branch information
mstembera authored and PikaCat committed Dec 25, 2022
1 parent 2c53bae commit 97ca8d6
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/search.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -462,12 +462,11 @@ void Thread::search() {
else
Threads.stop = true;
}
else if ( Threads.increaseDepth
&& !mainThread->ponder
else if ( !mainThread->ponder
&& Time.elapsed() > totalTime * 0.43)
Threads.increaseDepth = false;
Threads.increaseDepth = false;
else
Threads.increaseDepth = true;
Threads.increaseDepth = true;
}

mainThread->iterValue[iterIdx] = bestValue;
Expand Down

0 comments on commit 97ca8d6

Please sign in to comment.