<?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 Re: Memory leak of allocatable arrays inside OpenMP sections in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727798#M177740</link>
    <description>&lt;P&gt;The issue may relate to the definition of "finalizable type".&lt;/P&gt;&lt;P&gt;While a User Defined Type can have a final procedure(s), it is not clear that an allocatable array (descriptor) has a final procedure.&lt;/P&gt;&lt;P&gt;This is Fortran, an array descriptor is not necessarily the same as a C++ container.&lt;/P&gt;&lt;P&gt;As to if the underlying construct is a C++ container, or not, this may be a vendor specific implementation choice.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It would be nice if Steve could comment on this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
    <pubDate>Tue, 25 Nov 2025 17:02:39 GMT</pubDate>
    <dc:creator>jimdempseyatthecove</dc:creator>
    <dc:date>2025-11-25T17:02:39Z</dc:date>
    <item>
      <title>Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727430#M177720</link>
      <description>&lt;P&gt;&lt;BR /&gt;Hello! The following simple example of allocation of temporary blocks inside of OpenMP sections has a memory leaks since array `a` is not deallocated at the end of scope, as it usually happens in Fortran. gfortran does not have memory leak here.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="fortran"&gt;subroutine test(n, q, v)
  integer :: n
  real :: q(n, n), v(n, n, n)
  real, allocatable :: a(:, :)
  !$omp parallel default(none) &amp;amp;
  !$omp private(a) &amp;amp;
  !$omp shared(n, q, v)
  allocate(a(n, n))

  !$omp do
  do i = 1, n
    a = a + v(:, :, i)
  end do
  !$omp end do nowait

  !$omp critical (sum_q)
  q = q + a
  !$omp end critical (sum_q)

  !$omp end parallel
end subroutine test

program main
  integer, parameter :: n = 1000
  real, allocatable :: q(:, :), v(:, :, :)
  integer :: i
  allocate(q(n, n), v(n, n, n))
  q = 0.0
  call random_number(q)
  do i = 1, n
    call test(n, q, v)
  end do
  print *, sum(q)
end program main&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;Tested ifx: 2025.2.0&lt;BR /&gt;&lt;BR /&gt;Compilation flags: ifx -fopenmp alloc.f90 -O3&lt;BR /&gt;&lt;BR /&gt;gfortran solves this task in 8 threads in approximately 40 seconds.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 23 Nov 2025 13:56:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727430#M177720</guid>
      <dc:creator>foxtran</dc:creator>
      <dc:date>2025-11-23T13:56:22Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727615#M177730</link>
      <description>&lt;P&gt;I don't see any openMP sections, only openMP parallel do.&lt;/P&gt;&lt;P&gt;I tested in IFX 2025.3.1 on Windows and got no obvious increases in memory during progress.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 Nov 2025 15:58:52 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727615#M177730</guid>
      <dc:creator>Andrew_Smith</dc:creator>
      <dc:date>2025-11-24T15:58:52Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727616#M177731</link>
      <description>&lt;P&gt;I think you need to explicitly deallocate a before the end of the parallel region.&amp;nbsp; &amp;nbsp;This is still leaking in IFX 2025.3, otherwise&lt;/P&gt;</description>
      <pubDate>Mon, 24 Nov 2025 16:28:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727616#M177731</guid>
      <dc:creator>Mark_Lewy</dc:creator>
      <dc:date>2025-11-24T16:28:45Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727631#M177733</link>
      <description>&lt;P&gt;I believe&amp;nbsp;&lt;a href="https://community.intel.com/t5/user/viewprofilepage/user-id/86988"&gt;@Mark_Lewy&lt;/a&gt;&amp;nbsp;is correct, though Steve could comment on this.&lt;/P&gt;&lt;P&gt;I believe the auto deallocation (when realloc lhs is in effect) is required to be performed at &lt;EM&gt;procedure exit&lt;/EM&gt;.&lt;/P&gt;&lt;P&gt;At the point of procedure exit, only the main thread is running, thus only its allocation is required to be deallocated.&lt;/P&gt;&lt;P&gt;gfortran performing the deallocation (for non-master threads) when exiting a parallel region may be a non-standard feature.&lt;/P&gt;&lt;P&gt;Do not rely on non-standard (vendor specific) behavior.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Mon, 24 Nov 2025 18:08:10 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727631#M177733</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2025-11-24T18:08:10Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727652#M177734</link>
      <description>&lt;P&gt;I suppose procedure exit is at !$omp end parallel. At least as I understand how OMP sections are produced in binary.&lt;BR /&gt;&lt;BR /&gt;I've checked other compilers:&lt;BR /&gt;nvfortran 23.11&lt;BR /&gt;sun fortran compiler 12.6&lt;BR /&gt;Cray Fortran 18&lt;BR /&gt;&lt;BR /&gt;All of these compilers do deallocation at the end of scope in all threads.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Nov 2025 21:00:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727652#M177734</guid>
      <dc:creator>foxtran</dc:creator>
      <dc:date>2025-11-24T21:00:16Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727653#M177735</link>
      <description>&lt;P&gt;Yep, I have to do deallocation, but I would be much better to be consistent with other Fortran implementations. I am still not sure is it a problem with Intel compilers or other compilers are too clever...&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Considering rewriting this code in C++:&lt;/P&gt;&lt;LI-CODE lang="cpp"&gt;#pragma omp parallel
{
  std::vector v{100};
  …
  // Fortran/C++ RAII kills v
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;So, all threads should deallocate v at the end of scope. The same should happen with Fortran too.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Nov 2025 21:12:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727653#M177735</guid>
      <dc:creator>foxtran</dc:creator>
      <dc:date>2025-11-24T21:12:45Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727661#M177736</link>
      <description>&lt;P&gt;This is because std:vector has a dtor&lt;/P&gt;&lt;LI-CODE lang="cpp"&gt;#pragma omp parallel
{
float* array = (float*)malloc(1234);
...
}&lt;/LI-CODE&gt;&lt;P&gt;Would have a memory leak if you don't include the free.&lt;/P&gt;&lt;P&gt;In reading &lt;A href="https://www.intel.com/content/www/us/en/docs/fortran-compiler/developer-guide-reference/2025-2/deallocation-of-allocatable-variables.html" target="_self"&gt;this&lt;/A&gt; section, there is no mention of exiting a parallel region.&lt;/P&gt;&lt;P&gt;I couldn't locate a Fortran section in the OpenMP reference addressing this subject.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Mon, 24 Nov 2025 22:01:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727661#M177736</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2025-11-24T22:01:16Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727672#M177737</link>
      <description>&lt;P&gt;That is what is see in OpenMP 5.2:&lt;BR /&gt;&lt;BR /&gt;&amp;gt; Finalization of a list item of a finalizable type or subobjects of a list item of a finalizable type occurs at the end of the region.&lt;BR /&gt;&lt;BR /&gt;at&amp;nbsp;&lt;SPAN&gt;CHAPTER 5. DATA ENVIRONMENT;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;5.3 List Item Privatization;&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;p 107, lines 20-22.&lt;/SPAN&gt;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;&lt;BR /&gt;So, allocatable arrays should be finalized at the end of region.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;OpenMP 3.0 does specify behaviour in the other words:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;&lt;SPAN&gt;&amp;gt; The value and/or allocation status of the original list item will change only:&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt; &amp;nbsp;- if accessed and modified via pointer,&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt; &amp;nbsp;- if (possibly) accessed in the region but outside of the construct, or&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN&gt;&amp;gt; &amp;nbsp;- as a side effect of directives or clauses.&lt;BR /&gt;&lt;BR /&gt;at&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;Chapter 2. Directives; &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;2.9.3.3 private clause, p 90, lines 4-7.&lt;BR /&gt;&lt;BR /&gt;Actually, for main thread, there is deallocation for ifx 2025.2.0, but not for other threads.&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 25 Nov 2025 00:17:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727672#M177737</guid>
      <dc:creator>foxtran</dc:creator>
      <dc:date>2025-11-25T00:17:26Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727798#M177740</link>
      <description>&lt;P&gt;The issue may relate to the definition of "finalizable type".&lt;/P&gt;&lt;P&gt;While a User Defined Type can have a final procedure(s), it is not clear that an allocatable array (descriptor) has a final procedure.&lt;/P&gt;&lt;P&gt;This is Fortran, an array descriptor is not necessarily the same as a C++ container.&lt;/P&gt;&lt;P&gt;As to if the underlying construct is a C++ container, or not, this may be a vendor specific implementation choice.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It would be nice if Steve could comment on this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Tue, 25 Nov 2025 17:02:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727798#M177740</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2025-11-25T17:02:39Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727981#M177750</link>
      <description>&lt;P&gt;&lt;a href="https://community.intel.com/t5/user/viewprofilepage/user-id/41896"&gt;@Igor_V_Intel&lt;/a&gt;&amp;nbsp;, what do you think about this bug (or maybe it is not a bug)? Could you please have a look?&lt;/P&gt;</description>
      <pubDate>Wed, 26 Nov 2025 21:23:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1727981#M177750</guid>
      <dc:creator>foxtran</dc:creator>
      <dc:date>2025-11-26T21:23:06Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728268#M177761</link>
      <description>&lt;P&gt;There is definitely a leak of memory, as seen on Linux using 'top' to watch in a 2nd window.&amp;nbsp; This is interesting also, in that ifx and ifort are using stack for the allocation whereas gfortran is probably using heap.&amp;nbsp; Using the option -heap-arrays you will find ifx runs as fast a gfortran.&amp;nbsp; Without that option, ifx seems quite slow by comparision.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So the question is whether this is legal OMP or not.&amp;nbsp; For sure your syntax sets each thread with a private version of the array descriptor for 'a'.&amp;nbsp; but the allocation is done per thread.&amp;nbsp; So at the end of the OMP parallel region is it the programmer's responsibility to release the allocation or should Fortran scoping rules apply.&amp;nbsp; Good question.&amp;nbsp; If this were C, it would be illegal without a free() I would think.&amp;nbsp; So why would the OMP rules for Fortran differ?&amp;nbsp; Don't know.&amp;nbsp; My expectation is like yours - I would expect Fortran to free the allocation on each thread at the end of the region.&amp;nbsp; Expect does not mean compliant to Standards.&amp;nbsp;&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;I'll write up a bug report and we'll have a discussion internally as to the legality of this example.&amp;nbsp; This is a good example, thank you for sending this in.&lt;BR /&gt;&lt;BR /&gt;BTW - ifort gives the same behavior so it's something in our Fortran front-end I think.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ron&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 16:45:44 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728268#M177761</guid>
      <dc:creator>Ron_Green</dc:creator>
      <dc:date>2025-11-28T16:45:44Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728270#M177762</link>
      <description>&lt;P&gt;&amp;nbsp;bug ID is CMPLRLLVM-71966&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 17:14:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728270#M177762</guid>
      <dc:creator>Ron_Green</dc:creator>
      <dc:date>2025-11-28T17:14:06Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728277#M177766</link>
      <description>&lt;P&gt;In principle, I agree with Jim here. OpenMP only defines when the scope of a private variable begins and ends.&lt;BR /&gt;The compiler decides when storage for the private copy is created and destroyed.&amp;nbsp;OpenMP does not constrain the implementation’s handling of Fortran allocatables and&amp;nbsp;Fortran requires deallocation only at procedure exit (by main thread). So, it appears to be a standard-conforming behavior of the compiler. However, I agree with you and Ron that it is not what the user may expect. The fact that other compiler implementations deallocate the memory shows that we should discuss this topic and consider aligning it.&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 18:21:08 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728277#M177766</guid>
      <dc:creator>Igor_V_Intel</dc:creator>
      <dc:date>2025-11-28T18:21:08Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728293#M177772</link>
      <description>&lt;P&gt;This is something that the standards committee has to address (OpenMP standard, assuming it is not addressed already).&lt;/P&gt;&lt;P&gt;You can also address this with the following (assuming you wish for automatic deallocation (untested code).&lt;/P&gt;&lt;LI-CODE lang="fortran"&gt;subroutine test(n, q, v)
  integer :: n
  real :: q(n, n), v(n, n, n)
  !$omp parallel default(none) &amp;amp;
  !$omp shared(n, q, v)
  !$omp do
  block
  real, allocatable :: a(:, :)
  allocate(a(n, n))
  do i = 1, n
    a = a + v(:, :, i)
  end do
  !$omp end do nowait

  !$omp critical (sum_q)
  q = q + a
  !$omp end critical (sum_q)
  end block
  !$omp end parallel
end subroutine test&lt;/LI-CODE&gt;&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Fri, 28 Nov 2025 21:28:58 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728293#M177772</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2025-11-28T21:28:58Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728374#M177785</link>
      <description>&lt;P&gt;&amp;gt;&amp;nbsp;&lt;SPAN&gt;requires deallocation only at procedure exit&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;As I can understand, OMP generates a new procedure for each OMP region (at least that is one of possible ways to implement OpenMP pragmas), so, technically, at the end of parallel region there is an exit from procedure, so deallocate should happen in all threads.&lt;/P&gt;</description>
      <pubDate>Sat, 29 Nov 2025 20:49:51 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728374#M177785</guid>
      <dc:creator>foxtran</dc:creator>
      <dc:date>2025-11-29T20:49:51Z</dc:date>
    </item>
    <item>
      <title>Re: Memory leak of allocatable arrays inside OpenMP sections</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728415#M177793</link>
      <description>&lt;P&gt;&amp;gt;&amp;gt;&lt;EM&gt;As I can understand, OMP generates a new procedure for each OMP region...&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Do you have anything to substantiate this?&lt;/SPAN&gt;&lt;/P&gt;&lt;LI-CODE lang="fortran"&gt;subroutine foo(array)
real :: array(:)
integer :: i
do i=1,size(array)
   ...
end do
end subroutine foo&lt;/LI-CODE&gt;&lt;P&gt;The procedure is foo&lt;/P&gt;&lt;LI-CODE lang="fortran"&gt;subroutine foo(array)
real :: array(:)
integer :: i
!$omp parallel do
do i=1,size(array)
   ...
end do
!$omp end parallel do
end subroutine foo&lt;/LI-CODE&gt;&lt;P&gt;the procedure is foo, and by definition, it contains a parallel region.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Jim Dempsey&lt;/P&gt;</description>
      <pubDate>Sun, 30 Nov 2025 18:36:41 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Memory-leak-of-allocatable-arrays-inside-OpenMP-sections/m-p/1728415#M177793</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2025-11-30T18:36:41Z</dc:date>
    </item>
  </channel>
</rss>

