hi,
i have 2 functions on a cuda file. on one i have a call to the other like:
f1(){
…
…
cuMagnitude(srcHost,src,len);
…
}
extern “C” void cuMagnitude(cufftComplex *src, int *dst,int len){
…
…
}
the problem is the srcHost array elements change when cuMagnitude is called …
also, i’m not being able to allocate device arrays with cudaMalloc in cuMagnitude , the pointers stay null :\
anyone can help me please??
i can provide more code if you think it would help…
EDIT:
weird thing: i’m passing a Host array; in cuMagnitude the value of the array is diferent but it is the same as the value on the Device array in the first function, before copying to the host.