Author: Russell Reagan
Date: 16:27:57 10/22/04
Go up one level in this thread
On October 22, 2004 at 17:12:07, Stuart Cracraft wrote: >My program spends 40% of its total time in the routines >determining if a given square is attacked. > >Surely there must be a better way. Probably, but we need more details. There are tricks to speed up this kind of thing, but which one you need will depend on the toolset available and the specific question you are trying to answer. In regards to toolset available, do you use bitboards, 0x88, or something else? What information do you have available? Attack tables or not? If so describe them. Piece lists or not? If so describe them. If bitboards, do you have rotated bitboards as well? And so on. In regards to the question being asked, are you wanting to know if a given square is attacked by a piece on another square, or if a given square is attacked by *any* piece of one color, or only if the last pseudo-legal move left the king in check, or something else?
This page took 0.01 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.