summaryrefslogtreecommitdiffstats
path: root/src/amd
diff options
context:
space:
mode:
authorSamuel Pitoiset <[email protected]>2019-08-28 16:52:30 +0200
committerSamuel Pitoiset <[email protected]>2019-08-30 09:33:27 +0200
commit7b1655ccf3471a7c961612197b7227fd0e4abb35 (patch)
tree87c6894de21a6542ecb83e2d458f1fadc0056938 /src/amd
parent081561de16e077ab613accf8b8f8f5d5df81ea42 (diff)
radv: move setting can_discard to ac_fill_shader_info()
Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/amd')
-rw-r--r--src/amd/vulkan/radv_nir_to_llvm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/amd/vulkan/radv_nir_to_llvm.c b/src/amd/vulkan/radv_nir_to_llvm.c
index b4ee28f4d37..1c1633a51e7 100644
--- a/src/amd/vulkan/radv_nir_to_llvm.c
+++ b/src/amd/vulkan/radv_nir_to_llvm.c
@@ -4298,7 +4298,6 @@ LLVMModuleRef ac_translate_nir_to_llvm(struct ac_llvm_compiler *ac_llvm,
} else if (shaders[i]->info.stage == MESA_SHADER_VERTEX) {
ctx.abi.load_base_vertex = radv_load_base_vertex;
} else if (shaders[i]->info.stage == MESA_SHADER_FRAGMENT) {
- shader_info->fs.can_discard = shaders[i]->info.fs.uses_discard;
ctx.abi.load_sample_position = load_sample_position;
ctx.abi.load_sample_mask_in = load_sample_mask_in;
ctx.abi.emit_kill = radv_emit_kill;
@@ -4521,6 +4520,7 @@ ac_fill_shader_info(struct radv_shader_variant_info *shader_info, struct nir_sha
shader_info->cs.block_size[i] = nir->info.cs.local_size[i];
break;
case MESA_SHADER_FRAGMENT:
+ shader_info->fs.can_discard = nir->info.fs.uses_discard;
shader_info->fs.early_fragment_test = nir->info.fs.early_fragment_tests;
shader_info->fs.post_depth_coverage = nir->info.fs.post_depth_coverage;
break;