Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Reversed vs. Rotated Bitboards (correction)

Author: Ralf Elvsén

Date: 14:24:16 01/29/02

Go up one level in this thread


On January 29, 2002 at 07:03:24, Sune Fischer wrote:

>On January 29, 2002 at 06:10:53, Ralf Elvsén wrote:
>

>>
>>Yes, that was what I was trying to do. If (in this case) h1 is set you
>>don't have to mask after the occ^(occ-2) -thing. I think the easiest way
>>maybe is.
>>
>>x = (occ | 0x8080808080808080) >> square
>>a = (x^(x-2)) >> square
>
I. My endless stream of errors continue: the last line should read
a = (x^(x-2)) << square

>Could be, hopefully there were a few redundant operations;)
>
>but 0x8080808080808080 is FILE8:
>-------x
>-------x
>-------x
>-------x
>-------x
>-------x
>-------x
>-------x
>
>how do you know what to mask with, a small table would be needed right?

II. I have a suspicion there is something I am missing. Work it out
and report back here please :)

Ralf


>
>>>Anyway, it is easier to test and debug than rotated and it may even be faster >on some machines where memory bandwith is a huge bottleneck.
>>
>>Yes, I think it can be just fine for move generation. But I'm not so
>>sure how it fits in regarding the other things now handled by e.g.
>>rotated bitboards.
>
>We end up with two attack boards instead of one, so to check if a square is
>attacked we need to check both boards, in principle.
>If the attack boards are used frequently for other things than move generation,
>then at some point it will be worth reversing the reversed board to get only one
>attack board.
>
>
>>Ralf
>>
>>>
>>>>>Ralf



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.