Fixes a GPU hang in Car Chase.
Cc: mesa-stable@lists.freedesktop.org
v2: Add comment explaining why (Jason).
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4035>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4035>
desc.BarrierEnable = cs_prog_data->uses_barrier;
desc.CrossThreadConstantDataReadLength =
cs_prog_data->push.cross_thread.regs;
+#if GEN_GEN >= 12
+ /* TODO: Check if we are missing workarounds and enable mid-thread
+ * preemption.
+ *
+ * We still have issues with mid-thread preemption (it was already
+ * disabled by the kernel on gen11, due to missing workarounds). It's
+ * possible that we are just missing some workarounds, and could enable
+ * it later, but for now let's disable it to fix a GPU in compute in Car
+ * Chase (and possibly more).
+ */
+ desc.ThreadPreemptionDisable = true;
+#endif
}
}
<value name="Ftz" value="0"/>
<value name="SetByKernel" value="1"/>
</field>
+ <field name="Thread Preemption Disable" start="84" end="84" type="bool"/>
<field name="Sampler Count" start="98" end="100" type="uint">
<value name="No samplers used" value="0"/>
<value name="Between 1 and 4 samplers used" value="1"/>
.CrossThreadConstantDataReadLength =
cs_prog_data->push.cross_thread.regs,
#endif
+#if GEN_GEN >= 12
+ /* TODO: Check if we are missing workarounds and enable mid-thread
+ * preemption.
+ *
+ * We still have issues with mid-thread preemption (it was already
+ * disabled by the kernel on gen11, due to missing workarounds). It's
+ * possible that we are just missing some workarounds, and could enable
+ * it later, but for now let's disable it to fix a GPU in compute in Car
+ * Chase (and possibly more).
+ */
+ .ThreadPreemptionDisable = true,
+#endif
.NumberofThreadsinGPGPUThreadGroup = cs_prog_data->threads,
};