Author: Steffan Westcott

Date: 04:13:51 11/20/02

Go up one level in this thread

On November 20, 2002 at 05:44:10, Sune Fischer wrote: >On November 20, 2002 at 05:37:43, Steffan Westcott wrote: > >>On November 20, 2002 at 05:05:25, Sune Fischer wrote: >> >>> I believe that "move for move" 0x88 is faster because you don't have to do >>> that extra bit scan to get the square >> >>Which square are you referring to? Source square? Destination square? I may be >>able to help you... > >With bitboards (as I'm sure you know) you need a piece of assembler using bsf, >then you need to clear the bit afterwards. This is not needed with 0x88. > >ie: > while (padvances2) { > to=FirstOne(padvances2); > *move++=(to+16)|(to<<6)|(pawn<<12); > Clear(to,padvances2); > } > > >>When using bitboards and looking for a pattern instance for a _single_ square, >>think again : You should be looking for pattern instances on _all_ squares >>simulataneously. > >Right, I get the idea :) > >-S. > >>Puzzled, >>Steffan Sune, In your example, you are converting a bitboard (board centric) representation to a move array (move centric) representation. This would be required if you want to serialise (list, enumerate) the information. I would advise minimising (and postponing) the use of code which serialises (converts) the data to a non-bitboard form. To maximise the potential of your favoured board representation, it should be pervasive throughout your engine design. To turn to your example, I would favour using the bitboard padvances2 itself as a movelist element, rather than chop it up into movelist array elements (non-bitboards) as your code fragment does. At some point, a bitboard will need to be serialised ie. bits extracted one at a time. This should be done as late as possible in the data flow, as it is at this point the advantages of bitboards dissolve (ie. parallel computation). An example is at the point of move selection from a bitboard representing some candidate moves of equal quality (static move evaluation). I very rarely have a need to find the index of a set bit in a bitboard. This activity is a conversion from the bitboard representation to a co-ordinate representation. In an engine design that deals with units of data in bitboard format, it upsets matters when an co-ordinate format datum (= bit index) is introduced. Nearly the only case where I need the index is to print out the move! Cheers, Steffan

- Re: significant math
**Sune Fischer***04:35:46 11/20/02*- Re: significant math
**Steffan Westcott***06:37:11 11/20/02*- Re: significant math
**Gerd Isenberg***12:17:57 11/20/02*- Re: significant math
**Steffan Westcott***15:15:49 11/20/02*- Re: significant math
**Gerd Isenberg***23:32:50 11/20/02*

- Re: significant math

- Re: significant math
- Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***09:55:07 11/20/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Steffan Westcott***14:57:12 11/20/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***02:55:59 11/21/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Steffan Westcott***03:47:24 11/21/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***12:23:55 11/21/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Steffan Westcott***16:17:46 11/21/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***23:49:05 11/21/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Gerd Isenberg***04:42:51 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***08:53:54 11/22/02* - Re: Natural move generation with bitboards (was Re:significant math)
**Sune Fischer***08:37:56 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Gerd Isenberg***10:20:35 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Sune Fischer***13:17:29 11/22/02*

- Re: Natural move generation with bitboards (was Re:significant math)
- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***08:58:34 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Sune Fischer***09:19:42 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***09:52:54 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Steffan Westcott***16:08:27 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***16:44:52 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Steffan Westcott***17:19:09 11/22/02*

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)
- Re: Natural move generation with bitboards (was Re:significant math)
**Sune Fischer***10:38:50 11/22/02*- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***11:01:19 11/22/02*

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)
- Re: Natural move generation with bitboards (was Re:significant math)
**Alessandro Damiani***00:24:24 11/22/02*

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)
- Re: Natural move generation with bitboards (was Re:significant math)
**Daniel Clausen***03:55:11 11/21/02*

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: Natural move generation with bitboards (was Re:significant math)

- Re: significant math

- Re: significant math

This page took 0.05 seconds to execute

Last modified: Thu, 07 Jul 11 08:48:38 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.