Author: Roberto Waldteufel
Date: 16:33:58 12/08/98
Go up one level in this thread
On December 08, 1998 at 19:05:52, Marc wrote: >I noticed in the previous thread about bitboard vs. integer array performance >that both approaches were considered equally efficient on non-64 bit-based >processors. > >Even so, I thought bitboards provided a significant speed improvement over int >arrays in both move-generation and position evaluations, i.e. quickly checking >for forks. > >Any thoughts from the bitboard camp? Yes, I agree, although I don't specifically test for forks (but it would be easy to implement with bitboards). It all depends what bitboards you maintain. If you use rotated bitboards, you usually maintain only position of the pieces, not the attack-to and attack-from bitboards. These you calculate on the fly. If you use ordinary bitboards, you can do the same, but the coding is different. Which of these is best depends on your hardware, but on PII I tested this and found the ordinary bitboards faster. However, on older pentiums the bit scan instructions are much slower, so the rotated bitboards would be much better. Alternatively, you can maintain incrementally updated arrays of bitboards for all the attack data. This adds overhead when you make and unmake moves, but you save on move generation and position evaluation. It also makes check detection much faster. If you don't maintain this data, you have less work making moves, but more in generation and evaluation and in check detection. It's hard to say which is best - it depends on how you evaluate positions, how you generate moves etc, and these are fundamental design decisions you have to make before you can really consider the pros and cons. I believe that bitboards are much better than arrays for PII and PPro, mainly because of the fast bit scan instructions. This may not be the case on Pplain, PMMX or 486 machines, which have the bit scan instructions, but execute them terribly slowly (so much so that they are effectively useless). Best wishes, Roberto
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.