Author: Peter Fendrich
Date: 15:03:25 10/18/04
Go up one level in this thread
On October 17, 2004 at 22:58:35, William Bryant wrote: >I am reaching for straws here, but, knowing the experience on this board, >someone might have had this problem too. > >My move generator comes up short of perft. >Specifically, from the starting position it is 20 move short on perft 3. > >I get 20 at ply 1 >I get 400 at ply 2 (20 responses) >But I only get 8882 at ply 3 (reguardless of wether black starts first or white) > >I have checked all the special move, double pawn moves, ep moves, castling and >can't seem to find >the error. > >Any suggestions. > >William >(BTW, this is a new engine for me, 64 bits wide for my new (hopefully) G5)) The absolutely best way to debug the movegen is to extend your perft just a little bit. (I call the function perftm). When I run it in my new engine I get: perftm 3 (20 moves) 0 a2a3 : 380 1 b2b3 : 420 2 c2c3 : 420 3 d2d3 : 539 4 e2e3 : 599 5 f2f3 : 380 6 g2g3 : 420 7 h2h3 : 380 8 a2a4 : 420 9 b2b4 : 421 10 c2c4 : 441 11 d2d4 : 560 12 e2e4 : 600 13 f2f4 : 401 14 g2g4 : 421 15 h2h4 : 420 16 Nb1a3 : 400 17 Nb1c3 : 440 18 Ng1f3 : 440 19 Ng1h3 : 400 Total: 8902 The trick is to compare your perftm with some other that is correct. Mine is under development but you can download for instance Sharper http://www.albert.nu/programs/sharper/ His command "divide 3" is the same as mine "perftm 2" Lets say that your a2a3 is only 360. Make the move in both Sharper and your own program and continue with "divide 2". When you finally reach divide 1, you will see the missing move(s). /Peter
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.