Hi,

I have found that calling math functions like log and exp on elements of an 
array of type double[] is slower for the vectorized case than 
non-vectorized case. 

foreach(i=0..N) {
    a[i] = log(b[i]);
}

is slower for various array sizes than 

for(uniform int i = 0; i < N; i++) {
    a[i] = log(b[i]);
}

For floats, the vectorized version is faster as expected. 

I have gone through the previous threads with similar issues and the 2 
suggestions that stood out :
1) Changing the target to try different vector width
2) Linking against Intel's SVML math library

I tried both the suggestions without much success. 

What is the recommended approach to get good double precision performance 
in ISPC?

Thanks,
Pankaj

-- 
You received this message because you are subscribed to the Google Groups 
"Intel SPMD Program Compiler Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to