Topic: OpenMP4.0

I want to use function of OpenMP 4.0.
Should I need to include some files, or set environment variables?

2 (edited by davidb 2014-09-04 08:11:06)

Re: OpenMP4.0

You need to specify the -fopenmp flag when you invoke the compiler and the linker.

There is a checkbox for the compiler on the Fortran tab of Project Options. This correctly sets the flag for compiling and linking.

You can set the environment variable OMP_NUM_THREADS to control the maximum number of threads the program should use. If you don't set this, the maximum number of threads will equal the number of processor cores.

Note that, at this time, only a sub-set of the additional features in OpenMP 4 are supported.

--
David

Re: OpenMP4.0

David is mostly correct.  As of Simply Fortran 2.15, the compiler should have full support for the OpenMP 4 standard.  Please see the compiler release notes.  But other than that, David is right.  Just make sure to select "Enable OpenMP" under the Fortran tab in Project Options.

Jeff Armstrong
Approximatrix, LLC