]> git.sesse.net Git - stockfish/commit
Avoid TT cutoffs at root of null zugzwang verification
authorMarco Costalba <mcostalba@gmail.com>
Sat, 10 Apr 2010 09:32:17 +0000 (10:32 +0100)
committerMarco Costalba <mcostalba@gmail.com>
Sat, 10 Apr 2010 09:35:29 +0000 (10:35 +0100)
commit626b1f8c6adc6c6b1bd7dc30109cd7fa5f3c44d8
treee4ccc3c482ac4a1b270ee2de5dd256dfe5e29580
parent06a350f1aee97f05c3416853fb54385b23030ebc
Avoid TT cutoffs at root of null zugzwang verification

This patch fixes an issue with zugzwang well explained by Tord:

"Assume that a zugzwang position occurs at iteration N,
at a search depth d, with d < 6*OnePly. The null move search
fails high, and no verification search is done, because the
depth is too small. The position gets stored in the transposition
table with a good score and a depth of d.

Now, consider what happens when the same position occurs at iteration
N+1, this time with a depth of d+OnePly (i.e. one ply deeper than at
the previous iteration). Once again, the null move search fails
high. The point is that the verification search will also fail high,
because of an instant transposition table cutoff caused by the value
stored in the TT during the previous iteration."

With this patch we simply do not allow TT cutoffs at the root node
of a null move verification search if the TT value was found by a
null search.

Signed-off-by: Marco Costalba <mcostalba@gmail.com>
src/search.cpp