<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Should I place a barrier before calling pdpotri()? in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011897#M19268</link>
    <description>&lt;P&gt;I am using&amp;nbsp;&lt;A href="https://software.intel.com/en-us/node/521465"&gt;&lt;SPAN style="color: rgb(102, 102, 102); font-family: 'Courier New', Courier, monospace; font-size: 13px; line-height: 18.2000007629395px;"&gt;pd&lt;/SPAN&gt;&lt;SPAN class="option" style="box-sizing: border-box; font-family: 'Courier New', Courier, monospace; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;potrf&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN class="option" style="box-sizing: border-box; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;&lt;FONT face="Arial, Tahoma, Helvetica, sans-serif"&gt;&lt;A href="https://software.intel.com/en-us/node/521465"&gt;()&lt;/A&gt; in order to perform the Cholesky decomposition. Then I want to call&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;A href="https://software.intel.com/en-us/node/521487"&gt;pdpotri()&lt;/A&gt;, in order to invert the matrix. The function is called from every process, just after&amp;nbsp;&lt;SPAN style="color: rgb(102, 102, 102); font-family: 'Courier New', Courier, monospace; font-size: 13px; line-height: 18.2000007629395px;"&gt;pd&lt;/SPAN&gt;&lt;SPAN class="option" style="box-sizing: border-box; font-family: 'Courier New', Courier, monospace; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;potrf&lt;/SPAN&gt;&lt;SPAN class="option" style="box-sizing: border-box; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;&lt;FONT face="Arial, Tahoma, Helvetica, sans-serif"&gt;(). Should I put a barrier there, so that I am sure that all the processes are done with the Cholesky factorization, and then move on to the inversion part, or it's not needed?&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="color: rgb(34, 34, 34); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 15px; line-height: 19.5px;"&gt;I wrote some examples with tiny inputs, which show that it's not needed, but I want to be sure that I am not just (un)lucky and face a problem with larger inputs.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 15 Jul 2015 20:08:24 GMT</pubDate>
    <dc:creator>Georgios_S_</dc:creator>
    <dc:date>2015-07-15T20:08:24Z</dc:date>
    <item>
      <title>Should I place a barrier before calling pdpotri()?</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011897#M19268</link>
      <description>&lt;P&gt;I am using&amp;nbsp;&lt;A href="https://software.intel.com/en-us/node/521465"&gt;&lt;SPAN style="color: rgb(102, 102, 102); font-family: 'Courier New', Courier, monospace; font-size: 13px; line-height: 18.2000007629395px;"&gt;pd&lt;/SPAN&gt;&lt;SPAN class="option" style="box-sizing: border-box; font-family: 'Courier New', Courier, monospace; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;potrf&lt;/SPAN&gt;&lt;/A&gt;&lt;SPAN class="option" style="box-sizing: border-box; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;&lt;FONT face="Arial, Tahoma, Helvetica, sans-serif"&gt;&lt;A href="https://software.intel.com/en-us/node/521465"&gt;()&lt;/A&gt; in order to perform the Cholesky decomposition. Then I want to call&amp;nbsp;&lt;/FONT&gt;&lt;/SPAN&gt;&lt;A href="https://software.intel.com/en-us/node/521487"&gt;pdpotri()&lt;/A&gt;, in order to invert the matrix. The function is called from every process, just after&amp;nbsp;&lt;SPAN style="color: rgb(102, 102, 102); font-family: 'Courier New', Courier, monospace; font-size: 13px; line-height: 18.2000007629395px;"&gt;pd&lt;/SPAN&gt;&lt;SPAN class="option" style="box-sizing: border-box; font-family: 'Courier New', Courier, monospace; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;potrf&lt;/SPAN&gt;&lt;SPAN class="option" style="box-sizing: border-box; color: rgb(102, 102, 102); font-size: 13px; line-height: 18.2000007629395px;"&gt;&lt;FONT face="Arial, Tahoma, Helvetica, sans-serif"&gt;(). Should I put a barrier there, so that I am sure that all the processes are done with the Cholesky factorization, and then move on to the inversion part, or it's not needed?&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="color: rgb(34, 34, 34); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 15px; line-height: 19.5px;"&gt;I wrote some examples with tiny inputs, which show that it's not needed, but I want to be sure that I am not just (un)lucky and face a problem with larger inputs.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 15 Jul 2015 20:08:24 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011897#M19268</guid>
      <dc:creator>Georgios_S_</dc:creator>
      <dc:date>2015-07-15T20:08:24Z</dc:date>
    </item>
    <item>
      <title> </title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011898#M19269</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;Could you please post your example/pseudo code the way you are calling these functions?&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jul 2015 03:43:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011898#M19269</guid>
      <dc:creator>VipinKumar_E_Intel</dc:creator>
      <dc:date>2015-07-16T03:43:39Z</dc:date>
    </item>
    <item>
      <title>Hi Vipin,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011899#M19270</link>
      <description>&lt;P&gt;Hi Vipin,&lt;/P&gt;

&lt;P&gt;&amp;nbsp; of course, here is how I call them:&lt;/P&gt;

&lt;PRE class="brush:cpp;"&gt;pdpotrf(type, &amp;amp;N, A_loc, &amp;amp;i_one, &amp;amp;i_one, descA, &amp;amp;info);
MPI_Barrier(MPI_COMM_WORLD); //do we need to set a barrier before inverting?
pdpotri(type, &amp;amp;N, A_loc, &amp;amp;i_one, &amp;amp;i_one, descA, &amp;amp;info);&lt;/PRE&gt;

&lt;P&gt;&amp;nbsp; I just worry that inverting may start, before some other process has terminated the Cholesky decomposition. Does pdpotri() take care of this? I mean, it checks and waits if needed. Or does pdpotri() work only in the submatrix of its calling process (i.e. A_loc in my code)? If so, then no barrier is needed.&lt;/P&gt;

&lt;P&gt;You can check the minor example &lt;A href="https://software.intel.com/en-us/forums/topic/561007"&gt;here&lt;/A&gt;, in post #4. The post's author is Ying, but it's pretty close to my code. So just imagine the code there, by just adding the last lines of code I posted here, that would make my new minor example.&lt;/P&gt;

&lt;P&gt;Thanks for taking time on my question,&lt;/P&gt;

&lt;P&gt;George&lt;/P&gt;</description>
      <pubDate>Thu, 16 Jul 2015 14:04:55 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011899#M19270</guid>
      <dc:creator>Georgios_S_</dc:creator>
      <dc:date>2015-07-16T14:04:55Z</dc:date>
    </item>
    <item>
      <title>Hi Georgios,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011900#M19271</link>
      <description>&lt;P&gt;Hi Georgios,&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&amp;nbsp; Since you are running these and part of&amp;nbsp;a single rank, you do not need to have a barrier in between, as these run one after other (or sequential manner) in the MPI proc.&lt;/P&gt;

&lt;P&gt;--Vipin&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jul 2015 05:26:31 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011900#M19271</guid>
      <dc:creator>VipinKumar_E_Intel</dc:creator>
      <dc:date>2015-07-17T05:26:31Z</dc:date>
    </item>
    <item>
      <title>Hi Vipin,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011901#M19272</link>
      <description>&lt;P&gt;Hi Vipin,&lt;/P&gt;

&lt;P&gt;&amp;nbsp; excuse me, but I do not understand this "and part of&amp;nbsp;a single rank". What does it mean? Maybe I am confused with the term rank.&lt;/P&gt;

&lt;P&gt;Thanks,&lt;/P&gt;

&lt;P&gt;George&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jul 2015 10:58:52 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011901#M19272</guid>
      <dc:creator>Georgios_S_</dc:creator>
      <dc:date>2015-07-17T10:58:52Z</dc:date>
    </item>
    <item>
      <title>Just for the record, I had</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011902#M19273</link>
      <description>&lt;P&gt;Just for the record, I had asked something similar in Stackoverflow and the response was in&lt;SPAN class="short_text" id="result_box" lang="en"&gt;&lt;SPAN class="hps"&gt; agreement&lt;/SPAN&gt;&lt;/SPAN&gt; with Vipin's post. I got this comment:&lt;/P&gt;

&lt;P&gt;&lt;SPAN class="comment-copy"&gt;Explicit barrier synchronisation is almost never needed in &lt;B&gt;correct&lt;/B&gt; MPI applications that perform pure message passing as the synchronisation occurs naturally through the data dependency between the send and receive calls. Barriers are usually needed in order to synchronise with the completion of external events, e.g. concurrent data I/O, or when benchmarking in order to get the processes in sync.&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;and this answer:&lt;/P&gt;

&lt;TABLE&gt;
	&lt;TBODY&gt;
		&lt;TR&gt;
			&lt;TD class="votecell"&gt;
				&lt;DIV class="vote"&gt;&amp;nbsp;&lt;/DIV&gt;
			&lt;/TD&gt;
			&lt;TD class="answercell"&gt;
				&lt;DIV class="post-text" itemprop="text"&gt;
					&lt;P&gt;While I have not looked into the details of &lt;CODE&gt;pdpotri()&lt;/CODE&gt; and &lt;CODE&gt;pdpotrf()&lt;/CODE&gt;, I see two cases:&lt;/P&gt;

					&lt;P&gt;1) There needs to be a barrier between the two functions. In this case, however, because &lt;CODE&gt;pdpotrf()&lt;/CODE&gt; must always come after &lt;CODE&gt;pdpotri()&lt;/CODE&gt;, it would make the most sense for there to be an implicit boundary built-in to the beginning of &lt;CODE&gt;pdpotri()&lt;/CODE&gt;.&lt;/P&gt;

					&lt;P&gt;2) There does not need to be a barrier between the two functions.&lt;/P&gt;

					&lt;P&gt;In both cases, it should not be necessary for you to write your own explicit barrier using &lt;CODE&gt;MPI_Barrier()&lt;/CODE&gt;.&lt;/P&gt;
				&lt;/DIV&gt;
			&lt;/TD&gt;
		&lt;/TR&gt;
	&lt;/TBODY&gt;
&lt;/TABLE&gt;</description>
      <pubDate>Fri, 17 Jul 2015 11:02:31 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/Should-I-place-a-barrier-before-calling-pdpotri/m-p/1011902#M19273</guid>
      <dc:creator>Georgios_S_</dc:creator>
      <dc:date>2015-07-17T11:02:31Z</dc:date>
    </item>
  </channel>
</rss>

