How to know the openmp version?

General OpenMP discussion

How to know the openmp version?

Postby lamoincyloj » Sun Aug 24, 2008 2:57 am

Hello OpenMP users

I want to know the command that allow me to know the OpenMP version supported by my gcc compiler.
My configuration: Fedora 9.
and I want to know what I have to do in order to emigrate to the 3.0 version.
there are anyone who can answer me, I need your help.
thank you.

Re: How to know the openmp version?

Postby rchrd » Sun Aug 24, 2008 6:50 pm

OpenMP must be implemented by the compiler you are using. It is not something that you can import separately into your environment.

Version 3.0 of the OpenMP spec is still new and not all compiler suppliers on Linux have released their compilers with it fully implemented.

Check the current status of the latest GCC compiler at It does appear that an implementation of OpenMP 3.0 has been made for the GCC compiler, but it is not clear if that implementation is available today in a downloadable release.

I don't know if there is a release available today of the Intel compilers that implement all or part of the 3.0 spec. Perhaps someone from Intel could shed some light here.

There is a "beta" release of the Sun Studio compilers on Linux, part of the Sun Studio Express program, with most of the 3.0 features implemented. Check the Sun OpenMP Wiki page for information about the latest Sun Studio Express release on Linux. Check the Sun Studio Express Readme page, at ... 08+Release to see if the platform you are using is supported by this Express release. Download from

Perhaps it's time to roundup the latest information on 3.0 features availability in compilers and put this information up on the website... a project for next week.
Richard Friedman rchrd -at- rchrd -dot- com webmaster
Posts: 59
Joined: Tue Apr 01, 2008 10:35 pm
Location: Oakland, California

Re: How to know the openmp version?

Postby mwolfe » Mon Aug 25, 2008 3:34 pm

If you enable the OpenMP features in your compiler, the preprocessor variable _OPENMP should give the OpenMP version. It is encoded as yyyymm, the year and month of the standard. The 2.5 standard will have the value 200505 (May 2005, the month the OpenMP 2.5 standard was approved). The 3.0 standard will be 200805

Return to Using OpenMP

Who is online

Users browsing this forum: No registered users and 4 guests