Doubling the cores or doubling the time?

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

Moderators: hgm, Rebel, chrisw

h1a8
Posts: 508
Joined: Fri Jun 04, 2010 7:23 am

Doubling the cores or doubling the time?

Post by h1a8 »

Someone once told me that with more cores the search gets thicker on average. So I ask

Which is stronger:

An engine with 4 processors with the time control 40moves in 4 minutes or an engine using two processors but having the time control of 40 moves in 8 minutes (double the time)?

I have a core 2 duo and I want to emulate engine matches as if the engines are running on 4 cores.

Lastly, can fritz gui do seperate time controls for each engine?
If not, then what gui can?
rbarreira
Posts: 900
Joined: Tue Apr 27, 2010 3:48 pm

Re: Doubling the cores or doubling the time?

Post by rbarreira »

No chess search algorithm uses the cores perfectly, so doubling the time is certainly better than doubling the number of threads.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Doubling the cores or doubling the time?

Post by hgm »

h1a8 wrote:If not, then what gui can?
In WinBoard the time-control dialog has input fields for time-odds factors of first and second engine (initialized to 1 each time you open the dialog). You could type another number there, and the time of that engine would be reduced by it. (Note that time odds really only makes sense in ponder off games!)

When you are running a tourney you typically want a time-odds to follow a specific engine; you can then install that engine with the extra option /firstTimeOdds=2 (say), to give it only half the usual time.
bob
Posts: 20943
Joined: Mon Feb 27, 2006 7:30 pm
Location: Birmingham, AL

Re: Doubling the cores or doubling the time?

Post by bob »

h1a8 wrote:Someone once told me that with more cores the search gets thicker on average. So I ask

Which is stronger:

An engine with 4 processors with the time control 40moves in 4 minutes or an engine using two processors but having the time control of 40 moves in 8 minutes (double the time)?

I have a core 2 duo and I want to emulate engine matches as if the engines are running on 4 cores.

Lastly, can fritz gui do seperate time controls for each engine?
If not, then what gui can?
There's no reliable way to do what you want other than to use 4 cores. For example, (1) are you POSITIVE that both programs get the same benefit from 4 cores, or does one have a better SMP implementation that produces greater benefit? Doubling the time for both says both are equal. (2) does doubling the cores REALLY double the total compute time used effectively, or does it just double the total compute time used? Will EITHER program actually run 2x faster on 4 cores? Probably not.
User avatar
hgm
Posts: 27790
Joined: Fri Mar 10, 2006 10:06 am
Location: Amsterdam
Full name: H G Muller

Re: Doubling the cores or doubling the time?

Post by hgm »

I guess his idea was to let it use 4 threads on 2 cores, doubling the time. Still not the real thing, but closer...
Frank Quisinsky
Posts: 6808
Joined: Wed Nov 18, 2009 7:16 pm
Location: Gutweiler, Germany
Full name: Frank Quisinsky

Re: Doubling the cores or doubling the time?

Post by Frank Quisinsky »

Hi Leon,

1 core = factor 1.0
2 cores = max. factor 1.7 ... today I believe 1.8
4 cores = max. factor 3.2 ... today I believe 3.3

40 moves in 4 minutes with factor 3.2
4 x 3.2 = 12,8

40 moves in 8 minutes with factor 1.7
8 x 1.7 = 13,6

Better is 40 moves in 8 minutes with 2 cores!

On your dual core system:

40 moves in 04 minutes = with 1 core
40 moves in 07 minutes = simulation with 2 cores
40 moves in 13 minutes = simulation with 4 cores

Note that not all engines comes with factor 1.8 with 2 cores or 3.2 with 4 cores.

Example:
Patzer by Roland Pfister = factor 1.3 with two cores
Can be test, very easy with different positions.

GUI can be used?
Arena

Hint:
With ponder = on you have + 45 ELO.

Double speed = 55 ELO more
55 x 1.7 / 2 = 46,75 ELO

After my experiments ~ 55 ELO.
Much others have the opinion 60-70 ELO.
Old thougths. With actual hardware I tested out 55 ELO.
I am thinking that double speed will give you not exactly 60-70 ELO. With more and more hardware power ... 55 ELO, 50 ELO ... but I am not sure with it.

Ponder = On matches are more interesting. Different engines produced a better time mangement. Often moves with more as one core are not to reproduced.

If you have interest to test such things ...
You have to use ponder = on.

Best
Frank
h1a8
Posts: 508
Joined: Fri Jun 04, 2010 7:23 am

Re: Doubling the cores or doubling the time?

Post by h1a8 »

Thanks a lot.

1. So arena can do separate time controls for different engines right?

2. Also, is kn/s (not for Rybka though) a good indicator of speed up?
For example, if Stockfish is getting 1000kn/s with 2 cores and 1700kn/s with 4 cores then can we assume a 1.7 speedup factor and thus give Stockfish with 2 cores 1.7x more time to equal Stockfish on 4 cores?
Frank Quisinsky
Posts: 6808
Joined: Wed Nov 18, 2009 7:16 pm
Location: Gutweiler, Germany
Full name: Frank Quisinsky

Re: Doubling the cores or doubling the time?

Post by Frank Quisinsky »

Leon,

1. Think so, no looking in detail in newer versions of Arena since I gave up my work in Arena around 2006.

2. Not with positions per seconds. I test it out with three clear positions (middelgame, late middlegame, early endgame without tablebases and very little hashtables).

Example:
1. Mate in 10: 1 Core = 1:52, 2 Cores = 1:10, 4 Cores = 0:38
2. move 56 best move = x: 1 Core = 1.55, 2 Cores = 1:17, 4 Cores = 0:41
3. third one x

1. 1:52 + 1:55 + x : 3 =
2. 1:10 + 1:17 + x : 3 =
3.

And calculate the average.
If you like you can try the same and compare it with nps.
I am sure other ways are possible and good too.

Best
Frank