Skip to content

nir: Prefer SSA-based source rewriting

Alyssa Rosenzweig requested to merge alyssa/mesa:nir/coccinelle-helpers into main

Now that there are no registers around this should be safe.

Via Coccinelle patch:

@@
expression instr, src, ssa;
@@

-nir_instr_rewrite_src_ssa(instr, src, ssa)
+nir_src_rewrite_ssa(src, ssa)

@@
expression instr, src, ssa;
@@

-nir_instr_rewrite_src(instr, src, nir_src_for_ssa(ssa))
+nir_src_rewrite_ssa(src, ssa)

@@
expression nif, src, ssa;
@@

-nir_if_rewrite_condition(nif, nir_src_for_ssa(ssa))
+nir_src_rewrite_ssa(&nif->condition, ssa)

Signed-off-by: Alyssa Rosenzweig alyssa@rosenzweig.io

Merge request reports

Loading