[Beignet] [PATCH OCL20] Runtime: Add new param_name to clGetProgramBuildInfo
Xiuli Pan
xiuli.pan at intel.com
Tue Apr 5 05:47:45 UTC 2016
From: Pan Xiuli <xiuli.pan at intel.com>
Add CL_PROGRAM_BUILD_GLOBAL_VARIABLE_TOTAL_SIZE for api
clGetProgramBuildInfo, return the constantset size from backend.
Signed-off-by: Pan Xiuli <xiuli.pan at intel.com>
---
src/cl_api.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/cl_api.c b/src/cl_api.c
index 5697e34..74e2b72 100644
--- a/src/cl_api.c
+++ b/src/cl_api.c
@@ -1522,6 +1522,9 @@ clGetProgramBuildInfo(cl_program program,
}else if (param_name == CL_PROGRAM_BINARY_TYPE){
FILL_GETINFO_RET (cl_uint, 1, &program->binary_type, CL_SUCCESS);
+ }else if (param_name == CL_PROGRAM_BUILD_GLOBAL_VARIABLE_TOTAL_SIZE){
+ size_t tmp = interp_program_get_global_constant_size(program->opaque);
+ FILL_GETINFO_RET (size_t, 1, &tmp, CL_SUCCESS);
} else {
return CL_INVALID_VALUE;
}
--
2.5.0
More information about the Beignet
mailing list