Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Fine #70 and hash bug(s) (warning: long post)

Author: Tom Likens

Date: 19:09:54 04/18/04

Go up one level in this thread


On April 18, 2004 at 19:56:25, Andrew Wagner wrote:

>     Ok, I've been banging my head against this one all day. This is Fine #70:
>[d]8/k7/3p4/p2P1p2/P2P1P2/8/8/K7 w - -
>
>     Below is Trueno's output for the position. Of course, the correct result is
>+1.8 (Trueno counts pawns as .9) with the best move of Kb1. It finds that but
>then changes its mind. I've been told that this position is generally infamous
>for catching hash bugs. Anyone have any suggestions how to attack this one? Null
>move is off, and I'm evaluating material only, using a single replace-always
>hash table. Any suggestions would be VERY much appreciated). Andrew
>
>           -------------------------------
>        8 | . | . | . | . | . | . | . | . |
>          |-------------------------------|
>        7 | k | . | . | . | . | . | . | . |
>          |-------------------------------|
>        6 | . | . | . | p | . | . | . | . |
>          |-------------------------------|
>        5 | p | . | . | P | . | p | . | . |
>          |-------------------------------|
>        4 | P | . | . | P | . | P | . | . |
>          |-------------------------------|
>        3 | . | . | . | . | . | . | . | . |
>          |-------------------------------|
>        2 | . | . | . | . | . | . | . | . |
>          |-------------------------------|
>        1 | K | . | . | . | . | . | . | . |
>           -------------------------------
>            A   B   C   D   E   F   G   H
>
>Fifty: 0  En Passant: 0
>Castle: 0000
>Ply: 0  To move: True

[--snip--]

Andrew,

One of the best ways I've found to debug hash table problems is to have a
routine that generates the hash key from scratch and then compares it to
the incremental key on the fly.  If you run this routine every time you
touch the hash key (usually after making or unmaking a move) you will more
than likely see the bug.  I set this up as a compile time option (it gets
enabled in my debug build).  I also set it up so that it drops directly
into the debugger if it encounters an error using an inline assembly
call to interrupt 3.

good luck,
--tom



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.