Re: SBCL Memory Tuning
- From: Ondrej Svitek <ondrej.svitek@xxxxxxxxx>
- Date: Sun, 17 Jun 2007 10:41:57 -0000
On Jun 16, 7:15 pm, Robert Uhl <eadmun...@xxxxxxxxxxxxxxx> wrote:
Anyone have any advice or tools for examining SBCL's memory usage?
I think pmap would be of interest for you, e.g.:
ondrej@snowcrash:~$ pmap `pidof sbcl`
5874: sbcl
01000000 4K rwx-- /usr/local/lib/sbcl/sbcl.core
01001000 40952K rwx-- [ anon ]
05000000 4K rwx-- /usr/local/lib/sbcl/sbcl.core
05001000 49144K rwx-- [ anon ]
...
b8000000 8K rwx-- /lib/ld-2.5.so
bffeb000 84K rwx-- [ stack ]
ffffe000 4K r-x-- [ anon ]
total 885248K
But as stated above, you usually don't have to worry about this
overcommitting scheme. (Almost) all memory pages are allocated with
MAP_NORESERVE flag and application "claims" space upon writing to
them. Or get a SIGSEGV, when low on free memory.
One issue, where this matters, is when you have limited virtual memory
usage by some means (e.g. RLIMIT) to a low value, say 256MB. In this
scenario SBCL won't succeed to "allocate" desired memory regions and
will fail to start (at least, this is what happens on Linux).
Depending on circumstances, you could get away with setting --dynamic-
space-usage option to some low value, but more likely, you'd have to
resort to tampering with address space layout in src/compiler/*/
parms.lisp and recompiling SBCL.
This file can also give you an insight on pmap output (look for
various -space-start, -space-end constants).
.
- Follow-Ups:
- Re: SBCL Memory Tuning
- From: Juho Snellman
- Re: SBCL Memory Tuning
- References:
- SBCL Memory Tuning
- From: Robert Uhl
- SBCL Memory Tuning
- Prev by Date: Re: A problem statement (and a proposed solution)
- Next by Date: Re: A problem statement (and a proposed solution)
- Previous by thread: Re: SBCL Memory Tuning
- Next by thread: Re: SBCL Memory Tuning
- Index(es):
Relevant Pages
|