I am beginner to CUDA and I am trying to allocate shared memory for double data type and pointers to double data types. I am allocating data using
extern __shared__ double dataShared[];
Here at I want pointers to this data at specific places
int v = threadIdx.x;
dataShared[v] = &dataShared[v + (v+1)*data.V];
I want a 2D double data array and 1D pointer array which points to each column of the 2D array in shared memory. Here I am avoiding dynamic allocation of the pointer array due to the performance implications. Here the pointer array is shifted and used to access the columns so that the 2D array would be column shifted as a result.
However this is not allowed and is there any other way I can achieve this. Currently I am working using CUDA 7.5 and it would be better if someone can suggest if there is anything new in CUDA 8.0 to achieve this.
dataShared[v] = &dataShared[...]doesn't make sense, as you're assigning a value of a pointer type to an array element of type double. I seriously doubt there is an issue with CUDA. You may want to try to come up with a solution for plain C first. It would certainly work for CUDA too. In order to get meaningful answers you will need to post more code and/or to explain your intent better. It may also be a XY problem, so you might want to add some more information about the context of the problem you are trying to solve