mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-30 22:14:56 +00:00
Update translate.cpp
This commit is contained in:
parent
f9cc4ebd65
commit
d1f2250a20
@ -164,6 +164,8 @@ IR::U32F32 Translator::GetSrc(const InstOperand& operand, bool force_flt) {
|
|||||||
value = ir.GetVccHi();
|
value = ir.GetVccHi();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case OperandField::M0:
|
||||||
|
value = m0_value;
|
||||||
default:
|
default:
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
@ -327,7 +329,7 @@ void Translator::SetDst(const InstOperand& operand, const IR::U32F32& value) {
|
|||||||
if (operand.output_modifier.multiplier != 0.f) {
|
if (operand.output_modifier.multiplier != 0.f) {
|
||||||
result = ir.FPMul(result, ir.Imm32(operand.output_modifier.multiplier));
|
result = ir.FPMul(result, ir.Imm32(operand.output_modifier.multiplier));
|
||||||
}
|
}
|
||||||
if (operand.output_modifier.clamp) {
|
if (operand.output_modifier.clamp && value.Type() == IR::Type::F32) {
|
||||||
result = ir.FPSaturate(value);
|
result = ir.FPSaturate(value);
|
||||||
}
|
}
|
||||||
switch (operand.field) {
|
switch (operand.field) {
|
||||||
@ -340,7 +342,7 @@ void Translator::SetDst(const InstOperand& operand, const IR::U32F32& value) {
|
|||||||
case OperandField::VccHi:
|
case OperandField::VccHi:
|
||||||
return ir.SetVccHi(result);
|
return ir.SetVccHi(result);
|
||||||
case OperandField::M0:
|
case OperandField::M0:
|
||||||
break;
|
m0_value = result;
|
||||||
default:
|
default:
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user