zink: track which stages in gfx programs are using inlined uniforms
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18135>
This commit is contained in:

committed by
Marge Bot

parent
8a5b3658df
commit
6a836eaff5
@@ -257,6 +257,12 @@ update_gfx_shader_modules(struct zink_context *ctx,
|
||||
hash_changed = true;
|
||||
default_variants &= zm->default_variant;
|
||||
prog->modules[i] = zm;
|
||||
if (has_inline) {
|
||||
if (zm->num_uniforms)
|
||||
prog->inline_variants |= BITFIELD_BIT(i);
|
||||
else
|
||||
prog->inline_variants &= ~BITFIELD_BIT(i);
|
||||
}
|
||||
variant_hash ^= prog->modules[i]->hash;
|
||||
}
|
||||
|
||||
|
@@ -793,6 +793,7 @@ struct zink_gfx_program {
|
||||
struct hash_table pipelines[2][11]; // [dynamic, renderpass][number of draw modes we support]
|
||||
uint32_t default_variant_hash;
|
||||
uint32_t last_variant_hash;
|
||||
uint8_t inline_variants; //which stages are using inlined uniforms
|
||||
|
||||
struct set libs[4]; //zink_gfx_library_key[primtype] -> VkPipeline
|
||||
};
|
||||
|
Reference in New Issue
Block a user