Skip to content

Commit

Permalink
'Age' capture history dividing it by two after every search instead o…
Browse files Browse the repository at this point in the history
…f letting it be
  • Loading branch information
eduherminio committed Jan 31, 2024
1 parent eae7283 commit 2680be9
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/Lynx/Search/IDDFS.cs
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,16 @@ private int CheckPonderHit(ref SearchResult? lastSearchResult, int depth)
Array.Clear(_quietHistory[i]);
}

// Not clearing _captureHistory on purpose
for (int i = 0; i < _captureHistory.Length; i++)
{
for (int j = 0; j < _captureHistory[i].Length; j++)
{
for (int k = 0; k < _captureHistory[i][j].Length; ++k)
{
_captureHistory[i][j][k] /= 2;
}
}
}
}

return depth;
Expand Down

0 comments on commit 2680be9

Please sign in to comment.