12 GiB heap support

The heap was limited to 6 GiB no matter the memory setting, causing memory configurations above 8 GiB to not actually affect the heap size.

Now when the memory config is set to [10 or] 12 GiB the heap also allocates 12 GiB.

The SetHeapSize SysCall will now allow heap sizes up to 12 GiB (technically slightly less).

Co-authored-by: KeatonTheBot <keaton@ryujinx.app>
This commit is contained in:
LotP
2025-10-15 21:49:11 -05:00
committed by KeatonTheBot
co-authored by KeatonTheBot
parent f5822c16af
commit 42727fca07
5 changed files with 27 additions and 5 deletions
@@ -137,6 +137,7 @@ namespace Ryujinx.HLE.HOS.Kernel.SupervisorCall
capabilities,
resourceLimit,
memRegion,
_context.Device.Configuration.MemoryConfiguration,
contextFactory,
customThreadStart);
@@ -880,7 +881,7 @@ namespace Ryujinx.HLE.HOS.Kernel.SupervisorCall
[Svc(1)]
public Result SetHeapSize([PointerSized] out ulong address, [PointerSized] ulong size)
{
if ((size & 0xfffffffe001fffff) != 0)
if ((size & 0xfffffffd001fffff) != 0)
{
address = 0;