Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Preparations for parallel search

Author: Tord Romstad

Date: 07:23:39 07/09/04

Go up one level in this thread


On July 09, 2004 at 10:08:20, Robert Hyatt wrote:

>On July 09, 2004 at 09:53:02, Daniel Clausen wrote:
>
>>On July 09, 2004 at 09:47:36, Tord Romstad wrote:
>>
>>>But as far as I can see, I would be forced to pass an extra pointer to most
>>>of the chess-related functions (search(), evaluate(), generate_moves(),
>>>make_move() etc.).  A bit ugly, but I suppose I could live with that.
>>
>>What do you mean with ugly here?
>>
>>To me, functions which work on exactly the arguments they get and maybe return
>>something are much clearer than functions which work on data that is cluttered
>>all over the place. :)

I agree in principle, but in this particular case we are talking about
a pointer to a giant structure containing all the "thread global" variables.
Working with the data in such a structure isn't very different from working
on global variables, IMHO.

>A pointer requires a register.  The X86 doesn't have very many.  This turns into
>an efficiency issue, but the gains far outweigh the small cost.

This isn't a problem for me, I think.  My main development platform is the
PowerPC, which (I think) has more registers than the X86.  Of course I would
like my engine to run on X86 machines as well, but I don't care if there is
a slight slowdown there.

Tord



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.