diff --git a/.pick_status.json b/.pick_status.json index a9d6d3d7748..e8da2560613 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -914,7 +914,7 @@ "description": "rusticl/memory: fix sampler argument size check", "nominated": true, "nomination_type": 0, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": null, "notes": null diff --git a/src/gallium/frontends/rusticl/api/kernel.rs b/src/gallium/frontends/rusticl/api/kernel.rs index bdab3e207e4..9520e5a8725 100644 --- a/src/gallium/frontends/rusticl/api/kernel.rs +++ b/src/gallium/frontends/rusticl/api/kernel.rs @@ -365,7 +365,14 @@ fn set_kernel_arg( return Err(CL_INVALID_ARG_SIZE); } } - _ => { + + KernelArgType::Sampler => { + if arg_size != std::mem::size_of::() { + return Err(CL_INVALID_ARG_SIZE); + } + } + + KernelArgType::Constant => { if arg.size != arg_size { return Err(CL_INVALID_ARG_SIZE); }