Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Employee
38 Views

Using SVML

Jump to solution

Hello,

I am using a single SVML function (___mm256_pow_ps()) among other non-SVML intrinsic functions in my code compiled with icpc. Is the following flag:-fimf-use-svml=true:pow the only one I should be using? I am probably missing something. Is there a different header, in addition to immintrin.h, that should be used? My compilation error is:

error: identifier "__m256_pow_ps" is undefined

Thanks in advance,

Steena

 

 

 

0 Kudos

Accepted Solutions
Highlighted
Black Belt
38 Views

There isn't a documented explicit interface for calling svml functions.  icpc should do it automatically with standard source code such as

#include <cmath>

....

float a[].b,c[];

for(int i=0; i<n; ++i)a = pow(c,b);  // or <math.h> and powf()

The fimf options may be used to control which svml functions are used, but the default is to use all of them.  If the vec-report option tells you it is vectorized, this assures you that an svml call is made.   You can check by nm etc.

View solution in original post

0 Kudos
2 Replies
Highlighted
Black Belt
39 Views

There isn't a documented explicit interface for calling svml functions.  icpc should do it automatically with standard source code such as

#include <cmath>

....

float a[].b,c[];

for(int i=0; i<n; ++i)a = pow(c,b);  // or <math.h> and powf()

The fimf options may be used to control which svml functions are used, but the default is to use all of them.  If the vec-report option tells you it is vectorized, this assures you that an svml call is made.   You can check by nm etc.

View solution in original post

0 Kudos
Highlighted
Employee
38 Views

Tim,

Thanks for that explanation. My mistake was mistyping the instruction---m256_pow_ps instead of _mm256_pow_ps. 

0 Kudos