memory leak on solaris 2.5.1 / 2.6 ?
Wolfgang.Grafen at marconicomms.com
Wed May 31 12:49:33 EDT 2000
William Annis wrote:
> akuchlin at mems-exchange.org (Andrew M. Kuchling) writes:
> > Wolfgang Grafen <Wolfgang.Grafen at marconicomms.com> writes:
> > > >>> x = "1001" * 5000000
> > > will occupy about 22 MB.
> > > >>> del x
> > > doesn't decrease the amount of allocated Memory.
> > >
> > > With Suse-Linux the memory will be properly freed on a Intel PC and
> > > a pre-compiled Python 1.5.2 version.
> > This is probably because of the different malloc() implementations on
> > the two platforms. When the request is for a large area of memory,
> > Linux malloc() will use mmap() to allocate it for just this reason; on
> > freeing the memory the process size will shrink when the memory region
> > is unmapped. Solaris malloc() probably doesn't do this; this theory
> > could be confirmed,
> Right. Solaris assumes that if you ask for a chunk of memory,
> you are probably going to ask for it again later, even after a free().
What is it for? After consuming the fast silicon main memory the
process slows extremely down when swapping to disk although
it could demand freed memory!
More information about the Python-list