Computer Chess Club Archives




Subject: kiwipete perft position

Author: Russell Reagan

Date: 08:04:02 01/04/03

I believe I got rid of all of the bugs in my move generator. I'm not sure
exactly what the problem was, but I made a few changes to the castling rights in
some special cases (capturing a rook on its original square, rook moving from
its original square, and so on) and it seems to work ok now. So I tried the
following position.

[D]r3k2r/p1ppqpb1/bn2pnp1/3PN3/1p2P3/2N2Q1p/PPPBBPPP/R3K2R w KQkq - 0 1

The above position is from "kiwipete" (Peter McKenzie). It has a little bit of
everything so it's a good position to use for perft. Anyway, I let it run last
night, and I thought I had switched my perft function to use 64-bit integer for
the counter, but these are the results I got.

> setboard r3k2r/p1ppqpb1/bn2pnp1/3PN3/1p2P3/2N2Q1p/PPPBBPPP/R3K2R w KQkq - 0 1
> perft 6
48      0
2039    0
97862   0.254
4085603 10.295
193690690       525.25
3736680389      29450.8
total time: 29986.6

Through the first 5 plies it finds the correct values. At ply 6 the value it
gives is off by a few billion, but the exact value of the difference isn't just
any old value. It is 4,294,967,296, which is 2^32, which suggests that my
counter is getting truncated somewhere.

Is it safe to assume my perft function is working correctly (at least in this
position), and that the counter just wrapped around?


This page took 0.04 seconds to execute

Last modified: Thu, 07 Jul 11 08:48:38 -0700

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