You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When targeting OpenMP with Devito, we're seeing compilation-time warnings on some older systems: ignoring #pragma omp simd
This is expected behavior when compiling with an OpenMP version < 4.0, as #pragma omp simd was only introduced in OpenMP 4.0 (released July 2013). In particular, the macro _OPENMP is not sufficient for this use case unless its value is ≥ 201307.
Option 1:
We should add a check in the Devito compiler pipeline to conditionally emit #pragma omp simd only if _OPENMP >= 201307.
Option 2:
We update the writing out pragma omp simd to include preprocessor guards in the generated code, e.g.:
The disadvantage is that this will reduce the readability of the generated code.
Option 3: Alternative considered: Adding -Wno-unknown-pragmas to the compiler flags to silence the warning. However, this is fragile and may suppress legitimate warnings from other unintended or misspelled pragmas.
The text was updated successfully, but these errors were encountered:
Description:
When targeting OpenMP with Devito, we're seeing compilation-time warnings on some older systems:
ignoring #pragma omp simd
This is expected behavior when compiling with an OpenMP version < 4.0, as
#pragma omp simd
was only introduced in OpenMP 4.0 (released July 2013). In particular, the macro_OPENMP
is not sufficient for this use case unless its value is ≥ 201307.Option 1:
We should add a check in the Devito compiler pipeline to conditionally emit
#pragma omp simd
only if_OPENMP >= 201307
.Option 2:
We update the writing out pragma omp simd to include preprocessor guards in the generated code, e.g.:
The disadvantage is that this will reduce the readability of the generated code.
Option 3:
Alternative considered: Adding
-Wno-unknown-pragmas
to the compiler flags to silence the warning. However, this is fragile and may suppress legitimate warnings from other unintended or misspelled pragmas.The text was updated successfully, but these errors were encountered: