Author: David Rasmussen
Date: 16:47:37 01/21/03
Go up one level in this thread
On January 21, 2003 at 19:18:34, Sean Mintz wrote: >>INLINE int FirstBit(const BitBoard bitboard) >>{ >> __asm >> { >> bsf eax,[bitboard+4] >> xor eax, 32 >> bsf eax,[bitboard] >> } >>} >> >>INLINE int LastBit(const BitBoard bitboard) >>{ >> __asm >> { >> bsr eax,[bitboard] >> sub eax,32 >> bsr eax,[bitboard+4] >> add eax,32 >> } >>} > >I tried using these in crafty and crafty froze up or something. Any ideas why? These worked for me (although not faster. I guess the compilers were optimizing the superfluous loads away). The PopCount() on the other hand, does not work for me. /David
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.