From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103734,27179c3b815f2f49 X-Google-Attributes: gid103734,public X-Google-Thread: 1164f8,27179c3b815f2f49 X-Google-Attributes: gid1164f8,public X-Google-Thread: fee84,27179c3b815f2f49 X-Google-Attributes: gidfee84,public X-Google-ArrivalTime: 1994-08-30 09:50:10 PST Path: bga.com!news.sprintlink.net!redstone.interpath.net!ddsw1!panix!MathWorks.Com!yeshua.marcam.com!charnel.ecst.csuchico.edu!olivea!decwrl!pa.dec.com!crl.dec.com!jac.zko.dec.com!lueck From: lueck@gurgi.zk3.dec.com (Greg Lueck Development Environment) Newsgroups: comp.windows.x,comp.unix.osf.osf1,comp.sys.dec Subject: Re: Alpha OSF1/2.0 server problem Date: 30 Aug 1994 16:27:47 GMT Organization: Digital Equipment Corporation Distribution: world Message-ID: <33vmm3$mh6@jac.zko.dec.com> References: <33mb0k$gg1@sundog.tiac.net> <33p02t$j5c@nyheter.chalmers.se> Reply-To: lueck@zk3.dec.com (Greg Lueck Development Environment) NNTP-Posting-Host: gurgi.zk3.dec.com X-Newsreader: mxrn 6.18-5 Xref: bga.com comp.windows.x:10982 comp.unix.osf.osf1:3276 comp.sys.dec:5553 In article , 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 -------------------------------------------------------------------------------