Raistmer

GPU double arithmetic gives incorrect results

Discussion created by Raistmer on Aug 15, 2009
Latest reply on Aug 17, 2009 by Raistmer
relative to CPU one

On CPU:
period=(double)sub_buffer_size/(double)freq;

On GPU:
kernel void GPU_fetch_array_kernel74t(int sub_buffer_size,float src[],float freq[],out float4 dest<>){
float f=freq[threadID];
double period=(double)sub_buffer_size/(double)f;
where freq[threadID] same frequency as in CPU version.

these periods are different enough to produce incorrect stride in folding.

Any comments about GPU double precision and calculations?

Outcomes