Stockfish null move pre-condition

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Stockfish null move pre-condition

Post by bob »

Ralph Stoesser wrote:
bob wrote: It will make measurably smaller trees at no cost. How much smaller depends on lots of things, but avoiding a wasted null-move search can't possibly be bad, and it doesn't add more than a line of code, which is hardly a huge increase in complexity.
Not so clear for SF 1.8. At some depths it makes the trees smaller, at other depths it makes the trees bigger. Measured with SF bench for depths 12, 14, 16, 18 and 20.
You can't compare individual positions. There are some that null-move makes larger. It is the overall effect that is important... And I don't see how avoiding a null-move search that you know will not fail high can be bad, overall... even though thanks to the hash table it might be worse in a position here or there.
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Stockfish null move pre-condition

Post by bob »

Tord Romstad wrote:
bob wrote:It will make measurably smaller trees at no cost.
We've had exactly this discussion several times before.

What you're missing is that we don't use just the score returned by the null move search, but also the move that refutes the null move. We use this move for pruning decisions. Without it, our forward pruning is less accurate.
Of course that changes things, since the search is used to determine more than just the "null-move observation".
Ralph Stoesser
Posts: 408
Joined: Sat Mar 06, 2010 9:28 am

Re: Stockfish null move pre-condition

Post by Ralph Stoesser »

bob wrote:
Ralph Stoesser wrote:
bob wrote: It will make measurably smaller trees at no cost. How much smaller depends on lots of things, but avoiding a wasted null-move search can't possibly be bad, and it doesn't add more than a line of code, which is hardly a huge increase in complexity.
Not so clear for SF 1.8. At some depths it makes the trees smaller, at other depths it makes the trees bigger. Measured with SF bench for depths 12, 14, 16, 18 and 20.
You can't compare individual positions. There are some that null-move makes larger. It is the overall effect that is important... And I don't see how avoiding a null-move search that you know will not fail high can be bad, overall... even though thanks to the hash table it might be worse in a position here or there.


Because you do some usefull things with the threat move from null move search fail low. Without the null move search you don't have that move. It's not unconditionally bad to skip that part, but it's also not clear to me whether it's good. How about some cluster testing to decide it root and branch?