Article View: comp.os.msdos.programmer
Article #3392Re: .RTLink Plus Hints Needed
From: Ping Huang
Date: Sun, 27 Sep 1992 14:30
Date: Sun, 27 Sep 1992 14:30
46 lines
3198 bytes
3198 bytes
In article <1992Sep27.082317.191310@zeus.calpoly.edu> cambler@zeus.calpoly.edu (Christopher J. Ambler, Phish) writes: > Specifically, hints to increase heap memory, how to virtualize large > data objects, and determine often swapped function calls begging to > be put into root are a good start... I tried using .RTLink on one of my projects recently. (The project involved using Novell LWP TCP/IP libraries and Magma Systems Mewel [substantial subset of Windows API in text mode] libraries.) I had very good success letting .RTLink automatically decide what could be put into Virtual Memory pages. Even without turning VML on (e.g. having it emulate Microsoft Link as much as possible), I noticed that my executable size went from 380Kb to about 295Kb. .RTLink reported that executable to require 314Kb to load. I then turned on VML, using the output of VMARFGEN to decide what could be virtualized and what could not, made one manual change (WINALT.c in Mewel cannot be virtualized, it does nasty interrupt handling stuff), and the new executable required only 173Kb to load. The documentation that comes with .RTLink strikes me as very good and well worthwhile reading; unlike most programming tools, there seems to be almost an overabundance of documentation rather than too little. Be sure to print out some of the .HLP files on disk that relate specifics about using .RTLink with specific compilers and library packages. I was unable to get profiling to work after playing with it for a couple of hours. This is unfortunately, because the profiling functionality documented in the manuals looks very powerful -- capable of providing all the information you need about which functions should be put back into the root image for performance reasons, not to mention localizing where optimization would be worthwhile. For virtualizing large data objects, I would take a look at the overlay chapter in the manual. It clearly states that managing large data objects by overlays is easier than in Virtual Memory pages if you want to be able to change the data in a persistent way. If you are using Microsoft C7, you might also want to take a look at section 4.7 of "Programming Techniques", which talks about the new virtual memory manager in C7 -- it looks like Microsoft has provided new run-time library routines which have similar semantics to Windows calls to allocate and deallocate memory for data. -- | Ping Huang (INTERNET: pshuang@martigny.ai.mit.edu) speaking for himself. | "One Thing to name them all, One Thing to define them, | One Thing to place them in environments and bind them..."
Technical Details
Message-ID:
<PSHUANG.92Sep27103052@freeside.ai.mit.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!snorkelwacker.mit.edu!ai-lab!zurich.ai.mit.edu!pshuangReferences:
<1992Sep27.082317.191310@zeus.calpoly.edu>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!snorkelwacker.mit.edu!ai-lab!zurich.ai.mit.edu!pshuang From: pshuang@zurich.ai.mit.edu (Ping Huang) Newsgroups: comp.os.msdos.programmer Subject: Re: .RTLink Plus Hints Needed Message-ID: <PSHUANG.92Sep27103052@freeside.ai.mit.edu> Date: 27 Sep 92 14:30:52 GMT References: <1992Sep27.082317.191310@zeus.calpoly.edu> Sender: news@ai.mit.edu Reply-To: pshuang@athena.mit.edu Organization: M.I.T. Artificial Intelligence Lab. Lines: 47 In-reply-to: cambler@zeus.calpoly.edu's message of 27 Sep 92 08:23:17 GMT