mirror of
https://github.com/FEX-Emu/FEX.git
synced 2026-10-14 16:00:44 +02:00
OpcodeDispatcher: Fixes nop encoded prefetch instruction
We had a bug where nop encoded prefetch instructions were getting flagged as illegal instructions erroneously. Fix that and add a unittest for ensuring execution. Fixes `Devil May Cry 4`
This commit is contained in:
3 files changed
+37
-16
No files matched your search
@@ -4889,6 +4889,11 @@ void OpDispatchBuilder::CLZeroOp(OpcodeArgs) {
|
||||
}
|
||||
|
||||
void OpDispatchBuilder::Prefetch(OpcodeArgs, bool ForStore, bool Stream, uint8_t Level) {
|
||||
if (Op->Src[0].IsGPR()) {
|
||||
// NOP instance.
|
||||
return;
|
||||
}
|
||||
|
||||
Ref DestMem = LoadSourceGPR(Op, Op->Src[0], Op->Flags, {.LoadData = false});
|
||||
_Prefetch(ForStore, Stream, Level, DestMem, Invalid(), MemOffsetType::SXTX, 1);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user