summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReid Spencer <rspencer@reidspencer.com>2007-04-23 07:22:51 +0000
committerReid Spencer <rspencer@reidspencer.com>2007-04-23 07:22:51 +0000
commite2e9b37698a022e2f7d1ad4a7cb76891f0202d34 (patch)
treee75f02e7e297e5ac0df77e0d01b8f3f318730f5f
parentfe6e3f49b1cf335f30b9042a5b06e00f641d2c14 (diff)
downloadbcm5719-llvm-e2e9b37698a022e2f7d1ad4a7cb76891f0202d34.tar.gz
bcm5719-llvm-e2e9b37698a022e2f7d1ad4a7cb76891f0202d34.zip
Cygwin doesn't have the RSS_LIMIT for get/setrlimit.
llvm-svn: 36361
-rw-r--r--llvm/lib/System/Unix/Program.inc2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/System/Unix/Program.inc b/llvm/lib/System/Unix/Program.inc
index 77d74a18c67..1fe25861e1e 100644
--- a/llvm/lib/System/Unix/Program.inc
+++ b/llvm/lib/System/Unix/Program.inc
@@ -119,10 +119,12 @@ static void SetMemoryLimits (unsigned size)
getrlimit (RLIMIT_DATA, &r);
r.rlim_cur = limit;
setrlimit (RLIMIT_DATA, &r);
+#ifndef __CYGWIN__
// Resident set size.
getrlimit (RLIMIT_RSS, &r);
r.rlim_cur = limit;
setrlimit (RLIMIT_RSS, &r);
+#endif
// Virtual memory.
getrlimit (RLIMIT_AS, &r);
r.rlim_cur = limit;
OpenPOWER on IntegriCloud