Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!samsung!zaphod.mps.ohio-state.edu!usc!ucsd!ucbvax!hplabs!hplabsz!mayer From: mayer@hplabsz.HPL.HP.COM (Niels Mayer) Newsgroups: comp.windows.x Subject: Re: Performance (also an R5 Toolkit Wish) Message-ID: <5857@hplabsz.HPL.HP.COM> Date: 28 Aug 90 19:31:33 GMT References: <1141@phcisa.UUCP> <5354@harrier.ukc.ac.uk> Reply-To: mayer@hplabs.hp.com (Niels Mayer) Organization: Hewlett-Packard Labs, Software & Systems Lab, Palo Alto, CA. Lines: 39 Summary: Expires: Sender: Followup-To: In article <5354@harrier.ukc.ac.uk> rlh2@ukc.ac.uk (Richard Hesketh) writes: >In article <1141@phcisa.UUCP>, frans@phcisa.UUCP (Francois Staes) writes: >|> Can smoebody tell me where I can find such a fast memory allocator ? >|> Can I simply use the malloc.c file as distributed with e.g. emacs ? > >Yes this seems to work just fine. Infact it is *extremely* quicker when a >large number of widgets need to be created. I have also found similar improvements when I use HP's -lmalloc (malloc(3X)) in Xtoolkit-based programs. Which other machines have a "fast malloc library" as part of their standard Un*x libraries? I'm particularly interested in (not necessarily in order of interest): (1) Sun, (2) DEC RISC, (3) MIPS, (4) Data General Aviion, (5) Apollo > Here comes the wish then ... how about a malloc written just for Xt and included > in the R5 release? I wouldn't want to say "just use the GNU malloc" because > of copyright restrictions. What about the andrew malloc library?? It has an MIT X Consortium style copyright. It is located in X11r4:contrib/toolkits/andrew/overhead/malloc I did notice the following warning from the file malloc.help: | The current incarnation of the allocator is unsuitable for direct use in a | large virtual environment where many small blocks are to be kept, since it | keeps all allocated and freed blocks on a single circular list. Just before | more memory is allocated, all allocated and freed blocks are referenced; this | can cause a huge number of page faults. | ??? ------------------------------------------------------------------------------- Niels Mayer -- hplabs!mayer -- mayer@hplabs.hp.com Human-Computer Interaction Department Hewlett-Packard Laboratories Palo Alto, CA. *