Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: bitboard eval question

Author: Tony Werten

Date: 06:21:56 11/20/02

Go up one level in this thread


On November 20, 2002 at 08:58:13, Kim Roper Jensen wrote:

>Hi
>
>I just wondered, if we take an bitboard program and its evaluation function, and
>then looked at all the bitmaps used/generated in it how many would be the same
>??
>
>What i wanted to know was, if there is any redundancy in the evaluation
>bitboards, for example the same bitboard gets generated multiple times but in
>different areas of evaluation.
>
>My idea was something like this:
>
>I assume that every evaluation rule is dependant on 1 or more bitboards, so we
>can say that a eval rule is dependant on 1 or more bitboards.
>
>Every evaluation rule that is used only 1 time gets scored first.
>Every evaluation rule that uses 2 or more bitboards that the first rule has
>generated
>and so on.
>
>The trick should be that we only generate each bitboard once and then never
>again and arrange code so we're using this fact.
>
>simple example with pawn eval:
>
>pawnBitBoard >> 8; all pawn moves 1 forward(or backward dependant on
>orientation), but this can also be used to se if a pawn can interpose between an
>attacker and defender.

Find the interposing squares, do a >>8 and and it with all pawns would be
faster, but the work done could probably only be used once.

This is the whole point, wether doing fast specific stuff multiple times is
faster than doing slow general stuff once. Sometimes it is, sometimes it isn't.
It depends on your design, not on wether or not you use bitboards.

Tony

>
>So instead of making clean easy readable code, we evaluate at once when we have
>the bitboards that the rule is dependant of.
>
>With regards
>Kim
>
>PS If this sounds like rubbish, theres a big chance it is, im not using
>bitboards myself but like fiddling with stuff :)
>
>PPS If the start of the first PS is correct please dont flame me, im on work,
>tired and almost drugged dead by coffe :)



This page took 0.03 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.