Author: Robert Hyatt
Date: 09:35:33 01/04/03
Go up one level in this thread
On January 04, 2003 at 11:04:02, Russell Reagan wrote: >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? > >Russell How are you printing the thing? %d will _not_ work with a 64 bit integer. Microsoft does it one way. If you are using gcc, use %llu to print a 64 bit counter (assuming it is unsigned which makes sense).
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.