0

这些刷新内存功能有什么区别?
哪个更好(工作安全且没有问题)?多谢。

    public static void FlushMemoryFirst()
    {
        System.Diagnostics.Process prs = System.Diagnostics.Process.GetCurrentProcess();
        try { prs.MinWorkingSet = (IntPtr)(300000); }
        catch { }
    }
    public static void FlushMemorySecond()
    {
        System.Diagnostics.Process prs = System.Diagnostics.Process.GetCurrentProcess();
        try { prs.MaxWorkingSet = (IntPtr)((int)(prs.MaxWorkingSet + 1)); }
        catch { }
    }
4

0 回答 0