Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve the description of error codes for clSetKernelArg #1319

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 13 additions & 10 deletions api/opencl_runtime_layer.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -10704,22 +10704,25 @@ endif::cl_khr_depth_images,cl_khr_gl_msaa_sharing[]
* {CL_INVALID_DEVICE_QUEUE} for an argument declared to be of type _queue_t_
when the specified _arg_value_ is not a valid device queue object.
This error code is <<unified-spec, missing before>> version 2.0.
* {CL_INVALID_ARG_SIZE} if _arg_size_ does not match the size of the data
type for an argument that is not a memory object or if the argument is a
memory object and _arg_size_ != `sizeof({cl_mem_TYPE})` or if _arg_size_ is
zero and the argument is declared with the local qualifier or if the
argument is a sampler and _arg_size_ != `sizeof({cl_sampler_TYPE})`.
* {CL_INVALID_ARG_SIZE}
** if _arg_size_ does not match the size of the data type for an argument
that is not a memory object, or
** if the argument is a memory object and _arg_size_ != `sizeof({cl_mem_TYPE})`, or
** if _arg_size_ is zero and the argument is declared with the `local` qualifier, or
** if the argument is a sampler and _arg_size_ != `sizeof({cl_sampler_TYPE})`.
* {CL_MAX_SIZE_RESTRICTION_EXCEEDED} if the size in bytes of the memory
object (if the argument is a memory object) or _arg_size_ (if the
argument is declared with `local` qualifier) exceeds a language-
specified maximum size restriction for this argument, such as the
*MaxByteOffset* SPIR-V decoration.
This error code is <<unified-spec, missing before>> version 2.2.
* {CL_INVALID_ARG_VALUE} if the argument is an image declared with the
`read_only` qualifier and _arg_value_ refers to an image object created
with _cl_mem_flags_ of {CL_MEM_WRITE_ONLY} or if the image argument is
declared with the `write_only` qualifier and _arg_value_ refers to an
image object created with _cl_mem_flags_ of {CL_MEM_READ_ONLY}.
* {CL_INVALID_ARG_VALUE}
** if the argument is an image declared with the `read_only` qualifier and
_arg_value_ refers to an image object created with _cl_mem_flags_ of
{CL_MEM_WRITE_ONLY}, or
** if the image argument is declared with the `write_only` qualifier and
_arg_value_ refers to an image object created with _cl_mem_flags_ of
{CL_MEM_READ_ONLY}.
* {CL_OUT_OF_RESOURCES} if there is a failure to allocate resources required
by the OpenCL implementation on the device.
* {CL_OUT_OF_HOST_MEMORY} if there is a failure to allocate resources
Expand Down