anv: drop add_var_binding from anv_nir_apply_pipeline_layout.c
authorJason Ekstrand <jason.ekstrand@intel.com>
Tue, 12 Feb 2019 20:02:09 +0000 (14:02 -0600)
committerJason Ekstrand <jason.ekstrand@intel.com>
Tue, 5 Mar 2019 16:06:50 +0000 (10:06 -0600)
It has exactly one caller.  Just inline it.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/intel/vulkan/anv_nir_apply_pipeline_layout.c

index c528132d9ca0f9ed41063a672622a796796289ce..89f4bb7899c4677c1d4ae5318ad3226d27f25e60 100644 (file)
@@ -52,17 +52,12 @@ add_binding(struct apply_pipeline_layout_state *state,
    BITSET_SET(state->set[set].used, binding);
 }
 
-static void
-add_var_binding(struct apply_pipeline_layout_state *state, nir_variable *var)
-{
-   add_binding(state, var->data.descriptor_set, var->data.binding);
-}
-
 static void
 add_deref_src_binding(struct apply_pipeline_layout_state *state, nir_src src)
 {
    nir_deref_instr *deref = nir_src_as_deref(src);
-   add_var_binding(state, nir_deref_instr_get_variable(deref));
+   nir_variable *var = nir_deref_instr_get_variable(deref);
+   add_binding(state, var->data.descriptor_set, var->data.binding);
 }
 
 static void