mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-04-26 15:30:40 +02:00
v3d: Don't forget to include RT writes in precompiles.
Looking at some assembly dumps for an optimization, we were clearly missing important parts of the shader!
This commit is contained in:
parent
3a81c753a3
commit
49d8e2aff1
1 changed files with 10 additions and 0 deletions
|
|
@ -197,6 +197,16 @@ v3d_shader_precompile(struct v3d_context *v3d,
|
|||
.base.shader_state = so,
|
||||
};
|
||||
|
||||
nir_foreach_variable(var, &s->outputs) {
|
||||
if (var->data.location == FRAG_RESULT_COLOR) {
|
||||
key.nr_cbufs = 1;
|
||||
} else if (var->data.location == FRAG_RESULT_DATA0) {
|
||||
key.nr_cbufs = MAX2(key.nr_cbufs,
|
||||
var->data.location -
|
||||
FRAG_RESULT_DATA0 + 1);
|
||||
}
|
||||
}
|
||||
|
||||
v3d_setup_shared_precompile_key(so, &key.base);
|
||||
v3d_get_compiled_shader(v3d, &key.base);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue