Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: On Beowulf - long post

Author: martin fierz

Date: 06:33:00 06/06/01

Go up one level in this thread


On June 06, 2001 at 09:31:32, martin fierz wrote:

>[snip]
>>
>>In this piece of crap code i see everywhere:
>>
>>    if (side == WHITE)
>>        tsq = B->WhiteKnights;
>>    else
>>        tsq = B->BlackKnights;
>>
>>Note you can eliminate these branches, which speeds code up bigtime.
>[snip]
>
>so, who can enlighten a dummy like me? how exactly can i eliminate
>branches like this? i admit that my checkers program has some of these
>too... although i mostly do it like this
>
>if(color==WHITE)
argh... i hit tab return instead of return, ok, again:

if(color==WHITE)
 do lots of stuff
else
 do lots of other stuff.

is this still so stupid?

cheers
  martin



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.