en:docs:fapi:dosgethugeshift

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
en:docs:fapi:dosgethugeshift [2021/09/17 06:06] prokusheven:docs:fapi:dosgethugeshift [2021/12/05 09:59] (current) prokushev
Line 13: Line 13:
 ===== Parameters ===== ===== Parameters =====
  
-  * ShiftCount (PUSHORT) - output : Address of the shift count.+  * ShiftCount ([[PUSHORT]]) - output : Address of the shift count.
  
 ===== Return Code ===== ===== Return Code =====
  
-rc (USHORT) - return+rc ([[USHORT]]) - return
  
 Return code description is: Return code description is:
Line 25: Line 25:
 ===== Remarks ===== ===== Remarks =====
  
-Each segment of a huge memory allocation has a unique selector. To compute the next sequential selector in a huge memory area, take the value 1, shift it left by the number of bits specified in shift count. Use the resulting value as an increment to add to the previous selector (using the selector returned by DosAllocHuge as the first selector). For example: +Each segment of a huge memory allocation has a unique selector. To compute the next sequential selector in a huge memory area, take the value 1, shift it left by the number of bits specified in shift count. Use the resulting value as an increment to add to the previous selector (using the selector returned by [[DosAllocHuge]] as the first selector). For example: 
-  * Assume DosAllocHuge is issued with NumSeg equal to 3, and that the number 63 is returned for the selector of the first segment. +  * Assume [[DosAllocHuge]] is issued with NumSeg equal to 3, and that the number 63 is returned for the selector of the first segment. 
   * If DosGetHugeShift returns a shift count of 4, shifting the value "1" by this amount results in an increment of 16.    * If DosGetHugeShift returns a shift count of 4, shifting the value "1" by this amount results in an increment of 16. 
   * Adding this increment to selector number 63 produces 79 for the second selector. Adding the same increment to selector number 79 yields 95 for the third selector.   * Adding this increment to selector number 63 produces 79 for the second selector. Adding the same increment to selector number 79 yields 95 for the third selector.