Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Announcements
Welcome to the Intel Community. If you get an answer you like, please mark it as an Accepted Solution to help others. Thank you!
26755 Discussions

Finalization not performed when within PARALLEL region

Matuszyk__Pawel
Beginner
150 Views

Hello,

I wrote a wrapper on FFT handler and computational subroutines. One of the futures is the deallocation of the FFT descriptor in the final subroutine. It works fine when running in sequential mode; however, the finalization is never called when leaving the PARALLEL region.

So, does not OpenMP support finalization, or I made some mistakes in my code?

Paweł

0 Kudos
4 Replies
Steve_Lionel
Black Belt Retired Employee
150 Views

Which compiler version are you using?

The OpenMP 4.5 spec says:

Finalization of a list item of a finalizable type or subojects of a list item of a finalizable type occurs at the end of the region. The order in which any final subroutines for different variables of a 8 finalizable type are called is unspecified.

so, in theory, it ought to work. I have not tried your example.

Matuszyk__Pawel
Beginner
150 Views

Hi Lionel,

I'm using Intel(R) Visual Fortran Compiler 19.0.5.281, which is pretty new one...

Paweł

Steve_Lionel
Black Belt Retired Employee
150 Views

Try 19.1.1.216.

Matuszyk__Pawel
Beginner
150 Views

Well, unfortunately, I do not have access to the newer version....

 

Paweł

Reply