GET_LOCAL_SIZE(3clc)
π GET_LOCAL_SIZE π
okay so bestie, this is a page from the OpenCL Manual (yes, the 3clc one) and it's literally about asking your kernel "hey, how many of us are in this dimension?" π«Ά
β¨ NAME β¨
get_local_size β returns the number of local work-items π
size_t get_local_size(uint dimindx);
πΈ DESCRIPTION πΈ
So like, this function returns the number of local work-items specified in the dimension identified by dimindx. No cap. π
Where does that number even come from? It's given by the local_work_size argument to clEnqueueNDRangeKernel(3clc) β if local_work_size is not NULL. But if it is NULL, then the OpenCL implementation itself picks an appropriate local_work_size value, and that's the value this function hands back to you. The implementation is the main character and it decides. π
Valid values of dimindx are 0 to get_work_dim(3clc)() - 1. For other values of dimindx, get_local_size() returns 1. Periodt. π
And for clEnqueueTask(3clc), this always returns 1. Every single time. Iconic consistency fr fr. β
π SPECIFICATION π
OpenCL Specification[1] π
π SEE ALSO π
go read those too bestie, they're all in the same little friend group π¦
π«Ά AUTHORS π«Ά
The Khronos Group π
Β©οΈ COPYRIGHT Β©οΈ
Copyright Β© 2007-2011 The Khronos Group Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and/or associated documentation files (the "Materials"), to deal in the Materials without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Materials, and to permit persons to whom the Materials are furnished to do so, subject to the condition that this copyright notice and permission notice shall be included in all copies or substantial portions of the Materials. π
π NOTES π
- OpenCL Specification page 242, section 6.12.1 - Work-Item Functions
ok that's the whole page, no skips, no summarising, we ate that π
and that's a wrap on GET_LOCAL_SIZE(3clc) from The Khronos Group, dated 01/14/2021 β mwah, take care of her πβ¨
π¦ where this page comes from
- ubuntu jammy: opencl-1.2-man-doc 1.0~svn33624-5 Β· other
- ubuntu noble: opencl-1.2-man-doc 1.0~svn33624-5 Β· other
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms