summaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/anv_pipeline.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2016-08-24 17:14:11 -0700
committerJason Ekstrand <[email protected]>2016-08-24 20:42:05 -0700
commit2301705dee6324634520559b27ac6728ebb02191 (patch)
tree30832142f487a117e15b3c9f789ff119b5428bf3 /src/intel/vulkan/anv_pipeline.c
parent05f36435ef117e48f457b44877d04dd6249b3bb7 (diff)
anv: Include the pipeline layout in the shader hash
The pipeline layout affects shader compilation because it is what determines binding table locations as well as whether or not a particular buffer has dynamic offsets. Since this affects the generated shader, it needs to be in the hash. This fixes a bunch of CTS tests now that the CTS is using a pipeline cache. Signed-off-by: Jason Ekstrand <[email protected]> Reviewed-by: Kristian Høgsberg <[email protected]> Cc: "12.0" <[email protected]>
Diffstat (limited to 'src/intel/vulkan/anv_pipeline.c')
-rw-r--r--src/intel/vulkan/anv_pipeline.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/intel/vulkan/anv_pipeline.c b/src/intel/vulkan/anv_pipeline.c
index 57e1bddd44f..48d267b9181 100644
--- a/src/intel/vulkan/anv_pipeline.c
+++ b/src/intel/vulkan/anv_pipeline.c
@@ -423,7 +423,8 @@ anv_pipeline_compile_vs(struct anv_pipeline *pipeline,
populate_vs_prog_key(&pipeline->device->info, &key);
if (module->size > 0) {
- anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint, spec_info);
+ anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint,
+ pipeline->layout, spec_info);
kernel = anv_pipeline_cache_search(cache, sha1, &stage_prog_data, &map);
}
@@ -511,7 +512,8 @@ anv_pipeline_compile_gs(struct anv_pipeline *pipeline,
populate_gs_prog_key(&pipeline->device->info, &key);
if (module->size > 0) {
- anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint, spec_info);
+ anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint,
+ pipeline->layout, spec_info);
kernel = anv_pipeline_cache_search(cache, sha1, &stage_prog_data, &map);
}
@@ -590,7 +592,8 @@ anv_pipeline_compile_fs(struct anv_pipeline *pipeline,
populate_wm_prog_key(&pipeline->device->info, info, extra, &key);
if (module->size > 0) {
- anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint, spec_info);
+ anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint,
+ pipeline->layout, spec_info);
pipeline->ps_ksp0 =
anv_pipeline_cache_search(cache, sha1, &stage_prog_data, &map);
}
@@ -720,7 +723,8 @@ anv_pipeline_compile_cs(struct anv_pipeline *pipeline,
populate_cs_prog_key(&pipeline->device->info, &key);
if (module->size > 0) {
- anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint, spec_info);
+ anv_hash_shader(sha1, &key, sizeof(key), module, entrypoint,
+ pipeline->layout, spec_info);
kernel = anv_pipeline_cache_search(cache, sha1, &stage_prog_data, &map);
}