cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

nibal
Challenger

Sample FFT_Kernels.cl in SDK 2.9-1 opencl/cpp_cl/FFT is broken

void FFT::Init(__global float *real,__global float *imag,__local float *Localds)
{
     gr = real;

     gi = imag;
     lds = Localds;
     gid = get_global_id(0);
      me = gid & 0x3fU;
      dg = (gid >> 6) * VSTRIDE;
      gr += dg;
      gi += dg;
}

In the host program globalThreads[0] = 64. Therefore, dg (the mp step) is always 0. As a result, it runs the full 64x1024 FFT each time, overwriting previous results. I am sure this is not intentional. Plz fix.

0 Likes
1 Solution
nibal
Challenger

Actually, it is not broken. It mps with another step, me. Works fine. Regardless, dg is leftover code, not used, that is misleading and should be removed.

View solution in original post

0 Likes
1 Reply
nibal
Challenger

Actually, it is not broken. It mps with another step, me. Works fine. Regardless, dg is leftover code, not used, that is misleading and should be removed.

0 Likes