[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-gnubg] Re: [Fwd: gnubg search function]

From: Thomas Hauk
Subject: [Bug-gnubg] Re: [Fwd: gnubg search function]
Date: Tue, 1 Apr 2003 09:51:02 -0700 (MST)

On Thu, 27 Mar 2003, Øystein Johansen wrote:
> >2) Where does the current search function hide? I'm told gnubg just
> >performs a 1-ply full-tree search. Is this a part of eval.c? It's a huge
> >file. Can you help point me toward the function?
> The search functions are all hidden in eval.c. It's implemented as a recusive 
> function. See EvaluatePositionCubeful3, EvaluatePositionCubeful4, 
> EvaluatePosition, EvaluatePositionFull and EvaluatePositionCache.

I've stared at the code for a while, but I'd like to just confirm my 

EvaluatePosition calls EvaluatePositionCache to determine if the state has 
already been evaluated and cached in order to speed things up. If it 
hasn't, then EvaluatePositionCache calls EvaluatePositionFull. 
EvaluatePositionFull contains a recursive call to EvaluatePositionCache if 
nPlies is greater than 0; else it performs a leaf evaluation.

Am I correct to interpret a return value of 0 as "nothing went wrong" and 
any other value to mean "something went wrong"?

Does gnubg simply perform a 1-ply search out of the box?

How do EvaluatePositionCubeful3 and 4 factor into the search?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]