These user-defined function(s) are not vectorized or inlined by the compiler: %function_names% To fix: Do one of the following:
- Enforce vectorization of the source loop by means of SIMD instructions and/or create a SIMD version of the function(s) using a directive:
| Target | Directive |
|---|
| Source loop | #pragma omp simd |
| Inner function definition or declaration | #pragma omp declare simd |
- If using the Ob or inline-level compiler option to control inline expansion with the 1 argument, use an inline keyword to enable inlining or replace the 1 argument with 2 to enable inlining of any function at compiler discretion.
Example
#pragma omp declare simd
int f (int x)
{
return x+1;
}
...
#pragma omp declare simd
int f (int x)
{
return x+1;
}
#pragma omp simd
for (int k = 0; k < N; k++)
{
a[k] = f(k);
}
Read More