How to get the workgroup size in OpenCL codegen?

As the GPU vendor recommend “Tell the Compiler the Work-Group Size” by

__attribute__((reqd_work_group_size(X,Y,Z))).

in OpenCL kenrel function.

I can’t get the work group size in codegen, Could you share how to get the work group size?

1 Like