Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Pawn Hashkey Size

Author: Miguel A. Ballicora

Date: 11:50:57 12/03/01

Go up one level in this thread


On December 03, 2001 at 14:33:33, Dan Andersson wrote:

>>and while collisions might not themselves be evil, the increase in complexity of
>>debugging etc. sure is. A very important invariant, that a position's
>
>An interesting artifact of shortening the hash is that due to the increased
>chance of collisions you will have a better chance of catching the collisions in
>action, and make the program deal with them gracefully. i.e. A more debugged
>program rather than the opposite ... Counterintuitive but true! By using a
>larger hash key you actually move the problem forward intead of cathing it.
>
>MvH Dan Andersson

Nice observation, but the best thing to do IMHO is to use the more bits you can
in the "release" version and the least you can tolerate in the "debug" version.
At least, in a way you can switch it with a compiler directive. That is what
I did with the "transposition - refutation" table and I caught some bugs
that would happen rarely, but they will happen. They were in the legality
checking function. Even though those bugs would have been rare, they cause
crashes since accepting ilegal moves messes up everything. Avoiding
a crash every ~50 games (or whatever) it is worth it.
Debug versions should not use "Defensive programming!", they should increase
the chances of the unexpected so bugs will not be hidden and caught.

Regards,
Miguel





This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.