* (non-binning) variant.
*/
static struct ir3_shader_variant *
-create_variant(struct ir3_shader *shader, struct ir3_shader_key *key,
+create_variant(struct ir3_shader *shader, const struct ir3_shader_key *key,
struct ir3_shader_variant *nonbinning)
{
struct ir3_shader_variant *v = CALLOC_STRUCT(ir3_shader_variant);
}
static inline struct ir3_shader_variant *
-shader_variant(struct ir3_shader *shader, struct ir3_shader_key *key,
+shader_variant(struct ir3_shader *shader, const struct ir3_shader_key *key,
bool *created)
{
struct ir3_shader_variant *v;
}
struct ir3_shader_variant *
-ir3_shader_get_variant(struct ir3_shader *shader, struct ir3_shader_key *key,
+ir3_shader_get_variant(struct ir3_shader *shader, const struct ir3_shader_key *key,
bool binning_pass, bool *created)
{
mtx_lock(&shader->variants_lock);
}
static inline bool
-ir3_shader_key_equal(struct ir3_shader_key *a, struct ir3_shader_key *b)
+ir3_shader_key_equal(const struct ir3_shader_key *a, const struct ir3_shader_key *b)
{
/* slow-path if we need to check {v,f}saturate_{s,t,r} */
if (a->has_per_samp || b->has_per_samp)
void * ir3_shader_assemble(struct ir3_shader_variant *v);
struct ir3_shader_variant * ir3_shader_get_variant(struct ir3_shader *shader,
- struct ir3_shader_key *key, bool binning_pass, bool *created);
+ const struct ir3_shader_key *key, bool binning_pass, bool *created);
struct ir3_shader * ir3_shader_from_nir(struct ir3_compiler *compiler, nir_shader *nir,
unsigned reserved_user_consts, struct ir3_stream_output_info *stream_output);
void ir3_shader_destroy(struct ir3_shader *shader);