> > > +#define RELEASE_KERNEL(k) \ > > > +do { \ > > > + if (k) { \ > > > + cle = clReleaseKernel(k); \ > > > + if (cle != CL_SUCCESS) \ > > > + av_log(avctx, AV_LOG_ERROR, "Failed to release " \ > > > + "kernel: %d.\n", cle); \ > > > + } \ > > > +} while(0) > > > > This appears multiple times here and also in other filters. Maybe it > > should be a > > macro in opencl.h like CL_SET_KERNEL_ARG? Hi Mark,
I am rethinking about this problem, can we just simply call clReleaseKernel() and not checking the input and the error_code. OpenCL spec has require implementation to check the input argument. So I think we can just ignore the if-null check. As we are destroying the objects, is it still useful to care the error code returned? Thanks! Ruiling _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".