shader: implement RDNA2 V_MED3_I16

This commit is contained in:
nmzik
2026-08-16 23:22:28 +02:00
parent 6b306f64d5
commit 44302cbf96
7 changed files with 84 additions and 23 deletions
@@ -32,6 +32,11 @@ bool Translator::TranslateInteger16Operation(const IR::Instruction& inst) {
case IR::Opcode::ISubI16:
result = ir.ISub(ReadU16AsU32(inst.src[0], false), ReadU16AsU32(inst.src[1], false));
break;
case IR::Opcode::IMed3I16:
result = ir.Emit(IR::ValueOpcode::SMedTri32,
{ReadU16AsU32(inst.src[0], true), ReadU16AsU32(inst.src[1], true),
ReadU16AsU32(inst.src[2], true)});
break;
case IR::Opcode::IMinI16:
case IR::Opcode::IMaxI16:
case IR::Opcode::UMinU16: