diff --git a/src/Ryujinx.Cpu/LightningJit/Cache/NoWxCache.cs b/src/Ryujinx.Cpu/LightningJit/Cache/NoWxCache.cs index 0a78d7a5f..a71074995 100644 --- a/src/Ryujinx.Cpu/LightningJit/Cache/NoWxCache.cs +++ b/src/Ryujinx.Cpu/LightningJit/Cache/NoWxCache.cs @@ -11,7 +11,7 @@ namespace Ryujinx.Cpu.LightningJit.Cache { private const int CodeAlignment = 4; // Bytes. private const int SharedCacheSize = 2047 * 1024 * 1024; - private const int LocalCacheSize = 256 * 1024 * 1024; + private const int LocalCacheSize = 128 * 1024 * 1024; // How many calls to the same function we allow until we pad the shared cache to force the function to become available there // and allow the guest to take the fast path. @@ -149,7 +149,7 @@ namespace Ryujinx.Cpu.LightningJit.Cache lock (_lock) { - if (!_pendingMap.Has(guestAddress)) + if (!_pendingMap.Has(guestAddress) && !_translator.Functions.ContainsKey(guestAddress)) { int funcOffset = _sharedCache.Allocate(code.Length);