Path: utzoo!attcan!utgpu!news-server.csri.toronto.edu!mailrus!uwm.edu!zaphod.mps.ohio-state.edu!usc!jarthur!nntp-server.caltech.edu!juno!andy From: andy@juno.caltech.edu (Andy Fyfe) Newsgroups: comp.sys.att Subject: Re: two questions about the 3b1 Message-ID: <1990Aug18.164211.5564@laguna.ccsf.caltech.edu> Date: 18 Aug 90 16:42:11 GMT References: <24776@boulder.Colorado.EDU> Sender: news@laguna.ccsf.caltech.edu Reply-To: andy@csvax.cs.caltech.edu Organization: California Institute of Technology Lines: 26 In article <24776@boulder.Colorado.EDU> andersom@tramp.Colorado.EDU (ANDERSON MARC O) writes: >[1] - Is it just me (or my machine) or does it take all of you 3b1'ers >a half an hour to compile small stuff with g++? (gnu c++) The problem might well be "malloc". If you want to see what can happen, write a program that does do { p = malloc(4000); printf("malloc returns %x\n", p); } while (p != 0); and compare this program when linked with libc/shlib to this program linked with -lmalloc. At one point I had compiled g++ on my 3b1 (though I got rid of it when I realized it couldn't compile larger programs for lack of virtual address space) and I compared the times for the osu version, and the ones I compiled with the shlib, -lmalloc, and gnu malloc. The difference was, I believe about an hour versus 4 minutes. (Though the quicker ones got through 3 or 4 fewer source lines before giving me a virtual memory exhausted error.) If you want to link with -lmalloc and still use the shared library, you need a program like shcc or the shared ld (that I wrote, but based on shcc) which you can find in the osu archives as well. Andy Fyfe andy@csvax.cs.caltech.edu ....!ames!elroy!cit-vax!andy