Merge pull request #18560 from unknownbrackets/replacement-slice

HLE: Slice the very slow memset/memcpy variants
This commit is contained in:
Henrik Rydgård authored and GitHub committed 2023-12-17 12:35:48 +01:00
commit e5af1f8bd0
12 files changed
+132 -23

No files matched your search

+10 -1
View File
@@ -242,7 +242,16 @@ void Arm64JitBackend::CompIR_System(IRInst inst) {
QuickCallFunction(SCRATCH2_64, GetReplacementFunc(inst.constant)->replaceFunc);
WriteDebugProfilerStatus(IRProfilerStatus::IN_JIT);
LoadStaticRegisters();
SUB(DOWNCOUNTREG, DOWNCOUNTREG, W0);
// Absolute value the result and subtract.
CMP(W0, 0);
CSNEG(SCRATCH1, W0, W0, CC_PL);
SUB(DOWNCOUNTREG, DOWNCOUNTREG, SCRATCH1);
// W0 might be the mapped reg, but there's only one.
// Set dest reg to the sign of the result.
regs_.Map(inst);
ASR(regs_.R(inst.dest), W0, 31);
break;
case IROp::Break: