Replace 'Expand DRAM' option with dropdown menu (#32)

Allows to use mods that require a larger memory pool to allocate from.
This commit is contained in:
Keaton
2024-10-21 23:16:41 -05:00
committed by GitHub
parent 0f3c7f920b
commit f76a97c976
54 changed files with 416 additions and 118 deletions

View File

@ -7,10 +7,10 @@ namespace Ryujinx.Common
public static T AlignUp<T>(T value, T size) where T : IBinaryInteger<T>
=> (value + (size - T.One)) & -size;
public static T AlignDown<T>(T value, T size) where T : IBinaryInteger<T>
public static T AlignDown<T>(T value, T size) where T : IBinaryInteger<T>
=> value & -size;
public static T DivRoundUp<T>(T value, T dividend) where T : IBinaryInteger<T>
public static T DivRoundUp<T>(T value, T dividend) where T : IBinaryInteger<T>
=> (value + (dividend - T.One)) / dividend;
public static int Pow2RoundDown(int value) => BitOperations.IsPow2(value) ? value : Pow2RoundUp(value) >> 1;