Quad-bard vs bitboard : is it faster ?
Moderators: hgm, Rebel, chrisw
-
- Posts: 79
- Joined: Mon May 16, 2011 2:52 am
Quad-bard vs bitboard : is it faster ?
I'm discovering to quad-board structure on chessprogrammingwiki : is it faster than regular bitboards ? Is there any perft benchmark somewhere to compare engines using different structures ?
-
- Posts: 266
- Joined: Fri Jul 10, 2015 9:23 pm
- Location: Russia
Re: Quad-bard vs bitboard : is it faster ?
I use Quad-board, is very fast.
(in fact, I use Penta-board)
(in fact, I use Penta-board)
Eugene Kotlov
Hedgehog 2.1 64-bit coming soon...
Hedgehog 2.1 64-bit coming soon...
-
- Posts: 1334
- Joined: Sun Jul 17, 2011 11:14 am
Re: Quad-bard vs bitboard : is it faster ?
I don't have data on quad-bitboard versus octa-bitboard, but quad-bitboard engines require a monochrome board representation, and my own testing does show that those are slightly slower than double colour board representations.
I can provide more accurate data in a few hours.
I can provide more accurate data in a few hours.
Some believe in the almighty dollar.
I believe in the almighty printf statement.
I believe in the almighty printf statement.
-
- Posts: 79
- Joined: Mon May 16, 2011 2:52 am
Re: Quad-bard vs bitboard : is it faster ?
What is your penta-board representation ? What is the 5th board used for ?
-
- Posts: 79
- Joined: Mon May 16, 2011 2:52 am
Re: Quad-bard vs bitboard : is it faster ?
Thanks Matthew, waiting for your data
-
- Posts: 266
- Joined: Fri Jul 10, 2015 9:23 pm
- Location: Russia
Re: Quad-bard vs bitboard : is it faster ?
j_romang wrote:What is your penta-board representation ? What is the 5th board used for ?
Code: Select all
typedef struct
{
U64 a; // маска альфа-фигур
U64 b; // маска b
U64 c; // маска c
U64 d; // маска d
U16 k; // 0х10110000 00110000 (цвет, рокировки, кол-во фигур)
U8 e; // ep 0..7 если есть, 8 если нет
U8 t; // счетчик 50-и ходов
U8 r; // повтор позиции
U8 s; // специфика предыдущего хода
S16 m; // материал
} tpos;
Eugene Kotlov
Hedgehog 2.1 64-bit coming soon...
Hedgehog 2.1 64-bit coming soon...
-
- Posts: 79
- Joined: Mon May 16, 2011 2:52 am
Re: Quad-bard vs bitboard : is it faster ?
Thanks eugene ! Could you explain what you store in 'e', 's', and 'm' ? 'r' is a repetition counter, right ?
-
- Posts: 266
- Joined: Fri Jul 10, 2015 9:23 pm
- Location: Russia
Re: Quad-bard vs bitboard : is it faster ?
k - color, castling, number of piecesj_romang wrote:Thanks eugene ! Could you explain what you store in 'e', 's', and 'm' ? 'r' is a repetition counter, right ?
e - EP
t - the counter of 50 move rule
r - repeat position
s - specifics of the previous move
m - material
Eugene Kotlov
Hedgehog 2.1 64-bit coming soon...
Hedgehog 2.1 64-bit coming soon...
-
- Posts: 1334
- Joined: Sun Jul 17, 2011 11:14 am
Re: Quad-bard vs bitboard : is it faster ?
This got sidetracked by the forum migration and me getting ill over the weekend.
So, I ran a Perft benchmark (which admittedly isn't the whole story of a search, but it magnifies the important part).
It turns out that a monochrome move generator is slightly faster:
However, as a counterpoint:
So it's rather hardware dependent.
So, I ran a Perft benchmark (which admittedly isn't the whole story of a search, but it magnifies the important part).
It turns out that a monochrome move generator is slightly faster:
Code: Select all
AMD FX-6300 @ 3.5GHz:
Double-colour:
CPW [637,032,715 nodes]:
real 1m16.190s
user 1m15.781s
sys 0m0.063s
Hartmann [4,782,906,132 nodes]:
real 10m9.788s
user 10m6.125s
sys 0m0.141s
Single-colour:
CPW:
real 1m15.089s
user 1m14.719s
sys 0m0.016s
Hartmann:
real 9m44.185s
user 9m40.984s
sys 0m0.188s
Code: Select all
RPi 3B+ @ 1.4GHz:
Double-colour CPW:
real 6m14.229s
user 6m13.821s
sys 0m0.026s
Single-colour CPW:
real 8m24.195s
user 8m23.984s
sys 0m0.055s
Some believe in the almighty dollar.
I believe in the almighty printf statement.
I believe in the almighty printf statement.
-
- Posts: 79
- Joined: Mon May 16, 2011 2:52 am
Re: Quad-bard vs bitboard : is it faster ?
Thanks ! Is your raspberry Pi B+ running in 32 or 64 bit mode ?