Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Books

Author: Peter McKenzie

Date: 16:44:35 04/20/99

Go up one level in this thread


On April 20, 1999 at 19:21:07, James Robertson wrote:

>On April 20, 1999 at 11:00:08, James Robertson wrote:
>
>>I have become dissatisfied with the way my program searches for moves in it's
>>book; it simply takes too long. How do other programs do this? If I look at the
>>Crafty bookmaking code, I see stuff about "clusters". What does this mean? How
>>do EXchess, or Comet or other programs search their books?
>>
>>Thanks for any help!
>>James
>
>Thanks guys for your responses; let me think about them for a bit. I forgot to
>mention: my book is a list of hash codes that are sorted numerically. My engine
>jumps around through the numbers until it zeroes in on the hash code that
>matches. If there is a match, then that move is in the book. This is wonderful
>for small books but gets bad fast with larger ones. For instance, my program
>often can only make three book moves a second, and it's book is just 413k (26418
>entries).

A binary search in memory should let you do this much much faster then 3 every
second - perhaps its not the book that is slowing you down?  Or are you doing
the binary search on a file?  Even then, with suitable caching, you should get
much better speed than reported.
How are you timing this - using ICC?  If so, maybe there are other bottlenecks
involved...

Peter

>
>James



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.