summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/clover/api
diff options
context:
space:
mode:
authorGrigori Goronzy <[email protected]>2015-05-28 13:01:51 +0200
committerGrigori Goronzy <[email protected]>2015-06-29 13:24:37 +0200
commitd15b32ebded278243eb648bb9ecd4c5f5d6d0569 (patch)
tree5f9f347641e1a5751f5a463a723d67a8d450d7a3 /src/gallium/state_trackers/clover/api
parent249a9df7fce0a6bebc70852ab583c5324208bf06 (diff)
clover: implement CL_KERNEL_PREFERRED_WORK_GROUP_SIZE_MULTIPLE
Work-group size should always be aligned to subgroup size; this is a basic requirement, otherwise some work-items will be no-operation. It might make sense to refine the value according to a kernel's resource usage, but that's a possible optimization for the future. Reviewed-by: Francisco Jerez <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers/clover/api')
-rw-r--r--src/gallium/state_trackers/clover/api/kernel.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/clover/api/kernel.cpp b/src/gallium/state_trackers/clover/api/kernel.cpp
index 05cc392a914..857a152b554 100644
--- a/src/gallium/state_trackers/clover/api/kernel.cpp
+++ b/src/gallium/state_trackers/clover/api/kernel.cpp
@@ -169,7 +169,7 @@ clGetKernelWorkGroupInfo(cl_kernel d_kern, cl_device_id d_dev,
break;
case CL_KERNEL_PREFERRED_WORK_GROUP_SIZE_MULTIPLE:
- buf.as_scalar<size_t>() = 1;
+ buf.as_scalar<size_t>() = dev.subgroup_size();
break;
case CL_KERNEL_PRIVATE_MEM_SIZE: