home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!spool.mu.edu!darwin.sura.net!sgiblab!nec-gw!nec-tyo!wnoc-tyo-news!scslwide!wsgw!wsservra!daemon
- From: matt@centerline.com (Matt Landau)
- Newsgroups: fj.mail-lists.x-window
- Subject: Re: FLAME, FLAME ON X!!!
- Message-ID: <1992Nov16.094034.10647@sm.sony.co.jp>
- Date: 16 Nov 92 09:40:34 GMT
- Sender: daemon@sm.sony.co.jp (The devil himself)
- Distribution: fj
- Organization: CenterLine Software, Inc.
- Lines: 43
- Approved: michael@sm.sony.co.jp
-
- Date: 10 Nov 92 00:56:39 GMT
- Message-Id: <1dn1c7INNcnp@armory.centerline.com>
- Newsgroups: comp.windows.x
- References: <1683@igd.fhg.de>, <1992Nov9.235741.25166@dsd.es.com>
- Sender: xpert-request@expo.lcs.mit.edu
-
- In <1992Nov9.235741.25166@dsd.es.com> pmartz@dsd.es.com (Paul Martz) writes:
- >In article <1683@igd.fhg.de>, baumann@igd.fhg.de (Peter Baumann) writes:
- >> [ ... ]
- >>
- >> Short after that, a colleague of the bad-luck guy occasionally
- >> remarked, "Did you know that the X windows server never releases
- >> memory space once acquired for image display? Each new image loaded
- >> makes the X server address space grow until there's no more available."
- >> And added, "This is a well-known bug of X". Well-known. Well...
-
- >Care to tell us in which vendor's X is this a bug? I've certainly
- >never heard of it before.
-
- This sounds like a third-hand version of the oft-heard complaint that
- most X11 servers will never release memory *back to the operating system*;
- i.e., that once the X server has allocated a huge chunk of memory for,
- say, an image, that memory will never be made available to any other
- application running on the same system.
-
- This is, in fact, generally true, but it has nothing at all to do with
- the X server. It's simply an artifact of the fact that most versions
- of *free* don't return memory to the O/S, they simply stick it back on
- the free list for subsequent allocation from within the same process.
-
- The X server merely exhibits the same behavior as any other program using
- the standard malloc/free storage allocator. It's true, however, that
- such behavior is much more acceptable in programs that run for a while
- and then exit than in programs that run forever, like daemons and window
- systems. But it's not really X11's fault, per se.
-
- Actually, I once saw a malloc package that could be made to return some
- memory to the operating system by clever use of sbrk and brk, but I doubt
- that any X11 servers are written using such a technique. Might be an
- interesting experiment for some vendor, though ...
- --
- Matt Landau Waiting for a flash of enlightenment
- matt@centerline.com in all this blood and thunder
-