mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-06-01 12:15:43 -06:00
Handle -1 as V_CMP_NE_U64 argument (#2919)
Some checks are pending
Build and Release / reuse (push) Waiting to run
Build and Release / clang-format (push) Waiting to run
Build and Release / get-info (push) Waiting to run
Build and Release / windows-sdl (push) Blocked by required conditions
Build and Release / windows-qt (push) Blocked by required conditions
Build and Release / macos-sdl (push) Blocked by required conditions
Build and Release / macos-qt (push) Blocked by required conditions
Build and Release / linux-sdl (push) Blocked by required conditions
Build and Release / linux-qt (push) Blocked by required conditions
Build and Release / linux-sdl-gcc (push) Blocked by required conditions
Build and Release / linux-qt-gcc (push) Blocked by required conditions
Build and Release / pre-release (push) Blocked by required conditions
Some checks are pending
Build and Release / reuse (push) Waiting to run
Build and Release / clang-format (push) Waiting to run
Build and Release / get-info (push) Waiting to run
Build and Release / windows-sdl (push) Blocked by required conditions
Build and Release / windows-qt (push) Blocked by required conditions
Build and Release / macos-sdl (push) Blocked by required conditions
Build and Release / macos-qt (push) Blocked by required conditions
Build and Release / linux-sdl (push) Blocked by required conditions
Build and Release / linux-qt (push) Blocked by required conditions
Build and Release / linux-sdl-gcc (push) Blocked by required conditions
Build and Release / linux-qt-gcc (push) Blocked by required conditions
Build and Release / pre-release (push) Blocked by required conditions
This commit is contained in:
parent
7334fb620b
commit
484fbcc320
@ -989,13 +989,22 @@ void Translator::V_CMP_NE_U64(const GcnInst& inst) {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
const IR::U1 src0{get_src(inst.src[0])};
|
const IR::U1 src0{get_src(inst.src[0])};
|
||||||
ASSERT(inst.src[1].field == OperandField::ConstZero); // src0 != 0
|
auto op = [&inst, this](auto x) {
|
||||||
|
switch (inst.src[1].field) {
|
||||||
|
case OperandField::ConstZero:
|
||||||
|
return x;
|
||||||
|
case OperandField::SignedConstIntNeg:
|
||||||
|
return ir.LogicalNot(x);
|
||||||
|
default:
|
||||||
|
UNREACHABLE_MSG("unhandled V_CMP_NE_U64 source argument {}", u32(inst.src[1].field));
|
||||||
|
}
|
||||||
|
};
|
||||||
switch (inst.dst[1].field) {
|
switch (inst.dst[1].field) {
|
||||||
case OperandField::VccLo:
|
case OperandField::VccLo:
|
||||||
ir.SetVcc(src0);
|
ir.SetVcc(op(src0));
|
||||||
break;
|
break;
|
||||||
case OperandField::ScalarGPR:
|
case OperandField::ScalarGPR:
|
||||||
ir.SetThreadBitScalarReg(IR::ScalarReg(inst.dst[1].code), src0);
|
ir.SetThreadBitScalarReg(IR::ScalarReg(inst.dst[1].code), op(src0));
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user