return nir_intrinsic_load_local_group_size;
case SYSTEM_VALUE_GLOBAL_INVOCATION_ID:
return nir_intrinsic_load_global_invocation_id;
+ case SYSTEM_VALUE_WORK_DIM:
+ return nir_intrinsic_load_work_dim;
default:
unreachable("system value does not directly correspond to intrinsic");
}
system_value("subgroup_id", 1)
system_value("local_group_size", 3)
system_value("global_invocation_id", 3)
+system_value("work_dim", 1)
# Blend constant color values. Float values are clamped.#
system_value("blend_const_color_r_float", 1)
ENUM(SYSTEM_VALUE_NUM_WORK_GROUPS),
ENUM(SYSTEM_VALUE_LOCAL_GROUP_SIZE),
ENUM(SYSTEM_VALUE_GLOBAL_GROUP_SIZE),
+ ENUM(SYSTEM_VALUE_WORK_DIM),
ENUM(SYSTEM_VALUE_DEVICE_INDEX),
ENUM(SYSTEM_VALUE_VIEW_INDEX),
ENUM(SYSTEM_VALUE_VERTEX_CNT),
SYSTEM_VALUE_NUM_WORK_GROUPS,
SYSTEM_VALUE_LOCAL_GROUP_SIZE,
SYSTEM_VALUE_GLOBAL_GROUP_SIZE,
+ SYSTEM_VALUE_WORK_DIM,
/*@}*/
/** Required for VK_KHR_device_group */
*location = FRAG_RESULT_STENCIL;
vtn_assert(*mode == nir_var_shader_out);
break;
+ case SpvBuiltInWorkDim:
+ *location = SYSTEM_VALUE_WORK_DIM;
+ set_mode_system_value(b, mode);
+ break;
case SpvBuiltInGlobalSize:
*location = SYSTEM_VALUE_GLOBAL_GROUP_SIZE;
set_mode_system_value(b, mode);