Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Chess Tiger for Palm!! [Re: hash tables]

Author: Christophe Theron

Date: 15:49:27 05/07/01

Go up one level in this thread


On May 07, 2001 at 17:57:37, Ian Osgood wrote:

>Here is the reference I was thinking about, from the FAQ at the ChessGenius web
>site:
>
>"What about Hash tables?  The memory organisation of Palm devices makes hash
>tables difficult, maybe impossible. Only a small amount of memory (much less
>than 64Kb) can be used as fast read/write memory, the rest is dedicated to
>storage."
>
>I'm glad to hear that you at least found a solution.
>
>Ian



It is true that you do not have access to flat memory in the Palm. Actually you
have, but most of the memory is "protected". That is, you can read it with a
normal pointer (pointers can point anywhere in the Palm address space), but you
cannot write it directly.

This is a very simple and clever system that prevents a buggy program from
crashing the entire system and erase your valuable data.

If you want to write somewhere in a block you have allocated (I mean outside
your data segment), you must ask the system to do it for you. Of course the
system will first check if the block you are writting into is one of yours.

It is possible to bypass this protection system when you know what you are
doing.


Let me tell you my version about what Richard has said: he wanted to port an
existing version of his programs without changing a line of assembly. Because of
the special memory protection scheme of the Palm it was easier for him to pick a
program that did not use hash tables. The most advanced of his programs which
does not use hash tables is the Roma (1987), so he ported the Roma and just had
to write a GUI around it.


My way of doing it is different. I have decided that I want only one source code
for the PC version, the Palm version, the WinCE&PocketPC version and the Linux
version. And that the Palm and WinCE versions would not be downgraded versions
of Chess Tiger. So when I find an improvement, all the Tiger engines on all
platforms benefit from it.


After the release of Chess Tiger 12.0 I have rewritten a lot of things inside
the engine to achieve this goal. I have rewritten the move format, the move
generator, the move make/unmake routines and the hash table management. That's
why I can manage hash tables even on the Palm, that's why Chess Tiger is able to
perform well on a 16/32 bits processor like the DragonBall (the heart of the
Palm), and that's why any new version of Chess Tiger for PC will be available
instantly for the Palm.




    Christophe



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.