nak/legalize: Drop some pointless plop3 logic

There is no restrictions on plop3 in terms of what sources can be
immediates vs. registers.  Also, since we fold constants, all of this
code is dead.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/29591>
This commit is contained in:
Faith Ekstrand 2024-05-28 17:02:33 -05:00 committed by Marge Bot
parent 37b55ee34f
commit c1203ef5d1

View file

@ -725,23 +725,6 @@ fn legalize_sm70_instr(
src.src_ref = SrcRef::True;
}
}
let [ref mut src0, ref mut src1, ref mut src2] = op.srcs;
if !src_is_reg(src0) && src_is_reg(src1) {
std::mem::swap(src0, src1);
for lop in &mut op.ops {
*lop = LogicOp3::new_lut(&|x, y, z| lop.eval(y, x, z));
}
}
if !src_is_reg(src2) && src_is_reg(src1) {
std::mem::swap(src2, src1);
for lop in &mut op.ops {
*lop = LogicOp3::new_lut(&|x, y, z| lop.eval(x, z, y));
}
}
copy_alu_src_if_not_reg(b, src0, SrcType::Pred);
copy_alu_src_if_not_reg(b, src2, SrcType::Pred);
}
Op::FSwzAdd(op) => {
let [ref mut src0, ref mut src1] = op.srcs;