Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: How do you insure that Hash Table entries are correct?

Author: Larry Griffiths

Date: 09:34:55 09/17/00

Go up one level in this thread


On September 17, 2000 at 03:54:23, Johan Melin wrote:

>On September 17, 2000 at 02:46:34, Larry Griffiths wrote:
>
>>I tried using my compilers rand() function but it was only generating
>>random numbers from 0 to 0x7fff.
>>
>>I ran 78 positions from the BWTC suite
>>and got over 10,000 mis-matches using my 64-bit hash keys.
>>I looked at my smallboards and they usually differ by a piece missing or in a
>>different position.  My Piece table does not have zero or duplicate entries
>>and the random numbers in the piece table look good.
>>I built hashkeys using the two different smallboards and they do indeed
>>generate the same hashkeys.
>>
>>Maybe my hashkeys should be prime numbers?
>>
>>I will play around with random some more and see if it changes my mismatch
>>rate.
>>
>>Thanks Bob.
>>
>>Larry.
>
>With 10,000 mismatches something must be broken. How good are your random
>numbers? Try counting the bit-difference between all pairs of 64-bit keys.
>The average should be around 32 and the minimum above 12.
>
>/Johan Melin

Hi Johan,

I built 64-bit keys with prime-numbers in each 4 bits (4 x 16=64 bits) and also
with each nibble (4-bits) containing 2 bits on (using 3,5,6,9,10,12) and this
seemed to cut the mismatches between my small boards in half.
I also tried a 128-bit hash key but it did not reduce the mismatches by much.

I think BWTC position 256 is one of the suite tests that really eats my lunch.
This position causes 5961 mismatches in rapid fashion in my hashing.
It looks like this...

[D]r3kb2/ppp5/7r/3p4/4p2q/5n1P/PPPP1PP1/RNBQ1R1K b q - bm Qg4 Qxh3+; id
"BWTC.0256";




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.