OpenMP_OPENMP
では、OpenMP モードでコンパイルするときにマクロが定義されています (ほとんどの場合、私が知っているコンパイラ (gcc、pgi、intel など) によって)。OpenACC モード (Cray/pgi/その他のコンパイラ) でコンパイルするときに、同様の「標準」マクロが定義されていますか?
ウィラワン
OpenMP_OPENMP
では、OpenMP モードでコンパイルするときにマクロが定義されています (ほとんどの場合、私が知っているコンパイラ (gcc、pgi、intel など) によって)。OpenACC モード (Cray/pgi/その他のコンパイラ) でコンパイルするときに、同様の「標準」マクロが定義されていますか?
ウィラワン
はい、openacc に対して同様のマクロが定義されています: _OPENACC。
2.2 Conditional Compilation
The _OPENACC macro name is defined to have a value yyyymm where yyyy is the year and
mm is the month designation of the version of the OpenACC directives supported by the
implementation. This macro must be defined by a compiler only when OpenACC directives
are enabled. The version described here is 201306.