delorie.com/djgpp/faq/performance/overall.html
|
search
|
How do I configure my system to get optimal performance under
DJGPP?
Improving the overall performance of djgpp applications, including
gcc, depends on the amount of RAM you have installed in your
machine. Below are some guidelines to help you.
If you have 4 MBytes or less RAM installed
- Don't use any memory manager.
- Remove any TSR and device driver you don't absolutely need (like
setver.exe, himem.sys) from your config.sys
and autoexec.bat.
- Get a disk cache which works from conventional memory and
configure it to 256K size at most, or don't use a cache at all.
- Do not install RAM disk; point you TMPDIR
environment variable to a directory on your hard disk.
- stubedit gcc.exe and change the "Maximum amount
of virtual memory to keep when spawning" to zero.
With this configuration, gcc will still run out of free
physical RAM and page when compiling large C programs and most C++
programs. Also, you most probably won't be able to run recursive
Makefiles. Plan to buy more RAM as soon as you can.
If you have 5-8 MBytes of RAM installed
- Use memory manager such as emm386 or qemm386.
Try using the FRAME=NONE parameter of the memory manager.
This will disable Expanded Memory (EMS) services; if you must use
djgpp together with any program which needs EMS, try to configure that
program to use Extended Memory (XMS) instead.
- Load DOS, device drivers and TSRs HIGH.
- Give your disk cache 1 MByte of RAM. Enable its delayed-write
(aka write-back) feature.
- Do not install RAM disk; point you TMPDIR
environment variable to a directory on your hard disk.
- stubedit gcc.exe and change the "Maximum amount
of virtual memory to keep when spawning" to zero.
- If you have more than 2.5 MBytes of free RAM left (4 MBytes, if
you plan to program in C++ a lot), enlarge the disk cache size.
If you have more than 8 MBytes of RAM
- Use memory manager to load DOS, TSRs and device drivers high.
- Install at least 2-MByte-large disk cache, configured to use
delayed-write feature.
- If you have more than 5 MBytes left, install RAM disk with size
of at least 1.5 MBytes and point your TMPDIR environment
variable to it. If your RAM disk is less than 4 MBytes, gcc
might run out of space there for very large source files
(e.g., cccp.c file from the gcc source
distribution), but this shouldn't happen unless the size of the source
file you are compiling approaches 1 MByte.