cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

boxerab
Challenger

Binary kernel refuses to accept fourth opencl image argument

I have a kernel that runs on four open cl images.

If I build the kernel and then run, it runs fine.

But, if I generate a binary, and then load this from disk, I get an

CL_INVALID_KERNEL_ARG when trying to set the fourth image kernel argument.

0 Likes
1 Solution

So, it turns out that the problem was in my kernel.

I was passing four different opencl images, and choosing one of them at runtime based on global work item id.

The chosen image was stored in a local image variable. But, it looks like the AMD compiler didn't like that.

Solution was to work with original variables instead of the local variable.

View solution in original post

0 Likes
2 Replies
boxerab
Challenger

Actually, it looks like the build fails for these kernels.

0 Likes

So, it turns out that the problem was in my kernel.

I was passing four different opencl images, and choosing one of them at runtime based on global work item id.

The chosen image was stored in a local image variable. But, it looks like the AMD compiler didn't like that.

Solution was to work with original variables instead of the local variable.

0 Likes