/ src / Ryujinx.HLE / HOS / Kernel / Memory / KMemoryBlockSlabManager.cs
KMemoryBlockSlabManager.cs
 1  namespace Ryujinx.HLE.HOS.Kernel.Memory
 2  {
 3      class KMemoryBlockSlabManager
 4      {
 5          private readonly ulong _capacityElements;
 6  
 7          public int Count { get; set; }
 8  
 9          public KMemoryBlockSlabManager(ulong capacityElements)
10          {
11              _capacityElements = capacityElements;
12          }
13  
14          public bool CanAllocate(int count)
15          {
16              return (ulong)(Count + count) <= _capacityElements;
17          }
18      }
19  }