Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: lueck@gurgi.zk3.dec.com (Greg Lueck Development Environment)
Subject: Re: Alpha OSF1/2.0 server problem
Date: 30 Aug 1994 16:27:47 GMT	[thread overview]
Message-ID: <33vmm3$mh6@jac.zko.dec.com> (raw)
In-Reply-To: CvAsAB.9tE@world.std.com


In article <CvAsAB.9tE@world.std.com>, gnewman@world.std.com (Gary Newman) writes:
|> Actually, the problem is that "malloc" uses the "sbrk" call to extend
|> memory, and that cannot be undone to free the memory later.  A better
|> method would be to use "mmap" to add memory segments as needed, but
|> this would require a different malloc.
|> 
|> I don't know why there isn't a better malloc out there that uses mmap.
|> Anyone know?

Actually, "sbrk" can be used to return memory to the system.  Passing a
negative value to "sbrk" reduces the virtual size of the process.  Thus, "free"
can return memory to the system when that memory is at the end of the process's
heap.  The malloc system in DEC OSF/1 V3.0 supports this feature and even
allows applications to tune the behavior.  See the malloc() manpage for more
details if you are interested.

-- 
-------------------------------------------------------------------------------
Greg Lueck                              Opinions expressed herein are my own.
lueck@zk3.dec.com
-------------------------------------------------------------------------------
-- 
-------------------------------------------------------------------------------
Greg Lueck                              Opinions expressed herein are my own.
lueck@zk3.dec.com
-------------------------------------------------------------------------------


  reply	other threads:[~1994-08-30 16:27 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1994-08-27  3:13 Alpha OSF1/2.0 server problem David Scarbro
1994-08-28  3:25 ` Torbj|rn Lindgren
1994-08-29 13:03   ` Gary Newman
1994-08-30 16:27     ` Greg Lueck Development Environment [this message]
1994-08-30 23:00       ` David Scarbro
1994-09-01 18:08   ` Andre Beck
1994-09-01 18:42     ` AUSTIN PARK stefanovich boris
1994-09-02  7:42     ` Alpha OSF1/2.0 server problem Burkhard Neidecker-Lutz
1994-09-07 16:41       ` Andre Beck
1994-09-08 15:09         ` Greg Lueck Development Environment
1994-09-07 20:39     ` Shawn C. Masters
1994-09-08 13:09       ` Paul Southworth
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