how to use Glaurung with 8 CPU ??

Discussion of chess software programming and technical issues.

Moderators: hgm, Rebel, chrisw

Daniel Charles

how to use Glaurung with 8 CPU ??

Post by Daniel Charles »

Dear Tord ,

Do you know how I could play with Glaurung epsilon using 8 cpu on Fritz GUI ?
UCI Option stop at 4 CPU :(

Or if anyone knows the answer (fell free to help :D )


Thanks

Daniel
Dann Corbit
Posts: 12540
Joined: Wed Mar 08, 2006 8:57 pm
Location: Redmond, WA USA

Re: how to use Glaurung with 8 CPU ??

Post by Dann Corbit »

I think you may have to recompile it.
I guess that maximum CPUs is a compile time constant.
NowCan
Posts: 7
Joined: Mon Aug 13, 2007 10:16 am

Re: how to use Glaurung with 8 CPU ??

Post by NowCan »

Yes.
In glaurung.h


// Comment out the following line for a single-threaded executable:
#define SMP

#if defined(SMP)
const int MaxNumOfThreads = 4;
#else
const int MaxNumOfThreads = 1;
#endif
Volker Pittlik
Posts: 619
Joined: Wed Mar 08, 2006 9:10 pm
Location: Murten / Morat, Switzerland
Full name: Volker Pittlik

Re: how to use Glaurung with 8 CPU ??

Post by Volker Pittlik »

NowCan wrote:Yes.
In glaurung.h
This is only true for older versions. In Glaurung 2 e/5

a) there is no glaurung.h
b) the maximum number of threads is just an UCI option

NowCan wrote:// Comment out the following line for a single-threaded executable:
#define SMP

#if defined(SMP)
const int MaxNumOfThreads = 4;
...
Please notice that

Code: Select all

volker@vpittlik:~/schach/glaurung/g2e5/src> ./glaurung2-e5
uci
id name Glaurung 2-epsilon/5
...
option name Threads type spin default 1 min 1 max 4
uciok
The max number of threads is 4. Therefore I think it seems impossible to use 8 CPUs, but please correct me if I'm wrong.

Volker
Tord Romstad
Posts: 1808
Joined: Wed Mar 08, 2006 9:19 pm
Location: Oslo, Norway

Re: how to use Glaurung with 8 CPU ??

Post by Tord Romstad »

Hi all,

It's better to direct technical questions about Glaurung to the Winboard forum. Computer chess has very low priority for me at the moment, and I don't follow the discussions on the CCC very carefully. I was lucky to spot this thread.
Volker Pittlik wrote: Please notice that

Code: Select all

volker@vpittlik:~/schach/glaurung/g2e5/src> ./glaurung2-e5
uci
id name Glaurung 2-epsilon/5
...
option name Threads type spin default 1 min 1 max 4
uciok
The max number of threads is 4. Therefore I think it seems impossible to use 8 CPUs, but please correct me if I'm wrong.
You are right, without changing the source code, the maximum number of threads in Glaurung 2 - ε/5 is 4. This limit can be changed by editing the constant THREAD_MAX in thread.h. However, I don't think doing so would improve the speed of the program on a computer with 8 CPUs. Glaurung 1.2.1 is only very slightly faster with 6 threads than with 4 threads, and with 8 threads it is actually a tiny bit slower than with 4 threads. I expect Glaurung 2 - ε/5 to behave similarly in this respect.

I have some hope that Glaurung 2.0 (which is almost ready) will scale somewhat better to computers with many CPUs, but because I have no computer with more than 2 CPUs for my own testing and development, it is hard to be sure.

Tord
Volker Pittlik
Posts: 619
Joined: Wed Mar 08, 2006 9:10 pm
Location: Murten / Morat, Switzerland
Full name: Volker Pittlik

Re: how to use Glaurung with 8 CPU ??

Post by Volker Pittlik »

Tord Romstad wrote:It's better to direct technical questions about Glaurung to the Winboard forum...
Yes! Please do so as Tord has written!

(Insert random number of stupid smilies here: .>....<)

Volker
BBauer
Posts: 658
Joined: Wed Mar 08, 2006 8:58 pm

Re: how to use Glaurung with 8 CPU ??

Post by BBauer »

I could do some test using 4 threads on a Xeon box running at 3GHz with some memory, up to 16 Gb.

BTW, yesterday I could not find your homepage.

best wishes
Bernhard
Tony Thomas

Re: how to use Glaurung with 8 CPU ??

Post by Tony Thomas »

Yes! Please do so as Tord has written!

:D :) :( :o :shock: :? 8-) :lol: :cry: :oops: :P :evil: :twisted: :roll: :wink: :arrow: :idea: :?: :!: :x :shock: :D :) :D :) :( :o :shock: :? 8-) :lol: :cry: :oops: :P :evil: :twisted: :roll: :wink: :arrow: :idea: :?: :!: :x :shock: :D :) :D :) :( :o :shock: :? 8-) :lol: :cry: :oops: :P :evil: :twisted: :roll: :wink: :arrow: :idea: :?: :!: :x :shock: :D :) :D :) :( :o :shock: :? 8-) :lol: :cry: :oops: :P :evil: :twisted: :roll: :wink: :arrow: :idea: :?: :!: :x :shock: :D :)

Volker