Hi Dieter,
I am not totally sure, how you define search instability. I am thinking of, search at depth n with a small window, get a fail high, research with a higher upper bound, and get a smaller score back than before. Or even a fail low. Also similar cases when a move at the root fails low. At the moment, I cannot see, how the above 2. can cause this search instability.
Yes, I didn't define search stability at all. I should have.
There is the strict scientific definition which you describe where a fail high is followed by a fail low (or visa versa).
For the purpose of discussion I'm thinking of it in a broader sense, where the search not only returns unreliable/inconsistent scores, but where it gets bogged down, fails to find correct moves, or changes its mind over and over.
Perhaps the topic should be rephrased as 'What causes search 'blues'?
One typical example of window dependent pruning is in qsearch, where many engines will have some code: if ((current material + material gain of this capture move + safety margin) < alpha) /* Futile to try this move */
Now assume you have something like KNNP vs K and you are the lone K, that just captures that pawn. Perhaps your alpha is -10 (you are searching for a draw). current material is -700, K captures P is material gain of +100. So above snippet will prune away K capture P when safety margin is smaller than ~600 (which it will be in any program, I guess). Now you did not find any way to draw. You fail low at the root, and research with an uppen lower bound. You get to that node again. Now alpha is -infinity. You will try the move, and eval in the recursive call of qsearch will return zero. It can give you a fail high followed by a fail low at the same depth.
That's an excellent example!
So, delta pruning can be very dangerous without safeguards.
Its probably the reason why my engine is slow to solve this old Pierre Nolot position even with EGTBs...
FEN: 8/4N3/6p1/4n2p/7P/5kPK/8/8 b - - 0 1
Best Move is ... Ng4
[diag]8/4N3/6p1/4n2p/7P/5kPK/8/8 b - - 0 1 [/diag]
Would you agree that lazy eval can introduce similar effects, if it fails to detect a heavy score swing... like your example above?
Another thing worth to mention - very related to the HT point you had given: path dependent extensions (which for example recapture is). Typically your transition table entry was reached on a different path than the same position you are looking up now. This means, that you will often use a different set of extensions for the moves, even when the stored draft is exactly the same as the current remaining depth. This can yield in a different score from actual search without HT. At a possible later research time, that hash entry might be gone.
This is what I'm finding recently. Extensions/Reductions must be applied consistently throughout the search... if you extend a node differently to when previously visited, you get hash entries overwritten that shouldn't be... which leads to partial blindness in some lines... These kind of things are not search instability as such... but it makes the engine less 'sharp'.
Well Dieter, your delta pruning example was something I was yet to discover. Thanks for sharing that one. Much appreciated!!
Cheers,
Ross