Is there a way of setting default value for shared memory array?

Viewed 16949

Consider the following code:

__global__ void kernel(int *something) {
extern __shared__ int shared_array[];     

// Some operations on shared_array here.

}

Is it possible to set whole shared_array to some value - e.g. 0 - without explicitly addressing each cell in some thread?

3 Answers
Related