summaryrefslogtreecommitdiff
path: root/src/vm/gcenv.os.cpp
diff options
context:
space:
mode:
authorTom Deseyn <tom.deseyn@gmail.com>2018-08-16 20:47:20 +0200
committerJan Vorlicek <janvorli@microsoft.com>2018-08-16 20:47:20 +0200
commitca5b0d1caa47abdebac13233553c6e44db2e3168 (patch)
treec799ed2aad140fce723ad9a0796c12ae994c90ca /src/vm/gcenv.os.cpp
parent6a2ce4748f043d8c0dc9e4d30d415cffbef1958f (diff)
downloadcoreclr-ca5b0d1caa47abdebac13233553c6e44db2e3168.tar.gz
coreclr-ca5b0d1caa47abdebac13233553c6e44db2e3168.tar.bz2
coreclr-ca5b0d1caa47abdebac13233553c6e44db2e3168.zip
Determine memory load based on cgroup usage. (#19518)
cgroup usage is used to trigger oom kills. It includes rss and file cache of the cgroup. The implementation was only using the process rss to determine memory load. This is less than the cgroup usage and leads to oom kills due to GC not being triggered soon enough.
Diffstat (limited to 'src/vm/gcenv.os.cpp')
-rw-r--r--src/vm/gcenv.os.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vm/gcenv.os.cpp b/src/vm/gcenv.os.cpp
index 70dc2619dd..99e9ff6c72 100644
--- a/src/vm/gcenv.os.cpp
+++ b/src/vm/gcenv.os.cpp
@@ -605,7 +605,7 @@ void GCToOSInterface::GetMemoryStatus(uint32_t* memory_load, uint64_t* available
workingSetSize = pmc.WorkingSetSize;
}
#else
- status = PAL_GetWorkingSetSize(&workingSetSize);
+ status = PAL_GetPhysicalMemoryUsed(&workingSetSize);
#endif
if(status)
{