Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
From: patchkov@acs1.acs.ucalgary.ca (Serguei Patchkovskii)
Subject: Re: memory limits
Date: 2000/02/09	[thread overview]
Message-ID: <87sd39$ojg$2@nserve1.acs.ucalgary.ca> (raw)
In-Reply-To: 38A01DEB.B957E36A@mimosa.ceng.cea.fr

Philippe Blaise (phblai@mimosa.ceng.cea.fr) wrote:
: I thought it was not possible to adress more than
: memoryuse       1032192 kbytes
: but a simple program can allocate more :

I believe that csh 'memoryuse' limit corresponds to RLIMIT_RSS
in getrlimit/setrlimit system calls. Now, looking at the manual
page for setrlimit(2), we see:

      RLIMIT_RSS
          [Digital]  The maximum size, in bytes, to which a process's
          resident set size can grow.  This value imposes a limit on the
          amount of physical memory to be given to a process.  If memory is
          in short supply, the system prefers to take memory from processes
          that are exceeding their declared resident set size.

As you can see, this limit applies only in constrained memory
situations, and controls the amount of physical memory your
process can use - provided that there are other ways in which
it can be used by the system. Therefore, calling RLIMIT_RSS a
"limit" is a bit of misnomer - your process may well be able
to use more memory (if system has no other use for it), or it
may be stuck with less memory (if there are higher-priority 
uses for that memory). I'd rather call RLIMIT_RSS a hint, made 
by your application to the virtual memory subsystem, saying
that you'd *like* to have that much real memory to work optimally ...

Cheers,

/Serge.P

P.S. RTFM - it usually helps!

--
home page: http://www.cobalt.chem.ucalgary.ca/ps/



  parent reply	other threads:[~2000-02-09  5:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-02-08  5:00 memory limits Philippe Blaise
2000-02-09  5:00 ` Aurel Balmosan
2000-02-09  5:00 ` Serguei Patchkovskii [this message]
2000-02-10  5:00   ` Philippe Blaise
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox