Module: Mesa
Branch: main
Commit: fdfa59d7bfb481e71173e3e004387e0d71cb86c5
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=fdfa59d7bfb481e71173e3e004387e0d71cb86c5

Author: Samuel Pitoiset <[email protected]>
Date:   Fri Sep  9 16:52:55 2022 +0200

radv: rename radv_pipeline_key::vs::dynamic_vs_input to has_prolog

With GPL it's possible to create VS prologs without this dynamic state,
so it seems better to rename.

Signed-off-by: Samuel Pitoiset <[email protected]>
Reviewed-by: Timur Kristóf <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18519>

---

 src/amd/vulkan/radv_pipeline.c    | 4 ++--
 src/amd/vulkan/radv_shader.h      | 2 +-
 src/amd/vulkan/radv_shader_info.c | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/amd/vulkan/radv_pipeline.c b/src/amd/vulkan/radv_pipeline.c
index 5ae0be499a2..dbb0f3dd0a7 100644
--- a/src/amd/vulkan/radv_pipeline.c
+++ b/src/amd/vulkan/radv_pipeline.c
@@ -2664,7 +2664,7 @@ radv_generate_graphics_pipeline_key(const struct 
radv_graphics_pipeline *pipelin
    key.has_multiview_view_index = !!state->rp->view_mask;
 
    if (pipeline->dynamic_states & RADV_DYNAMIC_VERTEX_INPUT) {
-      key.vs.dynamic_input_state = true;
+      key.vs.has_prolog = true;
    }
 
    /* Vertex input state */
@@ -3242,7 +3242,7 @@ radv_lower_vs_input(nir_shader *nir, const struct 
radv_physical_device *pdevice,
    nir_function_impl *impl = nir_shader_get_entrypoint(nir);
    bool progress = false;
 
-   if (pipeline_key->vs.dynamic_input_state)
+   if (pipeline_key->vs.has_prolog)
       return false;
 
    nir_builder b;
diff --git a/src/amd/vulkan/radv_shader.h b/src/amd/vulkan/radv_shader.h
index 236a4020770..b889bc44234 100644
--- a/src/amd/vulkan/radv_shader.h
+++ b/src/amd/vulkan/radv_shader.h
@@ -73,7 +73,7 @@ struct radv_pipeline_key {
       uint32_t vertex_attribute_strides[MAX_VERTEX_ATTRIBS];
       uint8_t vertex_binding_align[MAX_VBS];
       uint32_t provoking_vtx_last : 1;
-      uint32_t dynamic_input_state : 1;
+      uint32_t has_prolog : 1;
       uint8_t topology;
    } vs;
 
diff --git a/src/amd/vulkan/radv_shader_info.c 
b/src/amd/vulkan/radv_shader_info.c
index aec354de913..42260d90b3a 100644
--- a/src/amd/vulkan/radv_shader_info.c
+++ b/src/amd/vulkan/radv_shader_info.c
@@ -382,7 +382,7 @@ static void
 gather_shader_info_vs(struct radv_device *device, const nir_shader *nir,
                       const struct radv_pipeline_key *pipeline_key, struct 
radv_shader_info *info)
 {
-   if (pipeline_key->vs.dynamic_input_state && nir->info.inputs_read) {
+   if (pipeline_key->vs.has_prolog && nir->info.inputs_read) {
       info->vs.has_prolog = true;
       info->vs.dynamic_inputs = true;
    }

Reply via email to