コード例 #1
0
ファイル: gc.cs プロジェクト: wwkkww1983/ZJCredit
 public static void RemoveMemoryPressure(long bytesAllocated)
 {
     if (bytesAllocated <= 0L)
     {
         throw new ArgumentOutOfRangeException("bytesAllocated", Environment.GetResourceString("ArgumentOutOfRange_NeedPosNum"));
     }
     if (4 == IntPtr.Size && bytesAllocated > (long)int.MaxValue)
     {
         throw new ArgumentOutOfRangeException("bytesAllocated", Environment.GetResourceString("ArgumentOutOfRange_MustBeNonNegInt32"));
     }
     GC._RemoveMemoryPressure((ulong)bytesAllocated);
 }