r600/sfn: Lower FS pos input w-transform in NIR

Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10608>
This commit is contained in:
Gert Wollny 2021-04-30 20:12:19 +02:00
parent ba8d19ab80
commit 3b4b962c15
2 changed files with 1 additions and 2 deletions

View File

@ -892,6 +892,7 @@ int r600_shader_from_nir(struct r600_context *rctx,
NIR_PASS_V(sel->nir, r600_vectorize_vs_inputs);
if (sel->nir->info.stage == MESA_SHADER_FRAGMENT) {
NIR_PASS_V(sel->nir, nir_lower_fragcoord_wtrans);
NIR_PASS_V(sel->nir, r600_lower_fs_out_to_vector);
}

View File

@ -400,8 +400,6 @@ void FragmentShaderFromNir::emit_shader_start()
auto v = new GPRValue(m_frag_pos_index, i);
v->set_as_input();
auto reg = PValue(v);
if (i == 3)
emit_instruction(new AluInstruction(op1_recip_ieee, reg, reg, {alu_write, alu_last_instr}));
m_frag_pos[i] = reg;
}
}