Mesa (master): tu: Use an input for the layer when lowering input attachments
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Aug 19 16:55:20 UTC 2020
Module: Mesa
Branch: master
Commit: 76f711d09d2f8c9b3bcd9f8c1694e553a486ac1f
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=76f711d09d2f8c9b3bcd9f8c1694e553a486ac1f
Author: Connor Abbott <cwabbott0 at gmail.com>
Date: Wed Jul 1 17:21:47 2020 +0200
tu: Use an input for the layer when lowering input attachments
Also remove a hack that's no longer needed. This should fix input
attachments with layered rendering.
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5719>
---
src/freedreno/vulkan/tu_shader.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/src/freedreno/vulkan/tu_shader.c b/src/freedreno/vulkan/tu_shader.c
index 3820f8877ee..4461bae26d0 100644
--- a/src/freedreno/vulkan/tu_shader.c
+++ b/src/freedreno/vulkan/tu_shader.c
@@ -354,13 +354,6 @@ lower_intrinsic(nir_builder *b, nir_intrinsic_instr *instr,
const struct tu_pipeline_layout *layout)
{
switch (instr->intrinsic) {
- case nir_intrinsic_load_layer_id:
- /* TODO: remove this when layered rendering is implemented */
- nir_ssa_def_rewrite_uses(&instr->dest.ssa,
- nir_src_for_ssa(nir_imm_int(b, 0)));
- nir_instr_remove(&instr->instr);
- return true;
-
case nir_intrinsic_load_push_constant:
lower_load_push_constant(b, instr, shader);
return true;
@@ -774,7 +767,7 @@ tu_shader_create(struct tu_device *dev,
NIR_PASS_V(nir, nir_lower_input_attachments,
&(nir_input_attachment_options) {
.use_fragcoord_sysval = true,
- .use_layer_id_sysval = true,
+ .use_layer_id_sysval = false,
});
}
More information about the mesa-commit
mailing list