home *** CD-ROM | disk | FTP | other *** search
/ Collection of Hack-Phreak Scene Programs / cleanhpvac.zip / cleanhpvac / SOFTIC~1.ZIP / DOC-TXT.ZIP / CHAP8 < prev    next >
Text File  |  1992-05-24  |  10KB  |  255 lines

  1.   CHAPTER 8
  2.  
  3.  Expanded Memory Support
  4.    8.1 Introduction
  5.    8.2 Configuring the EMM Environment
  6.    8.2.1 Default EMM Pages
  7.    8.2.2 Customizing the EMM Page Map
  8.    8.2.2.1 Including and Excluding Areas from EMM
  9.    8.3 Other EMM Features
  10.    8.3.1 Increasing Conventional Memory
  11.    8.3.2 Automatic Page Frame Locating
  12.    8.4 EMM Debugging
  13.  
  14.      189
  15.  
  16.  8.1 Introduction
  17.  
  18. Soft-ICE has an expanded memory manager built into its kernel. The Soft-
  19. ICE expanded memory manager supports the Lotus-Intel-Microsoft 4.0
  20. specification. This Soft-ICE feature is useful if you are using programs
  21. that support the EMM specification, or if you must backfill your
  22. conventional memory to extend your conventional memory to 640K or more.
  23.  
  24. Other 386 control programs that provide EMM capability (such as QEMM or
  25. 386-to-the-MAX) will not co-exist with Soft-ICE. If you are using those
  26. programs for EMM capability or backfilling, you can use the Soft-ICE EMM
  27. manager in their place.
  28.  
  29. Enabling EMM capability in Soft-ICE involves the following steps:
  30.    1. Configure the expanded memory environment
  31.       with the utility EMMSETUP.EXE. This utility
  32.       modifies S-ICE.EXE with the desired EMM page
  33.       map.
  34.    2. Add the /EMM switch to your S-ICE.EXE line
  35.       CONFIG.SYS. This reserves a portion of
  36.       extended memory for expanded memory. An
  37.       example line in CONFIG.SYS that reserves
  38.       memory for EMM is:
  39.           DEVICE = S-ICE.EXE /EMM 2048
  40.       This will reserve 2 megabytes of extended memory
  41.       for EMM use. See section 6.3 (Loading Soft-ICE
  42.       as a Loadable Device Driver) for details of
  43.       installing Soft-ICE in CONFIG.SYS.
  44.   3. Reboot your system.
  45.  
  46.      190 
  47.  
  48. 8.2 Configuring The EMM Environment
  49.  
  50. Before installing S-ICE.EXE with the /EMM switch in CONFIG.SYS file, you
  51. may have to run EMMSETUP.EXE to configure the EMM 4.0 environment. This
  52. configuration process allows you to select which portions of memory you
  53. would like to make available as EMM 4.0 pages. Running EMMSETUP.EXE is
  54. highly recommended if you are using programs that take full advantage of
  55. the EMM 4.0 specification.
  56.  
  57. 8.2.1 Default EMM Pages
  58.  
  59. By default, S-ICE.EXE with the /EMM switch is pre-configured to allow EMM
  60. 4.0 pages in the following areas:
  61.  
  62.    * The lower 640K (except for the 1st 64K)
  63.    * 64K starting at DDH
  64. You may want to reconfigure for the following reasons:
  65.    * You may have a device such as a network that i
  66.        the D000H area of memory.
  67.    * You may want to fill more holes above 640K with
  68.        EMM pages. This will increase performance and
  69.        usability of programs like Microsoft Windows. To
  70.        get maximum performance from Microsoft
  71.        Windows you should fill every available page with
  72.        expanded memory.
  73.  
  74.  8.2.2 Customizing the EMM Page Map
  75.  
  76. To configure the EMM map you must use the utility EMMSETUP.EXE.
  77. EMMSETUP.EXE allows the page map to be altered, then modifies S-ICE.EXE
  78. with the changes.
  79.  
  80.      191
  81.  
  82. EMMSETUP makes its best guess on automatically configuring the EMM map.
  83. EMMSETUP will try to fill much of the address space as possible with
  84. mappable pages while working around video cards and ROMS. If its guess is
  85. not good enough or not to your liking you can override it. Overriding may
  86. be necessary if you have a network, a special video adapter or a memory-
  87. mapped option adapter.
  88. To configure the EMM map enter:
  89.  
  90.    EMMSETUP
  91.  
  92. EMMSETUP displays a matrix of 16K memory pages available in the lower 1
  93. megabyte region. The matrix is divided into 16 columns each representing
  94. 64K (from 0 to 10000H). There are 4 rows representing the four 16K pages
  95. in each 64K region.
  96.  
  97. Each block of the matrix can contain an E, X, R or V. Blocks that contain
  98. an E are available as EMM pages; blocks that contain an X are not. Blocks
  99. that contain an R are memory areas that have been identified by EMMSETUP
  100. as ROM areas. You can override these areas with an E if desired, however,
  101. this should only be done if the ROM is never accessed. Blocks that contain
  102. V are identified as video memory. We have made worst case assumptions on
  103. video memory. Your particular video card may not take up as much as we
  104. have 'guessed'. You can override the memory blocks that contain
  105. unnecessary V's if desired.
  106.  
  107. If you are satisfied with EMMSETUP's guesses, press the F10 key and S-
  108. ICE.EXE will be modified with these parameters. You must reboot before any
  109. changes made to S-ICE.EXE will take effect. If you wish to override
  110. EMMSETUP's guesses, do so at this time.
  111.  
  112.      192 
  113.  
  114. 8.2.2.1 Including and Excluding Areas from EMM
  115.  
  116. To include an area as EMM 4.0 memory simply guide the cursor to the
  117. desired block, then type E. Conversely, to exclude an area from EMM 4.0
  118. memory, guide the cursor to the block and type X. When you are satisfied
  119. with your changes, press F10 to exit the program. All changes are
  120. automatically stored in the S-ICE.EXE file. If you wish to exit without
  121. modifying S-ICE.EXE press ESC. You must reboot before any changes made to
  122. S-ICE.EXE will take effect.
  123.  
  124. When including upper memory blocks keep in mind the following:
  125.    * CGA occupies from B800H to C000H.
  126.    * MDA occupies from B000H to B100H.
  127.    * Most Hercules cards occupy from B000 to C000H.
  128.    * EGA occupies from A000H to C000H and from
  129.        C000H to C400H.
  130.    * VGA (mother board) occupies from A000H to
  131.        C000H.
  132.    * VGA (option card) occupies from A000H to
  133.        C000H and C000H to C800H.
  134.    * PS/2 System ROM occupies from E000H to
  135.        10000H.
  136.    * PS/2 ESDI ROM occupies from CC00H to D000H
  137.    * Most AT Compatible Roms occupy from F000H to
  138.        10000H.
  139.    * Compaq systems, Micronix motherboard systems,
  140.        and most Chips and Technologies motherboard
  141.        systems move the EGA/VGA ROM to E000H
  142.        However they still occupy the C000H region as
  143.        well.
  144.    * Token Ring Networks usually occupy from CC00H
  145.        to E000H.
  146.    * Many Networks occupy memory regions in the
  147.        D000H area.
  148. The above guidelines are for 'generic' devices, Many implementations by
  149. different computer vendors and
  150.  
  151.      193 
  152.  
  153. adapter card vendors will vary.
  154.  
  155. 8.3 Other EMM Features
  156.  
  157. S-ICE.EXE with the /EMM switch has two features that are automatically
  158. enabled depending on your system configuration. These features are
  159. backfilling and relocating the page frame.
  160.  
  161. 8.3.1 Increasing Conventional Memory
  162.  
  163.  
  164. System memory will automatically be backfilled up to the first non-
  165. mappable page. This means it starts looking at contiguous E's at location
  166. 1000, and continues until it finds the first non-contiguous E. If the
  167. contiguous E's go beyond the amount of your system's base memory, memory
  168. will backfilled up to the first R, V, or X that is found.
  169.  
  170. The benefit of backfilling is that you can increase the amount of usable
  171. system memory to greater than 640K. The backfilled memory is available
  172. within DOS. If you do not want memory backfilled, use EMMSETUP to make
  173. page non-mappable (X) at the point you wish system memory to end.
  174.  
  175. Note:
  176. Monochrome-only systems (MDA) can backfill up to B000H to add an
  177. additional 64K to conventional memory CGA systems can be backfilled up to
  178. B800, adding an additional 96K to conventional memory. EGA and VGA systems
  179. can be backfilled only if no graphics programs will be run. You can
  180. backfill an EGA or a VGA system up to B800:0 if no graphics programs will
  181. be run.
  182.  
  183. Warning:
  184. If memory is backfilled,DO NOT UNLOAD Soft-ICE. Doing so will cause your
  185. system to crash.
  186.  
  187.      194 
  188.  
  189. 8.3.2 Automatic Page Frame Locating
  190.  
  191. Most EMM-knowledgeable programs require a 64K page frame that is not used
  192. as normal DOS memory. This is normally located above the video device
  193. area. However in some systems there is no 64K contiguous region to place
  194. the page frame. In these instances S-ICE.EXE 'steals' top 4 mappable pages
  195. of lower memory. The net result that lower DOS memory shrinks by 64K.
  196.  
  197. 8.4 EMM Debugging
  198.  
  199. A range break point or a break point on memory that is in an EMM mappable
  200. area will stay at that address no matter which EMM page is mapped in.
  201.  
  202. When debugging EMM programs, the EMMMAP command may also be very useful.
  203. See section 5.6 for more information.
  204.  
  205. The D, E, S, F, and C commands can be used to view or modify any allocated
  206. EMM handle page. The page does not have to be currently mapped in. The
  207. syntax of these commands is similar to that of the commands when being
  208. used for non-EMM pages, except for the following:
  209.     * In the D, E, S, and F commands, the address
  210.         portion of the command must be specified in the
  211.         following way:
  212.         Hhandle# Ppage# offset
  213.         where handle is a number specifying which EMM
  214.         handle to use, page is a number specifying which
  215.         EMM page to use, and offset is a number from 0 to
  216.         4000H, specifying the offset from the beginning
  217.         the page.
  218.  
  219.      195
  220.  
  221.       Example:
  222.  
  223.       DB H1 P3 0
  224.       This command will dump bytes from page 3 of
  225.       handle 1, starting at offset 0.
  226.  
  227.    *  The C command must be specified in the following
  228.       way:
  229.       C Hhandle# Ppage# offset1 Llength offset2
  230.       where handle and page are the same as above.
  231.       offset1 is a number from 0 to 4000H, specifying the
  232.       offset from the beginning of the page, where the
  233.       first data block to be compared is located. offset2 is
  234.       a number from 0 to 4000H, specifying the offset
  235.       from the beginning of the page, where the second
  236.       data block to be compared is located.
  237.       Example:
  238.    
  239.       C H2 P4 00 L10 1000
  240.     
  241.       This command will compare the first 10 bytes of
  242.       memory located at offset 0 of page 4 of handle 2
  243.       with the first 10 bytes of memory located at offset
  244.       1000 of page 4 of handle 2.
  245.  
  246. Note:
  247. Subsequent uses of the D, E, S, F, and C commands will continue to use the
  248. handle and page last specified. To get back to conventional memory, use
  249. one of the above commands with a segment specified in the address field,
  250. for example:
  251.          D 0:0
  252.  
  253.      196
  254.  
  255.