<?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 OpenMp turncation error in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828852#M51385</link>
    <description>This is not a data race condition. The result printout indicates a single bit difference in the least significant bit of the result. I suggest you consult the archetecture manual to see what influences rounding behavior, in particular, how is rounding of 0.5 of the mantissa is handled.&lt;BR /&gt;&lt;BR /&gt; always round up&lt;BR /&gt; always round down&lt;BR /&gt; alternately round up/down&lt;BR /&gt;pseudo randomly round up/down&lt;BR /&gt;&lt;BR /&gt;When either of the last two methods are employed, then by varying the thread count (slice points) it is possible to generate different rounding results.&lt;BR /&gt;&lt;BR /&gt;Jim Dempsey&lt;BR /&gt;</description>
    <pubDate>Tue, 07 Sep 2010 13:08:22 GMT</pubDate>
    <dc:creator>jimdempseyatthecove</dc:creator>
    <dc:date>2010-09-07T13:08:22Z</dc:date>
    <item>
      <title>OpenMp turncation error</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828849#M51382</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;Im quite new to openMP and I found that the results of the serial and parallel version of the following code has a difference at the last decimalplace.&lt;BR /&gt;&lt;BR /&gt;I use intel fortran compiler in an intel 64 bit machine under fedora 10.&lt;BR /&gt;&lt;BR /&gt;Can anybody pls tell me a way how can this be elminated.&lt;BR /&gt;&lt;BR /&gt;----------------------------------------------------------------------------&lt;BR /&gt;program main&lt;BR /&gt;implicit none&lt;BR /&gt;integer i,j,l&lt;BR /&gt;double precision a(9999)&lt;BR /&gt;&lt;BR /&gt;c initialisation&lt;BR /&gt;do i=1,9999&lt;BR /&gt;a(i)=i**(.2)&lt;BR /&gt;enddo&lt;BR /&gt;----------------------------------------------------------&lt;BR /&gt;!$omp parallel do default(shared) private(i,j)&lt;BR /&gt;do j=1,20&lt;BR /&gt;do i=1,9999&lt;BR /&gt;a(i)=a(i)+i/3.d0&lt;BR /&gt;enddo&lt;BR /&gt;enddo&lt;BR /&gt;!$omp end parallel do&lt;BR /&gt;-----------------------------------------------------------&lt;BR /&gt;&lt;BR /&gt;open(file='pxx',unit=30)&lt;BR /&gt;do i=1,9999&lt;BR /&gt;write(30,*) i,a(i)&lt;BR /&gt;enddo&lt;BR /&gt;&lt;BR /&gt;end&lt;BR /&gt;-----------------------------------------------------------&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;here is some sample result comparison.&lt;BR /&gt;9959c9959&lt;BR /&gt;&amp;lt; 9959 66399.6377247174&lt;BR /&gt;---&lt;BR /&gt;&amp;gt; 9959 66399.6377247175&lt;BR /&gt;9973c9973&lt;BR /&gt;&amp;lt; 9973 66492.9728295009&lt;BR /&gt;---&lt;BR /&gt;&amp;gt; 9973 66492.9728295008&lt;BR /&gt;9980c9980&lt;BR /&gt;&amp;lt; 9980 66539.6403811772&lt;BR /&gt;---&lt;BR /&gt;&amp;gt; 9980 66539.6403811773&lt;BR /&gt;9985c9985&lt;BR /&gt;&amp;lt; 9985 66572.9743463199&lt;BR /&gt;---&lt;BR /&gt;&amp;gt; 9985 66572.9743463198&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Sep 2010 16:39:59 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828849#M51382</guid>
      <dc:creator>chat1983</dc:creator>
      <dc:date>2010-09-06T16:39:59Z</dc:date>
    </item>
    <item>
      <title>OpenMp turncation error</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828850#M51383</link>
      <description>There's a fair chance your j loop is optimized away (pushed inside the i loop and evaluated at compile time) when you disable OpenMP. Did you check for that, and for ways to prevent it, if it's not what you intended?&lt;BR /&gt;Also, are you taking care to disable transformations such as i/3d0 =&amp;gt; i* .33333333333333333d0, if you don't intend them to happen in one or the other case (-prec-div vs. -noprec-div) ?&lt;BR /&gt;As pointed out in the other forum where you showed this example, your parallel code doesn't solve a set problem, as the serial code does. The serial code updates each value in the array at each j iteration from the result of the previous j iteration. The parallelized code gives each thread a subset of the values of j to implement, with an indeterminate number of updates from other threads writing into the shared array at indeterminate points during the computation (race condition).&lt;BR /&gt;Even though the parallel version skips steps taken in the serial version (possibly at compile time), it probably takes longer. So, you wouldn't do an experiment like this as a way of either speeding up or attempting to replicate the serial result.&lt;BR /&gt;</description>
      <pubDate>Mon, 06 Sep 2010 18:48:01 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828850#M51383</guid>
      <dc:creator>TimP</dc:creator>
      <dc:date>2010-09-06T18:48:01Z</dc:date>
    </item>
    <item>
      <title>OpenMp turncation error</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828851#M51384</link>
      <description>&lt;BR /&gt;Hi Tim,&lt;BR /&gt;&lt;BR /&gt;Thank you very much for your reply. As both you guys said, It is a date race condition. I could correct the error in my original program, the one Im converting to parallel. &lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 07 Sep 2010 12:53:18 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828851#M51384</guid>
      <dc:creator>chat1983</dc:creator>
      <dc:date>2010-09-07T12:53:18Z</dc:date>
    </item>
    <item>
      <title>OpenMp turncation error</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828852#M51385</link>
      <description>This is not a data race condition. The result printout indicates a single bit difference in the least significant bit of the result. I suggest you consult the archetecture manual to see what influences rounding behavior, in particular, how is rounding of 0.5 of the mantissa is handled.&lt;BR /&gt;&lt;BR /&gt; always round up&lt;BR /&gt; always round down&lt;BR /&gt; alternately round up/down&lt;BR /&gt;pseudo randomly round up/down&lt;BR /&gt;&lt;BR /&gt;When either of the last two methods are employed, then by varying the thread count (slice points) it is possible to generate different rounding results.&lt;BR /&gt;&lt;BR /&gt;Jim Dempsey&lt;BR /&gt;</description>
      <pubDate>Tue, 07 Sep 2010 13:08:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828852#M51385</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2010-09-07T13:08:22Z</dc:date>
    </item>
    <item>
      <title>OpenMp turncation error</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828853#M51386</link>
      <description>&lt;P&gt;Please also see&lt;A href="http://software.intel.com/en-us/articles/consistency-of-floating-point-results-using-the-intel-compiler/"&gt; the article &lt;/A&gt;on obtaining floating point consistency with our compiler.&lt;/P&gt;&lt;P&gt;------&lt;/P&gt;&lt;P&gt;Wendy&lt;/P&gt;&lt;P&gt;&lt;A href="http://software.intel.com/en-us/forums/intel-visual-fortran-compiler-for-windows/announcement/241/"&gt;Attaching or including files in a post&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Sep 2010 16:56:02 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/OpenMp-turncation-error/m-p/828853#M51386</guid>
      <dc:creator>Wendy_Doerner__Intel</dc:creator>
      <dc:date>2010-09-07T16:56:02Z</dc:date>
    </item>
  </channel>
</rss>

