summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2019-09-22 18:31:09 -0700
committerGitHub <noreply@github.com>2019-09-22 18:31:09 -0700
commit281a383d913e7b6013068ec430fc21cf81f43350 (patch)
treea26e240be911f5b47d8a1cf0c3e3bb326aaf3a51 /src
parent0fca8289590b2eb45511345232f67e38118ba1e8 (diff)
downloadcoreclr-281a383d913e7b6013068ec430fc21cf81f43350.tar.gz
coreclr-281a383d913e7b6013068ec430fc21cf81f43350.tar.bz2
coreclr-281a383d913e7b6013068ec430fc21cf81f43350.zip
Do not clip CPU count when CPU quota is used. (#26153) (#26806)
Diffstat (limited to 'src')
-rw-r--r--src/classlibnative/bcltype/system.cpp7
-rw-r--r--src/pal/src/thread/process.cpp6
-rw-r--r--src/utilcode/util.cpp4
3 files changed, 0 insertions, 17 deletions
diff --git a/src/classlibnative/bcltype/system.cpp b/src/classlibnative/bcltype/system.cpp
index 18621145cf..402a215e9f 100644
--- a/src/classlibnative/bcltype/system.cpp
+++ b/src/classlibnative/bcltype/system.cpp
@@ -352,13 +352,6 @@ INT32 QCALLTYPE SystemNative::GetProcessorCount()
processorCount = systemInfo.dwNumberOfProcessors;
}
-#ifdef FEATURE_PAL
- uint32_t cpuLimit;
-
- if (PAL_GetCpuLimit(&cpuLimit) && cpuLimit < (uint32_t)processorCount)
- processorCount = cpuLimit;
-#endif
-
END_QCALL;
return processorCount;
diff --git a/src/pal/src/thread/process.cpp b/src/pal/src/thread/process.cpp
index 1ce2cda59f..4f9d318bef 100644
--- a/src/pal/src/thread/process.cpp
+++ b/src/pal/src/thread/process.cpp
@@ -2558,12 +2558,6 @@ PAL_GetCPUBusyTime(
{
return 0;
}
-
- UINT cpuLimit;
- if (PAL_GetCpuLimit(&cpuLimit) && cpuLimit < dwNumberOfProcessors)
- {
- dwNumberOfProcessors = cpuLimit;
- }
}
if (getrusage(RUSAGE_SELF, &resUsage) == -1)
diff --git a/src/utilcode/util.cpp b/src/utilcode/util.cpp
index 8f62d53f95..e0f0200076 100644
--- a/src/utilcode/util.cpp
+++ b/src/utilcode/util.cpp
@@ -1289,10 +1289,6 @@ int GetCurrentProcessCpuCount()
#else // !FEATURE_PAL
count = PAL_GetLogicalCpuCountFromOS();
-
- uint32_t cpuLimit;
- if (PAL_GetCpuLimit(&cpuLimit) && cpuLimit < count)
- count = cpuLimit;
#endif // !FEATURE_PAL
cCPUs = count;