home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / os / vms / 20086 < prev    next >
Encoding:
Text File  |  1992-12-30  |  2.5 KB  |  50 lines

  1. Newsgroups: comp.os.vms
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!darwin.sura.net!haven.umd.edu!decuac!pa.dec.com!e2big.mko.dec.com!quark.enet.dec.com!lionel
  3. From: lionel@quark.enet.dec.com (Steve Lionel)
  4. Subject: RE: ballooning EXE size
  5. Message-ID: <1992Dec30.142249.21319@e2big.mko.dec.com>
  6. Lines: 37
  7. Sender: usenet@e2big.mko.dec.com (Mr. USENET)
  8. Reply-To: lionel@quark.enet.dec.com (Steve Lionel)
  9. Organization: Digital Equipment Corporation, Nashua NH
  10. References:  <9212291417.AA07008@uu3.psi.com>
  11. Date: Wed, 30 Dec 1992 14:22:49 GMT
  12.  
  13.  
  14. A number of people have replied to Loren Buhle's question about "Balooning
  15. EXE size" with the suggestion to increase the linker's cutoff point for 
  16. creating new demand-zero image sections using the ISD_MAX linker option
  17. statement.  Though that "fix" often will shrink the image size, it has a hidden
  18. cost; the reason for the limit in the first place.
  19.  
  20. As the number of image sections grows, the image activation time also grows;
  21. an image with 100 or more image sections can take a long time to activate.
  22. Sometimes this isn't a problem, but sometimes it is.  The ideal solution, which
  23. I described in my previous posting, is to reduce the number of image sections to
  24. the absolute minimum by using the linker COLLECT option statement.  If possible,
  25. get it down such that there are no two image sections of the same type
  26. (read-only, demand-zero, copy-on-ref, etc.).  I would only recommend adjusting
  27. ISD_MAX if you haven't succeeded using the COLLECT method.
  28.  
  29. Some additional tips - use COMMON instead of large local variables; even a 
  30. COMMON which is only used by one routine.  Each COMMON has its own PSECT name 
  31. and thus you can use COLLECT to put all the uninitialized COMMONs together.
  32. Reserve local variables for non-arrays and initialized storage.  Even better,
  33. put all your data-initialized storage into their own set of COMMONs and 
  34. COLLECT them into their own image section.  The VAX FORTRAN and VAX FORTRAN-HPO
  35. Release Notes contain additional details on how to use COLLECT in a linker
  36. options file.
  37.  
  38. At present, there is a limit of 250 named COMMONs in VAX FORTRAN, and no way
  39. to allocate arrays on the stack (which would be ideal for large local arrays).
  40. In DEC Fortran for OpenVMS VAX V6.0, which we expect to be shipping by March,
  41. this limit is raised to 508, plus you can allocate arrays on the stack by
  42. using the AUTOMATIC statement.
  43. --
  44.  
  45. Steve Lionel                    lionel@quark.enet.dec.com
  46. SDT Languages Group
  47. Digital Equipment Corporation
  48. 110 Spit Brook Road
  49. Nashua, NH 03062
  50.