[Shootout-list] Re: ring of processes
Aaron Denney
wnoise@ofb.net
Tue, 5 Oct 2004 09:00:58 +0000 (UTC)
On 2004-10-05, Bengt Kleberg <bengt.kleberg@ericsson.com> wrote:
> Raymond Racine wrote:
> ...deleted
>>
>> I think a concise text description of the algorithm is what I am looking
>> for.
>
> ok. since we have several better ideas than mine already suggested i
> think it is premature to describe any one idea. i will try to summeraise
> what i belive to have understood from the suggestions:
>
> 1 any simple topology would make it worth ''cheating'' by having several
> channels setup directly between the processes that should exchange messages.
Well, I wouldn't call it cheating, so much as "the natural way to solve
this problem doesn't test what you want to test".
> 2 if we insist upon testing that all connections in a complex topology
> actually work we will end up without a nice linear ''correlation''
> between the number of processes and the number of messages.
True, but I don't think it matters. Fix some number of processes, then
let the number of messages be a varying input parameter.
> (i still think that we need to have a variable number of processes to
> avoid that the creation of processes takes up all the test time for a
> small number of messages)
Just have repeated messages, and the repeat factor vary, and keep the
number of processes small.
> it seems to me that it would be simpler to mandate one channel per
> process, than to devise a test that makes this the best solution.
Well, I think the "natural solution" for my all-to-all connections is
one input channel per process, with each process having access to all
the input channels of the others -- otherwise P^2 channels are needed
and managing them gets to be a pain.
Was my proposal in <slrncm3trg.nuv.wnoise@ofb.net> clear?
N*(P-1) messages flying at a time, each relayed through each process, so
send P times, for a total of N*(P-1)*P total messages sent.
I could write pseudo-code & whip up a Haskell (and possibly C/fork/IPC)
implementation if anyone wanted.
I could see embellishments like L*N*(P-1) low-priority and N*(P-1)
high-priority messages live at once, if you want to test selective
receiving.
--
Aaron Denney
-><-