Author: Bas Hamstra
Date: 21:20:39 04/28/01
Go up one level in this thread
On April 27, 2001 at 21:28:14, Dann Corbit wrote: >Precomputing attack tables is a snap, of course. The burning question is, how >are they best utilized? Depends on the type of attacktables and the datastructure if this is a snap, IMO. For instance Attack-To tables with bitboards are not a snap at all (will slow you down considerably), but Attack-From tables is doable. >I notice that nobody makes pawn attack tables. Is that because pawn attacks >too trivial to compute on the fly? Well with BB it is easy to at least compute all squares that are pawn attacked, and that will do most of the time. >What is the typical savings of attack tables compared to performing the >computations on the fly? Some tactical engines like TheKing, Diep and probably Hiarcs use attack-to info heavily. That is: they want to be able to read from a table for each square by which pieces of both sides it is attacked. Doing this on-the-fly would slow you down too much, in this case. For bitboards as well as other datastructures. >Is there any advantage to trying to compress the attack tables? >Do you use attack tables against an entire side at once, or only against pieces >by set or even individual chess men? > >Are they used in MVV/LVA primarily, or during all phases of evaluation? They are kept primarily for evaluation. >Obviously, knight attack tables can be performed with a single & operation, but >what do you do with bishops, queens, etc, where your own man or an intervening >piece can get in the way? Are they used only as a pre-test to see if the rest >is worth calculating? I am not sure you use the same definition as I do. In my opinion attack-to tables give for each square by which pieces (or squares, or directions) it is attacked. Truly attacked. Attack-From tables give for each piece (or square) which squares it attacks. What you seem to be referring to is some kind of pseudo-attacks, not taking into acccount blockers for sliders. Those tables are used also, of course, but these are not what most mean byt attack tables. >I thought of using all your own men, &'ed together as a mask, and then clearing >everything past a "pierce" mark, but that would probably be as expensive as >computation of the attack. By the way, I tried your version of PopCnt, and for 64 bits it was slightly slower, because 64 bits shifts cause overhead. Best regards! Bas.
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.