We apparently were not setting MOCS for 3DSTATE_CONSTANT_XS at all.
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13480>
{
struct crocus_compiled_shader *shader = ice->shaders.prog[stage];
struct brw_stage_prog_data *prog_data = shader ? (void *) shader->prog_data : NULL;
+ UNUSED uint32_t mocs = crocus_mocs(NULL, &batch->screen->isl_dev);
#if GFX_VER == 7
if (stage == MESA_SHADER_VERTEX) {
crocus_emit_cmd(batch, GENX(3DSTATE_CONSTANT_VS), pkt) {
pkt._3DCommandSubOpcode = push_constant_opcodes[stage];
#if GFX_VER >= 7
+#if GFX_VER != 8
+ /* MOCS is MBZ on Gen8 so we skip it there */
+ pkt.ConstantBody.MOCS = mocs;
+#endif
+
if (prog_data) {
/* The Skylake PRM contains the following restriction:
*