@@ -419,7 +419,7 @@ CL_API_ENTRY cl_int CL_API_CALL clSetKernelArgIntelFPGA(cl_kernel kernel,
419
419
ERR_RET (CL_INVALID_ARG_SIZE, context,
420
420
" Argument size is the wrong size" );
421
421
}
422
- } else if (arg_size == sizeof (cl_mem) && arg_value!= NULL &&
422
+ } else if (arg_size == sizeof (cl_mem) && arg_value != NULL &&
423
423
acl_pipe_is_valid_pointer (*((cl_mem *)arg_value), kernel)) {
424
424
is_pipe = CL_TRUE;
425
425
} else if (arg_size != arg_info->size ) {
@@ -442,7 +442,8 @@ CL_API_ENTRY cl_int CL_API_CALL clSetKernelArgIntelFPGA(cl_kernel kernel,
442
442
kernel->arg_defined [arg_index] = 1 ;
443
443
444
444
/* If this is a host pipe, create a host channel and bind them together */
445
- if (arg_info->host_accessible && pipe_ptr && pipe_ptr->host_pipe_info != NULL ) {
445
+ if (arg_info->host_accessible && pipe_ptr &&
446
+ pipe_ptr->host_pipe_info != NULL ) {
446
447
if (pipe_ptr->host_pipe_info ->m_binded_kernel != NULL ) {
447
448
ERR_RET (CL_INVALID_ARG_VALUE, context,
448
449
" This pipe has already been bound to a kernel. Cannot "
@@ -639,6 +640,7 @@ CL_API_ENTRY cl_int CL_API_CALL clSetKernelArgIntelFPGA(cl_kernel kernel,
639
640
kernel->arg_is_ptr [arg_index] = CL_FALSE;
640
641
} else if (is_sampler) {
641
642
cl_sampler sampler = *(cl_sampler *)arg_value;
643
+ assert (sampler);
642
644
int sampler_bitfield = 0 ;
643
645
644
646
sampler_bitfield = 0 ;
0 commit comments