Ok no zobrist key no pawn table. So that means no pawn table possible for Skipper.
By the way when I did not clean pawn table my engine crashed because there was not memory enough.
Pawn table does not help
Moderators: hgm, Dann Corbit, Harvey Williamson
-
jdart
- Posts: 4361
- Joined: Fri Mar 10, 2006 5:23 am
- Location: http://www.arasanchess.org
Re: Pawn table does not help
You should not be dynamically allocating (via "new" or "malloc") the pawn hash table entries, and probably not the pawn hash table itself. That will be slow. My table is just an array (see https://github.com/jdart1/arasan-chess/ ... /scoring.h around line 90).By the way when I did not clean pawn table my engine crashed because there was not memory enough.
--Jon
-
bob
- Posts: 20943
- Joined: Mon Feb 27, 2006 7:30 pm
- Location: Birmingham, AL
Re: Pawn table does not help
How can you "not evaluate pawns at all" and still play anything even close to reasonable chess?Henk wrote:If you already do expensive pawn evaluations, pawn table may help. But it's much faster to not evaluate pawns at all. If Skipper loses too much speed it will play much worse at blitz games. So it looks like it has to skip pawn evaluations. Counting them is the maximum.
Don't know when I will be stupid enough to implement pawn table for the fifth time. Also clearing pawn table is necessary otherwise it runs out of memory.
-
bob
- Posts: 20943
- Joined: Mon Feb 27, 2006 7:30 pm
- Location: Birmingham, AL
Re: Pawn table does not help
If you do pawn hashing right, even if you get zero hits, the speed impact is minimal. I assume you are using the usual Zobrist hashing? I just keep two hash signatures, one with all pieces and pawns, used in the normal transposition table probes, and one with just pawns, used to probe the pawn hash table. One memory access is not going to be much of a deal here. Not doing a pawn evaluation is going to get you killed in chess games.Henk wrote:If an engine is slow and has a minimal evaluation making it significantly slower with a less minimal evaluation does not help. Maybe making it very slow with a moderate evaluation might help but I doubt that too.cdani wrote:As a global example of speed of evaluation, Andscacs is maybe 3 MN/s with very simple evaluation in my main computer, and 1,2 MN/s with the current evaluation. But the difference of course is the later is maybe 400 elo stronger.
-
Henk
- Posts: 7210
- Joined: Mon May 27, 2013 10:31 am
Re: Pawn table does not help
Skipper does not use Zobrist hashing. So creating and comparing keys is not for free.bob wrote:If you do pawn hashing right, even if you get zero hits, the speed impact is minimal. I assume you are using the usual Zobrist hashing? I just keep two hash signatures, one with all pieces and pawns, used in the normal transposition table probes, and one with just pawns, used to probe the pawn hash table. One memory access is not going to be much of a deal here. Not doing a pawn evaluation is going to get you killed in chess games.Henk wrote:If an engine is slow and has a minimal evaluation making it significantly slower with a less minimal evaluation does not help. Maybe making it very slow with a moderate evaluation might help but I doubt that too.cdani wrote:As a global example of speed of evaluation, Andscacs is maybe 3 MN/s with very simple evaluation in my main computer, and 1,2 MN/s with the current evaluation. But the difference of course is the later is maybe 400 elo stronger.
-
Henk
- Posts: 7210
- Joined: Mon May 27, 2013 10:31 am
Re: Pawn table does not help
With material counting plus random value an engine is strong enough to beat me. Perhaps if evaluation is worthless, evaluating sixteen pawns does not help.bob wrote:How can you "not evaluate pawns at all" and still play anything even close to reasonable chess?Henk wrote:If you already do expensive pawn evaluations, pawn table may help. But it's much faster to not evaluate pawns at all. If Skipper loses too much speed it will play much worse at blitz games. So it looks like it has to skip pawn evaluations. Counting them is the maximum.
Don't know when I will be stupid enough to implement pawn table for the fifth time. Also clearing pawn table is necessary otherwise it runs out of memory.
-
Sven
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: Pawn table does not help
Then how do you maintain a hash key? Incrementally, or always from scratch after making a move?Henk wrote:Skipper does not use Zobrist hashing. So creating and comparing keys is not for free.bob wrote:If you do pawn hashing right, even if you get zero hits, the speed impact is minimal. I assume you are using the usual Zobrist hashing? I just keep two hash signatures, one with all pieces and pawns, used in the normal transposition table probes, and one with just pawns, used to probe the pawn hash table. One memory access is not going to be much of a deal here. Not doing a pawn evaluation is going to get you killed in chess games.Henk wrote:If an engine is slow and has a minimal evaluation making it significantly slower with a less minimal evaluation does not help. Maybe making it very slow with a moderate evaluation might help but I doubt that too.cdani wrote:As a global example of speed of evaluation, Andscacs is maybe 3 MN/s with very simple evaluation in my main computer, and 1,2 MN/s with the current evaluation. But the difference of course is the later is maybe 400 elo stronger.
-
Henk
- Posts: 7210
- Joined: Mon May 27, 2013 10:31 am
Re: Pawn table does not help
Not incrementally. Good idea. Maybe that's the first thing to change. But there are many other pieces of code to improve. In my current implementation I did not do table look-ups near the leaves just to make sure it would not become a performance bottleneck.Sven Schüle wrote:Then how do you maintain a hash key? Incrementally, or always from scratch after making a move?Henk wrote:Skipper does not use Zobrist hashing. So creating and comparing keys is not for free.bob wrote:If you do pawn hashing right, even if you get zero hits, the speed impact is minimal. I assume you are using the usual Zobrist hashing? I just keep two hash signatures, one with all pieces and pawns, used in the normal transposition table probes, and one with just pawns, used to probe the pawn hash table. One memory access is not going to be much of a deal here. Not doing a pawn evaluation is going to get you killed in chess games.Henk wrote:If an engine is slow and has a minimal evaluation making it significantly slower with a less minimal evaluation does not help. Maybe making it very slow with a moderate evaluation might help but I doubt that too.cdani wrote:As a global example of speed of evaluation, Andscacs is maybe 3 MN/s with very simple evaluation in my main computer, and 1,2 MN/s with the current evaluation. But the difference of course is the later is maybe 400 elo stronger.
-
Sven
- Posts: 4052
- Joined: Thu May 15, 2008 9:57 pm
- Location: Berlin, Germany
- Full name: Sven Schüle
Re: Pawn table does not help
Why should a hash table lookup that helps to avoid searching again many subtrees, and/or helps to improve move ordering, become a performance bottleneck?Henk wrote:In my current implementation I did not do table look-ups near the leaves just to make sure it would not become a performance bottleneck.
EDIT: here I assume your remark was about TT lookup, since you previously wrote that your current implementation does not include a pawn hash table.
-
Henk
- Posts: 7210
- Joined: Mon May 27, 2013 10:31 am
Re: Pawn table does not help
Perhaps it doesn't but I wanted to make sure it certainly does not. Also I was focusing on nodes/second because Skipper was five times slower than fairy-max.Sven Schüle wrote:Why should a hash table lookup that helps to avoid searching again many subtrees, and/or helps to improve move ordering, become a performance bottleneck?Henk wrote:In my current implementation I did not do table look-ups near the leaves just to make sure it would not become a performance bottleneck.
EDIT: here I assume your remark was about TT lookup, since you previously wrote that your current implementation does not include a pawn hash table.