I am getting a strange compiler error. The code is very simple inside my kernel function:
int MW_BLOCK_SIZE = 15; __shared__ unsigned char Is[MW_BLOCK_SIZE * MW_BLOCK_SIZE * 3]; //Image in the shared memory
line 43: internal error: assertion failed: add_dyn_init_cleanup: missing destructible entity descr (lower_init.c, line 4799) __attribute__((__shared__)) unsigned char Is[MW_BLOCK_SIZE * MW_BLOCK_SIZE * 3]; //Image in the shared memory ^ 1 catastrophic error detected in the compilation of "/tmp/tmp_00003033-3.ii". Compilation aborted.
However if I write the value of MW_BLOCK_SIZE, 15, inside the brackets, it doesn’t complain.
One final question: Is the shared memory Is, big enough? I think 15153 = 675 should be fine. I just want to make sure. Thanks in advance.