aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_shader_cache.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2017-04-30 16:05:42 +0200
committerMarek Olšák <[email protected]>2017-05-08 18:32:00 +0200
commitbb6e851a1e52599e346112837b93686a90817901 (patch)
treebe73ec74dab5f45e9871f5de8408620b877469e7 /src/mesa/state_tracker/st_shader_cache.c
parent7ca8b86cb9d27db2251507d84026e031ae9304f3 (diff)
st/mesa: unify TCS, TES, GS st_*_program structures
Tested-by: Edmondo Tommasina <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker/st_shader_cache.c')
-rw-r--r--src/mesa/state_tracker/st_shader_cache.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/mesa/state_tracker/st_shader_cache.c b/src/mesa/state_tracker/st_shader_cache.c
index 1a11f1135d7..0771ca660cf 100644
--- a/src/mesa/state_tracker/st_shader_cache.c
+++ b/src/mesa/state_tracker/st_shader_cache.c
@@ -87,7 +87,7 @@ st_store_tgsi_in_disk_cache(struct st_context *st, struct gl_program *prog,
break;
}
case MESA_SHADER_TESS_CTRL: {
- struct st_tessctrl_program *stcp = (struct st_tessctrl_program *) prog;
+ struct st_common_program *stcp = (struct st_common_program *) prog;
sha1 = stcp->sha1;
write_stream_out_to_cache(blob, out_state);
@@ -95,7 +95,7 @@ st_store_tgsi_in_disk_cache(struct st_context *st, struct gl_program *prog,
break;
}
case MESA_SHADER_TESS_EVAL: {
- struct st_tesseval_program *step = (struct st_tesseval_program *) prog;
+ struct st_common_program *step = (struct st_common_program *) prog;
sha1 = step->sha1;
write_stream_out_to_cache(blob, out_state);
@@ -103,7 +103,7 @@ st_store_tgsi_in_disk_cache(struct st_context *st, struct gl_program *prog,
break;
}
case MESA_SHADER_GEOMETRY: {
- struct st_geometry_program *stgp = (struct st_geometry_program *) prog;
+ struct st_common_program *stgp = (struct st_common_program *) prog;
sha1 = stgp->sha1;
write_stream_out_to_cache(blob, out_state);
@@ -188,24 +188,24 @@ st_load_tgsi_from_disk_cache(struct gl_context *ctx,
break;
}
case MESA_SHADER_TESS_CTRL: {
- struct st_tessctrl_program *stcp =
- (struct st_tessctrl_program *) glprog;
+ struct st_common_program *stcp =
+ (struct st_common_program *) glprog;
stage_sha1[i] = stcp->sha1;
ralloc_strcat(&buf, " tcs");
disk_cache_compute_key(ctx->Cache, buf, strlen(buf), stage_sha1[i]);
break;
}
case MESA_SHADER_TESS_EVAL: {
- struct st_tesseval_program *step =
- (struct st_tesseval_program *) glprog;
+ struct st_common_program *step =
+ (struct st_common_program *) glprog;
stage_sha1[i] = step->sha1;
ralloc_strcat(&buf, " tes");
disk_cache_compute_key(ctx->Cache, buf, strlen(buf), stage_sha1[i]);
break;
}
case MESA_SHADER_GEOMETRY: {
- struct st_geometry_program *stgp =
- (struct st_geometry_program *) glprog;
+ struct st_common_program *stgp =
+ (struct st_common_program *) glprog;
stage_sha1[i] = stgp->sha1;
ralloc_strcat(&buf, " gs");
disk_cache_compute_key(ctx->Cache, buf, strlen(buf), stage_sha1[i]);
@@ -278,8 +278,8 @@ st_load_tgsi_from_disk_cache(struct gl_context *ctx,
break;
}
case MESA_SHADER_TESS_CTRL: {
- struct st_tessctrl_program *sttcp =
- (struct st_tessctrl_program *) glprog;
+ struct st_common_program *sttcp =
+ (struct st_common_program *) glprog;
st_release_basic_variants(st, sttcp->Base.Target,
&sttcp->variants, &sttcp->tgsi);
@@ -293,8 +293,8 @@ st_load_tgsi_from_disk_cache(struct gl_context *ctx,
break;
}
case MESA_SHADER_TESS_EVAL: {
- struct st_tesseval_program *sttep =
- (struct st_tesseval_program *) glprog;
+ struct st_common_program *sttep =
+ (struct st_common_program *) glprog;
st_release_basic_variants(st, sttep->Base.Target,
&sttep->variants, &sttep->tgsi);
@@ -308,8 +308,8 @@ st_load_tgsi_from_disk_cache(struct gl_context *ctx,
break;
}
case MESA_SHADER_GEOMETRY: {
- struct st_geometry_program *stgp =
- (struct st_geometry_program *) glprog;
+ struct st_common_program *stgp =
+ (struct st_common_program *) glprog;
st_release_basic_variants(st, stgp->Base.Target, &stgp->variants,
&stgp->tgsi);