mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 11:38:05 +02:00
iris: Set MOCS on 3DSTATE_CONSTANT_ALL packets that disable all buffers
We'd like to add safeguards against accidental use of MOCS 0 (uncached), which can have large performance implications. One case where we missed setting a non-zero MOCS was in 3DSTATE_CONSTANT_ALL packets which fully disable all constant buffers. (If any constant buffer was present, we would set an actual MOCS value.) MOCS really shouldn't matter here, as there are no actual constant buffers to be cached. That said, it should be harmless to do so, and we can just assume a generic MOCS for internal buffers. Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13480>
This commit is contained in:
parent
0544afd2df
commit
369cd9ae28
1 changed files with 1 additions and 0 deletions
|
|
@ -5550,6 +5550,7 @@ emit_push_constant_packet_all(struct iris_context *ice,
|
|||
if (!push_bos) {
|
||||
iris_emit_cmd(batch, GENX(3DSTATE_CONSTANT_ALL), pc) {
|
||||
pc.ShaderUpdateEnable = shader_mask;
|
||||
pc.MOCS = iris_mocs(NULL, isl_dev, 0);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue