|
|
@ -126,8 +126,9 @@ cl_program build_opencl_kernel(build_kernel_data *data, const char *filename) |
|
|
|
applog(LOG_ERR, "Error %d: Building Program (clBuildProgram)", status); |
|
|
|
applog(LOG_ERR, "Error %d: Building Program (clBuildProgram)", status); |
|
|
|
status = clGetProgramBuildInfo(program, *data->device, CL_PROGRAM_BUILD_LOG, 0, NULL, &log_size); |
|
|
|
status = clGetProgramBuildInfo(program, *data->device, CL_PROGRAM_BUILD_LOG, 0, NULL, &log_size); |
|
|
|
|
|
|
|
|
|
|
|
char *sz_log = (char *)malloc(log_size); |
|
|
|
char *sz_log = (char *)malloc(log_size + 1); |
|
|
|
status = clGetProgramBuildInfo(program, *data->device, CL_PROGRAM_BUILD_LOG, log_size, sz_log, NULL); |
|
|
|
status = clGetProgramBuildInfo(program, *data->device, CL_PROGRAM_BUILD_LOG, log_size, sz_log, NULL); |
|
|
|
|
|
|
|
sz_log[log_size] = '\0'; |
|
|
|
applogsiz(LOG_ERR, log_size, "%s", sz_log); |
|
|
|
applogsiz(LOG_ERR, log_size, "%s", sz_log); |
|
|
|
free(sz_log); |
|
|
|
free(sz_log); |
|
|
|
goto out; |
|
|
|
goto out; |
|
|
|