mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2025-06-30 05:20:47 -07:00
PPTC & Pool Enhancements. (#1968)
* PPTC & Pool Enhancements.
* Avoid buffer allocations in CodeGenContext.GetCode(). Avoid stream allocations in PTC.PtcInfo.
Refactoring/nits.
* Use XXHash128, for Ptc.Load & Ptc.Save, x10 faster than Md5.
* Why not a nice Span.
* Added a simple PtcFormatter library for deserialization/serialization, which does not require reflection, in use at PtcJumpTable and PtcProfiler; improves maintainability and simplicity/readability of affected code.
* Nits.
* Revert #1987.
* Revert "Revert #1987."
This reverts commit 998be765cf
.
This commit is contained in:
@ -29,11 +29,17 @@ namespace ARMeilleure.Translation
|
||||
{
|
||||
if (_initialized) return;
|
||||
|
||||
Translator.PreparePool();
|
||||
|
||||
_directCallStubPtr = Marshal.GetFunctionPointerForDelegate<GuestFunction>(GenerateDirectCallStub(false));
|
||||
_directTailCallStubPtr = Marshal.GetFunctionPointerForDelegate<GuestFunction>(GenerateDirectCallStub(true));
|
||||
_indirectCallStubPtr = Marshal.GetFunctionPointerForDelegate<GuestFunction>(GenerateIndirectCallStub(false));
|
||||
_indirectTailCallStubPtr = Marshal.GetFunctionPointerForDelegate<GuestFunction>(GenerateIndirectCallStub(true));
|
||||
|
||||
Translator.ResetPool();
|
||||
|
||||
Translator.DisposePools();
|
||||
|
||||
_initialized = true;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user