Idle curiosity...
I'm looking at some of the properties of the current process:
using(Process p = Process.GetCurrentProcess())
{
// Inspect properties
// p.MaxWorkingSet = 1,413,120
// p.MinWorkingSet = 204,800
// p.WorkingSet = 54,140,928
// p.WorkingSet64 = 54,140,928
}
From my reading of the documentation, these properties are all related to the working set size in bytes, hence I was expecting to see:
MinWorkingSet <= WorkingSet <= MaxWorkingSet
This is not the case, can anyone explain why?
MaxWorkingSet and MinWorkingSet are the values returned by the Win32 API GetProcessWorkingSetSize. These are limits used by the virtual manager that will be enforced when the memory is in short supply. As long as enough memory is available, the current working set size is allowed to grow larger than the value in MaxWorkingSet.