cancel
Showing results for 
Search instead for 
Did you mean: 

OpenCL

sandyandr
Adept I
Adept I

Image access

I have two kernels. One of them writes (only) some image. Other - only reads it. Host has no business here. Is there any possibility to switch image access mode from read_only to write_only without image destruction/recreation between different kernel executions? I know, that I should better use read_write or even buffers for such tasks, but performance level is important - I want to use cache if there is any possibility to speed up the code with it here.

0 Kudos
Reply
3 Replies
nou
Exemplar
Exemplar

Re: Image access

yes you can specify image with __read_only qualifiers and __write_only in second one. then you must pass CL_READ_WRITE flag into clCreateImage() function.

sandyandr
Adept I
Adept I

Re: Image access

Thank you. By the way, where could I find information about exact cache dependancies on specified kernel qualifiers and image flags? Also, can't find the new AMD APP OCL Programming Guide (august revision - the last one?).

0 Kudos
Reply
pinform
Staff
Staff

Re: Image access

0 Kudos
Reply