struct brw_stage_prog_data base;
unsigned local_size[3];
- unsigned max_variable_local_size;
unsigned simd_size;
unsigned slm_size;
bool uses_barrier;
bool uses_num_work_groups;
- bool uses_variable_group_size;
struct {
struct brw_push_const_block cross_thread;
prog_data->slm_size = src_shader->num_shared;
unsigned local_workgroup_size;
- if (prog_data->uses_variable_group_size) {
- prog_data->max_variable_local_size =
- src_shader->info.cs.max_variable_local_size;
+ if (src_shader->info.cs.local_size_variable) {
local_workgroup_size = src_shader->info.cs.max_variable_local_size;
} else {
prog_data->local_size[0] = src_shader->info.cs.local_size[0];
assert(uniforms == prog_data->nr_params);
uint32_t *param;
- if (brw_cs_prog_data(prog_data)->uses_variable_group_size) {
+ if (nir->info.cs.local_size_variable) {
param = brw_stage_prog_data_add_params(prog_data, 3);
for (unsigned i = 0; i < 3; i++) {
param[i] = (BRW_PARAM_BUILTIN_WORK_GROUP_SIZE_X + i);
* invocations are already executed lock-step. Instead of an actual
* barrier just emit a scheduling fence, that will generate no code.
*/
- if (!cs_prog_data->uses_variable_group_size &&
+ if (!nir->info.cs.local_size_variable &&
workgroup_size() <= dispatch_width) {
bld.exec_all().group(1, 0).emit(FS_OPCODE_SCHEDULING_FENCE);
break;
*
* TODO: Check if applies for many HW threads sharing same Data Port.
*/
- if (!brw_cs_prog_data(prog_data)->uses_variable_group_size &&
+ if (!nir->info.cs.local_size_variable &&
slm_fence && workgroup_size() <= dispatch_width)
slm_fence = false;
* the actual size is not known until the dispatch command is issued.
*/
if (nir->info.cs.local_size_variable) {
- prog_data.uses_variable_group_size = true;
nir->info.cs.max_variable_local_size =
gl_ctx->Const.MaxComputeVariableGroupInvocations;
- } else {
- prog_data.uses_variable_group_size = false;
}
char *error_str;