Forum Discussion
Altera_Forum
Honored Contributor
8 years agoData sharing among various kernels
Hello, I have tried working with read and write channels to pass data from one kernel to other. I wanted to know, whether a global variable can be shared by various kernels to pass the data. I ...
Altera_Forum
Honored Contributor
8 years agoThat is not how you share global buffers. You cannot define global buffers inside the kernel code. They must be defined and allocated in the host code. You can just add one extra global argument to each kernel and after allocating the shared buffer in the host code, pass the pointer to the shared buffer to both kernels.