Skip to content

Commit 20ad2d9

Browse files
authored
Add missing error case for clSetKernelArgDevicePointerEXT (KhronosGroup#1492)
It is never valid to call clSetKernelArgDevicePointerEXT for an argument that is not a pointer to the global address space. Since it is the choice of argument that is wrong in this case, CL_INVALID_ARG_INDEX looks like the most natural error code. Change-Id: I75f066c9731ad57f2325d8cd359b29819f8327fe Signed-off-by: Kevin Petit <kevin.petit@arm.com>
1 parent cf43f3c commit 20ad2d9

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

api/opencl_runtime_layer.asciidoc

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11173,7 +11173,10 @@ successfully. Otherwise, it returns one of the following errors:
1117311173
* {CL_INVALID_KERNEL} if _kernel_ is not a valid kernel object.
1117411174
* {CL_INVALID_OPERATION} if no devices in the context associated with _kernel_ support
1117511175
the {cl_ext_buffer_device_address_EXT} extension.
11176-
* {CL_INVALID_ARG_INDEX} if _arg_index_ is not a valid argument index.
11176+
* {CL_INVALID_ARG_INDEX}
11177+
** if _arg_index_ is not a valid argument index.
11178+
** if _arg_index_ corresponds to an argument that is not a pointer to the `global`
11179+
address space.
1117711180
* {CL_OUT_OF_RESOURCES} if there is a failure to allocate resources required
1117811181
by the OpenCL implementation on the device.
1117911182
* {CL_OUT_OF_HOST_MEMORY} if there is a failure to allocate resources

0 commit comments

Comments
 (0)