constant mem fence?
hi folks,

i was just about to finish my first real kernel and then i started having strange difficulties that when i manually unrolled a loop which accessed a constant mem array the code just did not work any more (results were wrong).

it appears to me that there is a problem with accessing the constant mem array and the compiler would automatically take care of at, as long as a loop surrounds it. therefore, i would like to ask, is there sth similar to:

read_mem_fence(CLK_LOCAL_MEM_FENCE);

but affects reading from constant mem?

thanks in advance!

vci
hi folks,



i was just about to finish my first real kernel and then i started having strange difficulties that when i manually unrolled a loop which accessed a constant mem array the code just did not work any more (results were wrong).



it appears to me that there is a problem with accessing the constant mem array and the compiler would automatically take care of at, as long as a loop surrounds it. therefore, i would like to ask, is there sth similar to:



read_mem_fence(CLK_LOCAL_MEM_FENCE);



but affects reading from constant mem?



thanks in advance!



vci

#1
Posted 04/27/2012 10:54 PM   
Scroll To Top