Prevent log from showing negative JIT cache sizes (32bit-int overflow) (#664)

![image](https://github.com/user-attachments/assets/5820ce7b-cbfe-4908-8f5e-7ee82040ee1a)
This commit is contained in:
FluffyOMC 2025-02-14 22:37:19 -05:00 committed by GitHub
parent 6b55d158b7
commit 855161b23b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 5 additions and 5 deletions

View File

@ -186,7 +186,7 @@ namespace ARMeilleure.Translation.Cache
int newRegionNumber = _activeRegionIndex; int newRegionNumber = _activeRegionIndex;
Logger.Warning?.Print(LogClass.Cpu, $"JIT Cache Region {exhaustedRegion} exhausted, creating new Cache Region {newRegionNumber} ({((newRegionNumber + 1) * CacheSize).Bytes()} Total Allocation)."); Logger.Warning?.Print(LogClass.Cpu, $"JIT Cache Region {exhaustedRegion} exhausted, creating new Cache Region {newRegionNumber} ({((long)(newRegionNumber + 1) * CacheSize).Bytes()} Total Allocation).");
_cacheAllocator = new CacheMemoryAllocator(CacheSize); _cacheAllocator = new CacheMemoryAllocator(CacheSize);

View File

@ -166,7 +166,7 @@ namespace Ryujinx.Cpu.LightningJit.Cache
int newRegionNumber = _activeRegionIndex; int newRegionNumber = _activeRegionIndex;
Logger.Warning?.Print(LogClass.Cpu, $"JIT Cache Region {exhaustedRegion} exhausted, creating new Cache Region {newRegionNumber} ({((newRegionNumber + 1) * CacheSize).Bytes()} Total Allocation)."); Logger.Warning?.Print(LogClass.Cpu, $"JIT Cache Region {exhaustedRegion} exhausted, creating new Cache Region {newRegionNumber} ({((long)(newRegionNumber + 1) * CacheSize).Bytes()} Total Allocation).");
_cacheAllocator = new CacheMemoryAllocator(CacheSize); _cacheAllocator = new CacheMemoryAllocator(CacheSize);

View File

@ -4621,7 +4621,7 @@
"zh_CN": "繁体中文(推荐)", "zh_CN": "繁体中文(推荐)",
"zh_TW": "正體中文 (建議)" "zh_TW": "正體中文 (建議)"
} }
}, },
{ {
"ID": "SettingsTabSystemSystemLanguageSwedish", "ID": "SettingsTabSystemSystemLanguageSwedish",
"Translations": { "Translations": {
@ -4646,7 +4646,7 @@
"zh_CN": "瑞典语", "zh_CN": "瑞典语",
"zh_TW": "" "zh_TW": ""
} }
}, },
{ {
"ID": "SettingsTabSystemSystemLanguageNorwegian", "ID": "SettingsTabSystemSystemLanguageNorwegian",
"Translations": { "Translations": {
@ -24073,4 +24073,4 @@
} }
} }
] ]
} }