<?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 If you allocate a shared in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982702#M100117</link>
    <description>&lt;P&gt;If you allocate a shared&amp;nbsp;array of filament, your references are going to be:&lt;/P&gt;
&lt;P&gt;iThread = omp_get_thread_num()&lt;BR /&gt;...&lt;BR /&gt;fil_tmp(iThread)%x_spline%x(i) = fil_tmp(iThread)%x_spline%x(i) + dX&lt;/P&gt;
&lt;P&gt;When using the pointer, (or DUMMY with reference):&lt;/P&gt;
&lt;P&gt;myFilament%x_spline%x(i) = myFilament%x_spline%x(i) + dX&lt;/P&gt;
&lt;P&gt;You remove one array index operation. The compiler may remove this automatically assuming availability of registers (low complexity of code).&lt;/P&gt;
&lt;P&gt;If you are "pointer adverse", then consider encapsulating the body of the code and calling with reference to array element&lt;/P&gt;
&lt;P&gt;call doWork(fil_tmp(iThread), other, args, here)&lt;BR /&gt;...&lt;BR /&gt;subroutine doWork(myFilament, other, args, here)&lt;BR /&gt;type(filament) :: myFilament&lt;BR /&gt;...&lt;/P&gt;
&lt;P&gt;If you want, you can use a contains subroutine.&lt;/P&gt;
&lt;P&gt;I am not "pointer adversed". The efforts to hide the pointer is more work.&lt;/P&gt;
&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
    <pubDate>Mon, 26 Aug 2013 19:05:13 GMT</pubDate>
    <dc:creator>jimdempseyatthecove</dc:creator>
    <dc:date>2013-08-26T19:05:13Z</dc:date>
    <item>
      <title>-openmp -O1 bug with 13.1.3.192</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982689#M100104</link>
      <description>&lt;P&gt;The following code:&lt;/P&gt;
&lt;P&gt;[fortran]module parallel_mod&lt;BR /&gt;&lt;BR /&gt;type interpol_spline&lt;BR /&gt;&amp;nbsp; real(kind=8), allocatable&amp;nbsp;&amp;nbsp; ::&amp;nbsp; x(:), y(:), dy(:), ddy(:) &lt;BR /&gt;&amp;nbsp; real(kind=8), allocatable&amp;nbsp;&amp;nbsp; ::&amp;nbsp; w(:,:) &amp;nbsp;&lt;BR /&gt;end type interpol_spline&lt;BR /&gt;&lt;BR /&gt;type filament&lt;BR /&gt;&amp;nbsp; type(interpol_spline)&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ::&amp;nbsp; x_spline&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;&amp;nbsp; type(interpol_spline)&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ::&amp;nbsp; y_spline&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;&amp;nbsp; type(interpol_spline)&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ::&amp;nbsp; z_spline&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;&amp;nbsp; type(interpol_spline)&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ::&amp;nbsp; s_spline&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&lt;BR /&gt;end type&lt;BR /&gt;&lt;BR /&gt;contains&lt;BR /&gt;&lt;BR /&gt;subroutine parallel_test_two()&lt;BR /&gt;&amp;nbsp; implicit none&lt;BR /&gt;&amp;nbsp; type(filament)&amp;nbsp; :: fil_tmp&lt;BR /&gt;&amp;nbsp; !$omp parallel private(fil_tmp)&lt;BR /&gt;&amp;nbsp; !$omp end parallel&lt;BR /&gt;end subroutine&lt;BR /&gt;&lt;BR /&gt;end module parallel_mod&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;program omp_test&lt;BR /&gt;&amp;nbsp; use parallel_mod&lt;BR /&gt;&amp;nbsp; implicit none&lt;BR /&gt;&amp;nbsp; print *, 'about to test omp'&lt;BR /&gt;&amp;nbsp; call parallel_test_two()&lt;BR /&gt;&amp;nbsp; print *, 'all done'&lt;BR /&gt;end program omp_test[/fortran]&lt;/P&gt;
&lt;P&gt;When compiled like this:&lt;/P&gt;
&lt;P&gt;[bash]ifort -O1&amp;nbsp; -openmp&amp;nbsp; omp_test.f90[/bash]&lt;/P&gt;
&lt;P&gt;Outputs this at runtime:&lt;/P&gt;
&lt;P&gt;[plain] about to test omp&lt;BR /&gt;Segmentation fault[/plain]&lt;/P&gt;
&lt;P&gt;My ifort version information:&lt;/P&gt;
&lt;P&gt;[plain]Intel(R) Fortran Intel(R) 64 Compiler XE for applications running on Intel(R) 64, Version 13.1.3.192 Build 20130607[/plain]&lt;/P&gt;
&lt;P&gt;I assume this is an optimizer/OpenMP bug. But I can't find a workaround - any help/suggestions would be great.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2013 17:44:14 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982689#M100104</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-23T17:44:14Z</dc:date>
    </item>
    <item>
      <title>I am unable to reproduce this</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982690#M100105</link>
      <description>&lt;P&gt;I am unable to reproduce this reesult using the same compiler version and the same compile flags on linux. &amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2013 20:30:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982690#M100105</guid>
      <dc:creator>Casey</dc:creator>
      <dc:date>2013-08-23T20:30:39Z</dc:date>
    </item>
    <item>
      <title>I can reproduce it but am not</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982691#M100106</link>
      <description>&lt;P&gt;I can reproduce it but am not familiar enough with OpenMP to know whether or not this should work. My guess is that it should. I think the issue has to do with the unallocated allocatable components and the private clause.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2013 20:38:17 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982691#M100106</guid>
      <dc:creator>Steven_L_Intel1</dc:creator>
      <dc:date>2013-08-23T20:38:17Z</dc:date>
    </item>
    <item>
      <title>Hi Steve,</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982692#M100107</link>
      <description>&lt;P&gt;Hi Steve,&lt;/P&gt;
&lt;P&gt;If you manage to come up with a workaround that would be great.&lt;/P&gt;
&lt;P&gt;With private, I always do all the allocation once in the parallel section. The behaviour is not well defined otherwise. I'm pretty sure my reproducer should work. In fact, just changing slightly the make up of the derived types makes it work so it really smells like a bug.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Steve Lionel (Intel) wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;
&lt;P&gt;I can reproduce it but am not familiar enough with OpenMP to know whether or not this should work. My guess is that it should. I think the issue has to do with the unallocated allocatable components and the private clause.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2013 20:42:57 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982692#M100107</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-23T20:42:57Z</dc:date>
    </item>
    <item>
      <title>In case it's of interest to</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982693#M100108</link>
      <description>&lt;P&gt;In case it's of interest to anyone, it may be useful to know more about OP's environment.&amp;nbsp; When I attempted it according to the OP's instructions on 64-bit linux, it died with no segfault, but adding -g -traceback to the build options could produce a segfault.&lt;/P&gt;
&lt;P&gt;We have been seeing a great deal of difficulty with allocatable and automatic arrays under -openmp (-O1 and up) with 12.0 through 14.0 compilers, even without involving derived type.&amp;nbsp; Some of the troublesome cases actually worked with (only) this version of the compiler.&lt;/P&gt;</description>
      <pubDate>Fri, 23 Aug 2013 21:28:31 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982693#M100108</guid>
      <dc:creator>TimP</dc:creator>
      <dc:date>2013-08-23T21:28:31Z</dc:date>
    </item>
    <item>
      <title>Tim,</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982694#M100109</link>
      <description>&lt;P&gt;Tim,&lt;/P&gt;
&lt;P&gt;Let me know what you'd like to know about the environment. Here are a few things to get started:&lt;/P&gt;
&lt;P&gt;[plain]$ cat /etc/redhat-release &lt;BR /&gt;Fedora release 18 (Spherical Cow)&lt;BR /&gt;$ head /proc/cpuinfo &lt;BR /&gt;processor : 0&lt;BR /&gt;vendor_id : GenuineIntel&lt;BR /&gt;cpu family : 6&lt;BR /&gt;model : 45&lt;BR /&gt;model name : Intel(R) Xeon(R) CPU E5-2687W 0 @ 3.10GHz&lt;BR /&gt;stepping : 7&lt;BR /&gt;microcode : 0x70d&lt;BR /&gt;cpu MHz : 3100.000&lt;BR /&gt;cache size : 20480 KB&lt;BR /&gt;physical id : 0[/plain]&lt;/P&gt;
&lt;P&gt;On this system, there is still a segfault with flags -g -traceback -O1 -openmp&lt;/P&gt;
&lt;P&gt;Do let me know what other information I may be able to provide to help with this. It would be great to have rock-solid OpenMP support.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 24 Aug 2013 00:58:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982694#M100109</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-24T00:58:00Z</dc:date>
    </item>
    <item>
      <title>As a work around, try:</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982695#M100110</link>
      <description>&lt;P&gt;As a work around, try:&lt;/P&gt;
&lt;P&gt;[fortran]&lt;/P&gt;
&lt;P&gt;subroutine parallel_test_two()&amp;nbsp; &lt;BR /&gt;&amp;nbsp; implicit none &lt;BR /&gt;&amp;nbsp; type(filament), pointer&amp;nbsp; :: fil_tmp =&amp;gt;&amp;nbsp; NULL()&lt;BR /&gt;&amp;nbsp; !$omp parallel private(fil_tmp)&lt;BR /&gt;&amp;nbsp; allocate(fil_temp)&lt;BR /&gt;&amp;nbsp; ! allocate(fil_temp%x_spline%x(nnn))&lt;BR /&gt;&amp;nbsp; ! ...&lt;BR /&gt;&amp;nbsp; ! deallocate(fil_temp%x_spline%x(nnn))&lt;BR /&gt;&amp;nbsp; deallocate(fil_temp)&lt;BR /&gt;&amp;nbsp; nullify(fil_temp)&lt;BR /&gt;&amp;nbsp; !$omp end parallel&amp;nbsp; &lt;BR /&gt;end subroutine&lt;BR /&gt;[/fortran]&lt;/P&gt;
&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Sat, 24 Aug 2013 17:25:50 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982695#M100110</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2013-08-24T17:25:50Z</dc:date>
    </item>
    <item>
      <title>Jim,</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982696#M100111</link>
      <description>&lt;P&gt;Jim,&lt;/P&gt;
&lt;P&gt;Thanks for this very nice tip. Works fine at compile-time and appears to be good at runtime too. &lt;/P&gt;</description>
      <pubDate>Sat, 24 Aug 2013 18:32:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982696#M100111</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-24T18:32:22Z</dc:date>
    </item>
    <item>
      <title>FWIW, the behaviour of the</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982697#M100112</link>
      <description>&lt;P&gt;FWIW, the behaviour of the original example isn't defined by the (current) OpenMP 4.0 spec because of the use of allocatable components.&amp;nbsp; As a result, the OP's program has one foot in choose-your-own-adventure land&amp;nbsp; See the list on page 22 of the OpenMP spec.&amp;nbsp; &lt;/P&gt;</description>
      <pubDate>Sun, 25 Aug 2013 01:47:12 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982697#M100112</guid>
      <dc:creator>IanH</dc:creator>
      <dc:date>2013-08-25T01:47:12Z</dc:date>
    </item>
    <item>
      <title>A. Rohou,</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982698#M100113</link>
      <description>&lt;P&gt;A. Rohou,&lt;/P&gt;
&lt;P&gt;One more helpful hint. Use firstprivate in place of private. This will copy the NULL value of the pointer into the parallel region. While the proffered above code works, other code may not if it depends on/uses ASSOCIATED to test the validity of the pointer.&lt;/P&gt;
&lt;P&gt;There is another old thread relating to this subject.&lt;/P&gt;
&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Sun, 25 Aug 2013 14:28:50 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982698#M100113</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2013-08-25T14:28:50Z</dc:date>
    </item>
    <item>
      <title>Thanks all. Since IanH points</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982699#M100114</link>
      <description>&lt;P&gt;Thanks all. Since IanH points out that what I was expecting is not actually defined by OpenMP 4.0, I think I will do something like this instead:&lt;/P&gt;
&lt;P&gt;[fortran]subroutine parallel_test_two()&lt;BR /&gt;&amp;nbsp; use omp_lib&lt;BR /&gt;&amp;nbsp; implicit none&lt;BR /&gt;&amp;nbsp; type(filament), allocatable&amp;nbsp; :: fil_tmp(:)&lt;BR /&gt;&amp;nbsp; !$omp parallel shared(fil_tmp)&lt;BR /&gt;&amp;nbsp; !$omp single&lt;BR /&gt;&amp;nbsp; allocate(fil_tmp(omp_get_num_threads()))&lt;BR /&gt;&amp;nbsp; !$omp end single&lt;BR /&gt;&amp;nbsp; !(...)&lt;BR /&gt;&amp;nbsp; !$omp barrier&lt;BR /&gt;&amp;nbsp; !$omp single&lt;BR /&gt;&amp;nbsp; deallocate(fil_tmp)&lt;BR /&gt;&amp;nbsp; !$omp end single&lt;BR /&gt;&amp;nbsp; !$omp end parallel&lt;BR /&gt;end subroutinee[/fortran]&lt;/P&gt;
&lt;P&gt;I hope that this will be more likely to work, since I'm not expecting the complier to handle any implicit memory allocation of derived types with allocatable components anymore.&lt;/P&gt;
&lt;P&gt;[Edit: added barrier before single]&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2013 12:44:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982699#M100114</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-26T12:44:00Z</dc:date>
    </item>
    <item>
      <title>You might want to see if</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982700#M100115</link>
      <description>&lt;P&gt;You might want to see if using:&lt;/P&gt;
&lt;P&gt;... fil_tmp(myThreadNumber)%... ...&amp;nbsp;&lt;/P&gt;
&lt;P&gt;adds excessive overhead.&lt;/P&gt;
&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2013 15:56:58 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982700#M100115</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2013-08-26T15:56:58Z</dc:date>
    </item>
    <item>
      <title>Quote:jimdempseyatthecove</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982701#M100116</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;jimdempseyatthecove wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;
&lt;P&gt;You might want to see if using:&lt;/P&gt;
&lt;P&gt;... fil_tmp(myThreadNumber)%... ...&amp;nbsp;&lt;/P&gt;
&lt;P&gt;adds excessive overhead.&lt;/P&gt;
&lt;P&gt;Jim Dempsey&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Jim,&lt;/P&gt;
&lt;P&gt;I'm not sure I know exactly what you mean. In terms of memory, I would have expected this latest workaround to be ~ equivalent to using PRIVATE since there's only one additional array descriptor (fil_tmp(:)), but I don't really understand these things well enough to be sure that's true. On the other hand, perhaps you mean some kind of computing overhead?&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2013 16:05:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982701#M100116</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-26T16:05:34Z</dc:date>
    </item>
    <item>
      <title>If you allocate a shared</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982702#M100117</link>
      <description>&lt;P&gt;If you allocate a shared&amp;nbsp;array of filament, your references are going to be:&lt;/P&gt;
&lt;P&gt;iThread = omp_get_thread_num()&lt;BR /&gt;...&lt;BR /&gt;fil_tmp(iThread)%x_spline%x(i) = fil_tmp(iThread)%x_spline%x(i) + dX&lt;/P&gt;
&lt;P&gt;When using the pointer, (or DUMMY with reference):&lt;/P&gt;
&lt;P&gt;myFilament%x_spline%x(i) = myFilament%x_spline%x(i) + dX&lt;/P&gt;
&lt;P&gt;You remove one array index operation. The compiler may remove this automatically assuming availability of registers (low complexity of code).&lt;/P&gt;
&lt;P&gt;If you are "pointer adverse", then consider encapsulating the body of the code and calling with reference to array element&lt;/P&gt;
&lt;P&gt;call doWork(fil_tmp(iThread), other, args, here)&lt;BR /&gt;...&lt;BR /&gt;subroutine doWork(myFilament, other, args, here)&lt;BR /&gt;type(filament) :: myFilament&lt;BR /&gt;...&lt;/P&gt;
&lt;P&gt;If you want, you can use a contains subroutine.&lt;/P&gt;
&lt;P&gt;I am not "pointer adversed". The efforts to hide the pointer is more work.&lt;/P&gt;
&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2013 19:05:13 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982702#M100117</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2013-08-26T19:05:13Z</dc:date>
    </item>
    <item>
      <title>Thanks Jim, I know what you</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982703#M100118</link>
      <description>&lt;P&gt;Thanks Jim, I know what you mean now. It turns out my code is already "encapsulated" the way you described with &lt;/P&gt;&lt;BLOCKQUOTE&gt;call doWork(fil_tmp(iThread), other, args, here)&lt;/BLOCKQUOTE&gt;. So in my case, there's no or not much coding overhead.&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Aug 2013 19:12:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/openmp-O1-bug-with-13-1-3-192/m-p/982703#M100118</guid>
      <dc:creator>Alexis_R_</dc:creator>
      <dc:date>2013-08-26T19:12:07Z</dc:date>
    </item>
  </channel>
</rss>

