Newsgroups: comp.parallel.pvm
From: Willy Weisz <weisz@edvz.tuwien.ac.at>
Subject: Re: Master and Slave put together...
Organization: TU Wien, EDV-Zentrum
Date: 12 Sep 1995 15:53:13 GMT
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <434ad9$fkv@news.tuwien.ac.at>

ma_adlum@uxmail.ust.hk (Lum Wing Fung Adrian) wrote:
>Dear all,
>	I have a little program here :
>
>/* stuff deleted */
>/* this executable is a.out */
>
>	if (pvm_parent () == PvmNoParent)
>	{
>		pvm_spawn ("a.out", /*... */);
>		/* Master stuff */
>	}
>	else
>	{
>		/* Slave stuff */
>	}
>
>/* End of the a.out */
>	
>	This can be executed in PVM with normal output.  However,
>if run it in XPVM, the program stopped, or actually waited!
>
>	On the other hand, I split this into two pieces :
>
>/* this executable is b.out */
>
>	pvm_spawn ("c.out", /* ... */);
>	/* Master stuff */
>
>/* End of b.out */
>
>/* this executable is c.out */
>
>	/* Slave stuff */
>
>/* End of c.out */
>
>	Then, the program can be run normally in both PVM and XPVM.
>
>	Can anyone tell me what the differences between them?
>
>	Thanks in advance.
>
>--
When the program is started by XPVM it _has_ a parent task, namely XPVM!!!!!

Therefor pvm_parent() never returns PvmNoParent.


Regards

Willy Weisz


