Mail Archives: djgpp/1994/02/22/01:36:31
Raymond Rosmalen writes:
> Hi, I've been trying to improve on compilation time by making
> a RAM drive. I have in total 3MB XMS memory from which 1MB is
> in use by SMARTDRV. I made an 1MB RAM drive in XMS memory.
> Next, the TMPDIR varaiable was set to point to the RAM drive.
>
> Now I compiled a small (about 50 lines) program and this took
> me about 15 minutes (1MB RAM drive, 1MB XMS) !! Without the
> RAM drive it `only' took me 1.5 minutes (0MB RAM drive 2MB
> XMS).
>
> My question is: Did I forget something in setting up a RAM
> drive or is 3MB XMS memory just not enough? Or maybe, should
> I have created a smaller (or larger) RAM drive instead? Any
> comments are more than welcome!
Welcome to the wonderful world of virtual memory. You are
probably better off running GCC without either a ramdisk _or_ a
disk cache, since GCC needs at least 2M by itself, and having
less than 2M of free physical memory will result in it paging to
disk. A ramdisk and a disk cache together will reduce
performance, as you saw, since your system will spend a lot of
time moving stuff between them, taking CPU time away from your
compilation. A small disk cache (perhaps 256K or 512K) alone
_might_ help, by reducing somewhat the amount of access neded to
the physical disk.
- Raw text -