Why are Java Engines slow in Tournament mode?

Discussion of anything and everything relating to chess playing software and machines.

Moderator: Ras

swami
Posts: 6659
Joined: Thu Mar 09, 2006 4:21 am

Why are Java Engines slow in Tournament mode?

Post by swami »

Either it takes so much hash size or Java consumes enough space and still the GUI freezes.

Some of the engines that play slow

Flux
Mediocre

Flux dont seem to work at all.
Mediocre works but it is quite slow compared to other non java engines.

I wonder if this has to do with programming language the engine was written in or something?
User avatar
Dr.Wael Deeb
Posts: 9773
Joined: Wed Mar 08, 2006 8:44 pm
Location: Amman,Jordan

Re: Why are Java Engines slow in Tournament mode?

Post by Dr.Wael Deeb »

hi pal,
Flux works fine as a uci installed engine,I test Flux 0.9 and Flux 2.1 8-)
As for Mediocre,it works fine as a winboard installed program....
_No one can hit as hard as life.But it ain’t about how hard you can hit.It’s about how hard you can get hit and keep moving forward.How much you can take and keep moving forward….
swami
Posts: 6659
Joined: Thu Mar 09, 2006 4:21 am

Re: Why are Java Engines slow in Tournament mode?

Post by swami »

Dr.Wael Deeb wrote:hi pal,
Flux works fine as a uci installed engine,I test Flux 0.9 and Flux 2.1 8-)
As for Mediocre,it works fine as a winboard installed program....
Hi Wael,

Flux doesnt work for me,it seems CCRL too has problems regarding hash size
and java memory usage with Flux but the engine works for them this way,I heard the author may fix the bug.
fluxroot

Re: Why are Java Engines slow in Tournament mode?

Post by fluxroot »

swami wrote:
Dr.Wael Deeb wrote:hi pal,
Flux works fine as a uci installed engine,I test Flux 0.9 and Flux 2.1 8-)
As for Mediocre,it works fine as a winboard installed program....
Hi Wael,

Flux doesnt work for me,it seems CCRL too has problems regarding hash size
and java memory usage with Flux but the engine works for them this way,I heard the author may fix the bug.
Precise memory allocation and deallocation in Java (and C# btw) is nearly impossible. With the help of the Eclipse profiler however I managed to calculate the hash allocation almost exactly for Flux.

So although the task manager on windows shows a greater value for java.exe, Flux really uses only the given number of mb for the hash tables.

Sorry but that's how Java works. However I'm currently rewriting Flux to C++. :D So memory management should be no problem anymore.

Cheers
Poky
swami
Posts: 6659
Joined: Thu Mar 09, 2006 4:21 am

Re: Why are Java Engines slow in Tournament mode?

Post by swami »

Precise memory allocation and deallocation in Java (and C# btw) is nearly impossible. With the help of the Eclipse profiler however I managed to calculate the hash allocation almost exactly for Flux.

So although the task manager on windows shows a greater value for java.exe, Flux really uses only the given number of mb for the hash tables.

Sorry but that's how Java works. However I'm currently rewriting Flux to C++. :D So memory management should be no problem anymore.

Cheers
Poky
Flux would be very interesting opponent for many engines out there.I hope you get the engine to work somehow as some of the java engines do work without freezing, whereas Flux doesn't and I'm missing the most interesting opponent for other competitors out there.