Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Bitboards: must I rotate ?

Author: Vincent Diepeveen

Date: 03:48:04 05/12/02

Go up one level in this thread


On May 12, 2002 at 00:26:03, Robert Hyatt wrote:

>On May 11, 2002 at 21:12:35, David Dory wrote:
>
>>
>>Vince wrote:
>>>>Bitboards is a tradeoff. You put less information into
>>>>a single 64 bits word. So you can use instructions like AND and OR
>>>>more easily.
>>
>>>>Gnuchess is putting more information into a single word for each
>>>>square. The advantage is you can faster work with complex knowledge.
>>
>>You wrote:
>>>So in short it means, bitboard helps put more information (==more knowledge)in
>>>single square (64 bits?), if that is what I understand.
>>
>>
>>You have it exactly backward. Bitboards put less info than the design used by
>>Gnuchess 4, but they are faster, and you have the opportunity to be quite
>>creative with their use, without a big penalty in speed.
>
>
>Actually Vincent has it backward.  Bitmaps are "dense" in terms of information.
>For example, in the opening position, 1/2 the bits are 1's and 1/2 are 0's.
>That seems to suggest 50% density but that is _wrong_.  The zero bits also
>have significant meaning (squares that are empty).  Bitmaps are by far the
>best way to represent a chess board when you have a 64 bit machine.  Just
>compare a 32 bit program to a bitmapper on a 64 bit machine to see why.  Every
>internal instruction moves 64 bits around, and 1/2 of the bits are totally
>useless on a 32 bit program.  On a bitmapper, _every_ bit counts...

They ask about attack information Bob, as already 2 years ago proven,
also at a 64 bits machine bitboards are not the way to use for attack
information gnuchess 4.0 style, because you use 1 bit of information
a square, so in 1 integer for a square it takes a while to collect
information, whereas i have incremental attacktables which keep track
of a lot of things for each square.

So to get number of attackers at a square X in for example gnuchess 4.0
all you do is: attackers = attack[0]&31;

That's pretty unbeatable if you have 1 bit of information a bitmap!

This gets used in evaluation. Crafty doesn't use it in evaluation, so
i do not see why it needs it. It's a trade-off decision IMHO.

>
>
>>
>>Dave



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.