<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: IO Profiling of Applications: MPI Apps</title>
	<atom:link href="http://www.linux-mag.com/id/7728/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.linux-mag.com/id/7728/</link>
	<description>Open Source, Open Standards</description>
	<lastBuildDate>Sat, 05 Oct 2013 13:48:18 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
	<item>
		<title>By: rhysu</title>
		<link>http://www.linux-mag.com/id/7728/#comment-8040</link>
		<dc:creator>rhysu</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.linux-mag.com/id/7728/#comment-8040</guid>
		<description>&lt;p&gt;Your use of an intermediate shell script to kick off your code gives undefined behavior according to the &lt;a&gt;MPI-2 standard section 5.3.2: Starting Processes and Establishing Communication&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;
MPI does not say what happens if the program you start is a shell script and that shell script starts a program that calls MPI_INIT. Though some implementations may allow you to do this, they may also have restrictions, such as requiring that arguments supplied to the shell script be supplied to the program, or requiring that certain parts of the environment not be changed.
&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;It\&#039;ll probably work just fine on many implementations, but there\&#039;s always the chance it\&#039;ll bomb outright.  Or bomb in subtle ways.
&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Your use of an intermediate shell script to kick off your code gives undefined behavior according to the <a>MPI-2 standard section 5.3.2: Starting Processes and Establishing Communication</a>:</p>
<blockquote><p>
MPI does not say what happens if the program you start is a shell script and that shell script starts a program that calls MPI_INIT. Though some implementations may allow you to do this, they may also have restrictions, such as requiring that arguments supplied to the shell script be supplied to the program, or requiring that certain parts of the environment not be changed.
</p>
</blockquote>
<p>It\&#8217;ll probably work just fine on many implementations, but there\&#8217;s always the chance it\&#8217;ll bomb outright.  Or bomb in subtle ways.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tjrob</title>
		<link>http://www.linux-mag.com/id/7728/#comment-8041</link>
		<dc:creator>tjrob</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.linux-mag.com/id/7728/#comment-8041</guid>
		<description>&lt;p&gt;NOTE: When using $@, it should normally be enclosed in double quotes: \&quot;$@\&quot;. With the quotes, bash will quote each individual argument when expanding the list of arguments. As you wrote it, without the quotes, any script arguments containing spaces will be improperly parsed for the executable; with the double-quotes all is well.
&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>NOTE: When using $@, it should normally be enclosed in double quotes: \&#8221;$@\&#8221;. With the quotes, bash will quote each individual argument when expanding the list of arguments. As you wrote it, without the quotes, any script arguments containing spaces will be improperly parsed for the executable; with the double-quotes all is well.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jsquyres</title>
		<link>http://www.linux-mag.com/id/7728/#comment-8042</link>
		<dc:creator>jsquyres</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.linux-mag.com/id/7728/#comment-8042</guid>
		<description>&lt;p&gt;FWIW, you can use /tmp/strace.out.$OMPI_COMM_WORLD_RANK.  This is an Open MPI-specific way to know which MPI process you are -- each process will have a unique value of $OMPI_COMM_WORLD_RANK in the range [0,N).&lt;/p&gt;
&lt;p&gt;This might be slightly more friendly than a random PID number.
&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>FWIW, you can use /tmp/strace.out.$OMPI_COMM_WORLD_RANK.  This is an Open MPI-specific way to know which MPI process you are &#8212; each process will have a unique value of $OMPI_COMM_WORLD_RANK in the range [0,N).</p>
<p>This might be slightly more friendly than a random PID number.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: laytonjb</title>
		<link>http://www.linux-mag.com/id/7728/#comment-8043</link>
		<dc:creator>laytonjb</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.linux-mag.com/id/7728/#comment-8043</guid>
		<description>&lt;p&gt;@rhysu - didn\&#039;t know that. So far I\&#039;ve used this approach with Open MPI, Intel MPI, HP MPI (before it was sold), Platform MPI, MVAPICH, and MPICH2. So pretty much all of the worked at some point. But as you point out there are no guarantees. &lt;/p&gt;
&lt;p&gt;Jeff S. - any comment on why that section is in the MPI-2 standard?&lt;/p&gt;
&lt;p&gt;@tjrob - thanks for the bash-fu. It shows my lack of serious bash skills :)  But to make sure I understand if I have a bunch of arguments separate by spaces then it gets expanded incorrectly for the executable? I\&#039;ve run codes before using this method and the arguments had spaces - so I\&#039;m wondering if the executable just parsed the arguments correctly by chance or if there is something else going on.&lt;/p&gt;
&lt;p&gt;@jsquyres - Good point. It would also be good to echo that env variable to the output file so that we know how the PID-files match to the ranks.&lt;/p&gt;
&lt;p&gt;Thanks!&lt;/p&gt;
&lt;p&gt;Jeff
&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>@rhysu &#8211; didn\&#8217;t know that. So far I\&#8217;ve used this approach with Open MPI, Intel MPI, HP MPI (before it was sold), Platform MPI, MVAPICH, and MPICH2. So pretty much all of the worked at some point. But as you point out there are no guarantees. </p>
<p>Jeff S. &#8211; any comment on why that section is in the MPI-2 standard?</p>
<p>@tjrob &#8211; thanks for the bash-fu. It shows my lack of serious bash skills :)  But to make sure I understand if I have a bunch of arguments separate by spaces then it gets expanded incorrectly for the executable? I\&#8217;ve run codes before using this method and the arguments had spaces &#8211; so I\&#8217;m wondering if the executable just parsed the arguments correctly by chance or if there is something else going on.</p>
<p>@jsquyres &#8211; Good point. It would also be good to echo that env variable to the output file so that we know how the PID-files match to the ranks.</p>
<p>Thanks!</p>
<p>Jeff</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rpnabar</title>
		<link>http://www.linux-mag.com/id/7728/#comment-8044</link>
		<dc:creator>rpnabar</dc:creator>
		<pubDate>Wed, 30 Nov -0001 00:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.linux-mag.com/id/7728/#comment-8044</guid>
		<description>&lt;p&gt;@trojb\&#039;s comment:&lt;/p&gt;
&lt;p&gt;Use double quotes to prevent word splitting. [2]  An argument enclosed in double quotes presents itself as a single word, even if it contains whitespace separators.&lt;/p&gt;
&lt;p&gt;More here: http://tldp.org/LDP/abs/html/quotingvar.html
&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>@trojb\&#8217;s comment:</p>
<p>Use double quotes to prevent word splitting. [2]  An argument enclosed in double quotes presents itself as a single word, even if it contains whitespace separators.</p>
<p>More here: <a href="http://tldp.org/LDP/abs/html/quotingvar.html" rel="nofollow">http://tldp.org/LDP/abs/html/quotingvar.html</a></p>
]]></content:encoded>
	</item>
</channel>
</rss>