mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2025-07-02 15:00:47 -07:00
Apply suggestions from code review
Address gdkchan's feedback Co-authored-by: gdkchan <gab.dark.100@gmail.com>
This commit is contained in:
@ -540,8 +540,11 @@ namespace ARMeilleure.Translation.PTC
|
||||
}
|
||||
}
|
||||
|
||||
internal static void LoadTranslations(ConcurrentDictionary<ulong, TranslatedFunction> funcs, IMemoryManager memory,
|
||||
JumpTable jumpTable, EntryTable<uint> countTable)
|
||||
internal static void LoadTranslations(
|
||||
ConcurrentDictionary<ulong, TranslatedFunction> funcs,
|
||||
IMemoryManager memory,
|
||||
JumpTable jumpTable,
|
||||
EntryTable<uint> countTable)
|
||||
{
|
||||
if (AreCarriersEmpty())
|
||||
{
|
||||
@ -680,8 +683,13 @@ namespace ARMeilleure.Translation.PTC
|
||||
return relocEntries;
|
||||
}
|
||||
|
||||
private static bool PatchCode(Span<byte> code, RelocEntry[] relocEntries, IntPtr pageTablePointer,
|
||||
JumpTable jumpTable, EntryTable<uint> countTable, out Counter<uint> callCounter)
|
||||
private static bool PatchCode(
|
||||
Span<byte> code,
|
||||
RelocEntry[] relocEntries,
|
||||
IntPtr pageTablePointer,
|
||||
JumpTable jumpTable,
|
||||
EntryTable<uint> countTable,
|
||||
out Counter<uint> callCounter)
|
||||
{
|
||||
callCounter = null;
|
||||
|
||||
@ -747,8 +755,12 @@ namespace ARMeilleure.Translation.PTC
|
||||
return new UnwindInfo(pushEntries, prologueSize);
|
||||
}
|
||||
|
||||
private static TranslatedFunction FastTranslate(byte[] code, Counter<uint> callCounter, ulong guestSize,
|
||||
UnwindInfo unwindInfo, bool highCq)
|
||||
private static TranslatedFunction FastTranslate(
|
||||
byte[] code,
|
||||
Counter<uint> callCounter,
|
||||
ulong guestSize,
|
||||
UnwindInfo unwindInfo,
|
||||
bool highCq)
|
||||
{
|
||||
CompiledFunction cFunc = new CompiledFunction(code, unwindInfo);
|
||||
|
||||
@ -797,8 +809,11 @@ namespace ARMeilleure.Translation.PTC
|
||||
}
|
||||
}
|
||||
|
||||
internal static void MakeAndSaveTranslations(ConcurrentDictionary<ulong, TranslatedFunction> funcs, IMemoryManager memory,
|
||||
JumpTable jumpTable, EntryTable<uint> countTable)
|
||||
internal static void MakeAndSaveTranslations(
|
||||
ConcurrentDictionary<ulong, TranslatedFunction> funcs,
|
||||
IMemoryManager memory,
|
||||
JumpTable jumpTable,
|
||||
EntryTable<uint> countTable)
|
||||
{
|
||||
var profiledFuncsToTranslate = PtcProfiler.GetProfiledFuncsToTranslate(funcs);
|
||||
|
||||
@ -1085,4 +1100,4 @@ namespace ARMeilleure.Translation.PTC
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user