Polyglot 2.0.3 memory limit

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

User avatar
Ozymandias
Posts: 1535
Joined: Sun Oct 25, 2009 2:30 am

Re: Polyglot 2.0.3 memory limit

Post by Ozymandias »

One quirk, when running a batch file, polyglot doesn't unload and the next command gets stalled. I guess there must be a simple command to force the unloading.
User avatar
Ozymandias
Posts: 1535
Joined: Sun Oct 25, 2009 2:30 am

Re: Polyglot 2.0.3 memory limit

Post by Ozymandias »

Now that I think about it, when I first used it, the window didn't close when pressing a key, because it had not loaded the "pause 0" command. It looks like the exe doesn't really finish, even though the "all done" message, is displayed. Nothing you add in the batch, will close the program, then.
Joost Buijs
Posts: 1563
Joined: Thu Jul 16, 2009 10:47 am
Location: Almere, The Netherlands

Re: Polyglot 2.0.3 memory limit

Post by Joost Buijs »

Yes very strange, here it shows the same behavior, it does not exit after the makebook command.
The 32 bit executable from Harm Geert works fine in this respect.

I've got the source from git and I assume it is the correct version.
I didn't change anything in the source, maybe there is a very subtle bug in the code somewhere that has unwanted side effects.
Another possibility is that there is a dependency on the size of pointers 32 vs. 64 bit.
When I have some time, maybe later today, I will take a look at it.
I should not be too difficult to find what causes this problem (I hope).
User avatar
Ozymandias
Posts: 1535
Joined: Sun Oct 25, 2009 2:30 am

Re: Polyglot 2.0.3 memory limit

Post by Ozymandias »

Joost Buijs wrote:Yes very strange, here it shows the same behavior, it does not exit after the makebook command.
The 32 bit executable from Harm Geert works fine in this respect.

I've got the source from git and I assume it is the correct version.
I didn't change anything in the source, maybe there is a very subtle bug in the code somewhere that has unwanted side effects.
Another possibility is that there is a dependency on the size of pointers 32 vs. 64 bit.
When I have some time, maybe later today, I will take a look at it.
I should not be too difficult to find what causes this problem (I hope).
Well, I hope you're having fun, because other than me, there doesn't seem to be much demand for this upgrade :wink:
Joost Buijs
Posts: 1563
Joined: Thu Jul 16, 2009 10:47 am
Location: Almere, The Netherlands

Re: Polyglot 2.0.3 memory limit

Post by Joost Buijs »

Ozymandias wrote: Well, I hope you're having fun, because other than me, there doesn't seem to be much demand for this upgrade :wink:
Programming can be fun, and I also want to have a fully working 64 bit polyglot.
Unfortunately I don't have much time for it this week.

There is a routine 'option_init_pg()' to initialize all UCI options.
Somehow running this routine breaks the program exit, probably because it overwrites things in memory locations it should not touch.
It happens with both compilers MS and Intel, so I'm pretty sure it must be something in the code.
User avatar
Ozymandias
Posts: 1535
Joined: Sun Oct 25, 2009 2:30 am

Re: Polyglot 2.0.3 memory limit

Post by Ozymandias »

Joost Buijs wrote:Unfortunately I don't have much time for it this week.
No hurry.
Joost Buijs
Posts: 1563
Joined: Thu Jul 16, 2009 10:47 am
Location: Almere, The Netherlands

Re: Polyglot 2.0.3 memory limit

Post by Joost Buijs »

Ozymandias wrote:
Joost Buijs wrote:Unfortunately I don't have much time for it this week.
No hurry.
It has something to do with console mode versus pipe mode and the input thread, when the input thread is running it does not want to exit.
It is code from the dark ages, and I don't want to rewrite the whole thing.
Next weekend I will take another look at it.