[Mesa-dev] [PATCH 15/21] etnaviv: compiler: ignore nir_instr_type_ssa_undef

Philipp Zabel p.zabel at pengutronix.de
Tue Jun 5 14:38:39 UTC 2018


From: Michael Tretter <m.tretter at pengutronix.de>

Ignore ssa_undef nir instructions when generating code, because all
users of the undefined values are removed and undefined values are not
used. The instructions should be removed while rewriting the users of
undefined variables, but are not removed yet.

Signed-off-by: Michael Tretter <m.tretter at pengutronix.de>
Signed-off-by: Philipp Zabel <p.zabel at pengutronix.de>
---
 src/gallium/drivers/etnaviv/etnaviv_compiler.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/gallium/drivers/etnaviv/etnaviv_compiler.c b/src/gallium/drivers/etnaviv/etnaviv_compiler.c
index 66553199fe19..f17b9979b705 100644
--- a/src/gallium/drivers/etnaviv/etnaviv_compiler.c
+++ b/src/gallium/drivers/etnaviv/etnaviv_compiler.c
@@ -2199,6 +2199,9 @@ etna_emit_instr(struct etna_compile *c, nir_instr *instr)
    case nir_instr_type_load_const:
       /* Nothing to do */
       break;
+   case nir_instr_type_ssa_undef:
+      /* TODO: ssa_undef should be removed already */
+      break;
    default:
       BUG("Unhandled nir_instr: %d", instr->type);
       assert(0);
-- 
2.17.1



More information about the mesa-dev mailing list