delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1995/01/15/20:52:58

Date: Mon, 16 Jan 1995 10:37:16 +0900
From: Stephen Turnbull <turnbull AT shako DOT sk DOT tsukuba DOT ac DOT jp>
To: enok AT lysator DOT liu DOT se
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Optimize your PC

Oskar--
    Thanks for the good work!

    I would like to note that when I built Ghostscript, my experience
was basically the same as yours (that is, 4MB is tight and a 1MB cache
is about right; with >8MB---I actually have 12MB, a 2MB cache is about
right).  Despite the fact that Ghostscript is a huge program, very few
of the source files are more than about 5KB.  By far the biggest
"source" file is the Makefile (at 120KB and growing)!
    *But* the link step on such a program is a killer.  When compiled
*without* "-g", the linked executable is 4.5MB before stripping.  I'm
not sure if it's an artifact of the machine I was working on (the IBM
ThinkPad seems to be very broken), but the total VM required was 9MB
of RAM + 16MB of page space = 25MB.  When I've got the time I'll check
this on my other system.
    I don't know what the implications of this are for optimizing your
memory usage.  I suspect that for full builds, on an 8MB machine you
use your configuration (2MB cache).  But late in the development
process, when you are tweaking a couple of files at a time, then
rebuilding, it may make sense to use a smaller (or even no) cache, and
allow the linker as much physical RAM as possible.
    I emphasize that this is just a guess, but I thought I would throw
these observations (that the linker on a large system of small source
files will use many times as much memory as the compilation phase, and
that late in the development stage, linking will dominate the build
time) out for the consideration of those who know what they are
talking about.  (And for the use of FAQ compilers.)
    --Steve

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019