Browse Prior Art Database

Automatic Freeing of Subsets Providing only an Address

IP.com Disclosure Number: IPCOM000108215D
Original Publication Date: 1992-May-01
Included in the Prior Art Database: 2005-Mar-22
Document File: 1 page(s) / 60K

Publishing Venue

IBM

Related People

Cox, DR: AUTHOR [+3]

Abstract

This article describes a method for automatically freeing a subset or memory from a segment providing only an address of that memory. There is no way to free a subset of memory in OS/2* without providing the actual length the subset was allocated for. OS/2 requires a caller to provide the address and the length of the subset in order to free memory using the DosSubFree() API. The application program must keep track of the length of each subset of memory it has obtained to properly make this API call.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 56% of the total text.

Automatic Freeing of Subsets Providing only an Address

       This article describes a method for automatically freeing
a subset or memory from a segment providing only an address of that
memory. There is no way to free a subset of memory in OS/2* without
providing the actual length the subset was allocated for.  OS/2
requires a caller to provide the address and the length of the subset
in order to free memory using the DosSubFree() API. The application
program must keep track of the length of each subset of memory it has
obtained to properly make this API call.

      In order to overcome this and other related memory problems in
our application systems, OfficeVision*/2 (OV/2) Office built a Memory
Management subsystem, providing a layer of independence between
applications programs and the OS/2 operating system.  This subsystem
is described in (*). Using this subsystem as a base for solving the
subset freeing problem, we enhanced the system to recalculate the
allocation size of each subset request to allow for a block of memory
for the Memory Management system to maintain additional information
in a prefix block. The subsystem then adjusted the allocation size to
align it on the four-byte boundary required by OS/2.  The actual
allocation size was then maintained in the prefix block.  Using the
enhanced subsystem, when an application frees a subset it needs to
provide only an address to the subset it wishes to free. The Memory
Management subsystem will use the...