Unit heapunit

Classes

Functions

AddToAddress - Since the maximum length of a contiguous piece of memory (allocated with GetMem, deallocated with FreeMem c.
BigBlockRead - Same as BlockWrite (Turbo Pascal) but permits writing of blocks greater than the BP block size of at most 65535

AddToAddress
BigBlockWrite - Increments the address of P with 'increment'

BigBlockRead
BigFillChar - Same as BlockRead (Turbo Pascal) but permits reading of blocks greater than the BP block size of at most 65535

Move } {$endif} { Procedures for both REAL and PROTECTED mode
BigFreeMem - Same as FillChar (Turbo Pascal), but size larger than 65520 bytes is allowed.
BigGetMem - Same as FreeMem (see Turbo Pascal help about that procedure), but 'size' larger than 65520 bytes is allowed

BigBlockWrite
BigMove - Same as GetMem (see Turbo Pascal help about that procedure), but 'size' larger than 65520 bytes is allowed.
Move - Same as Move (see declaration hereunder), but 'Count' larger than 65520 bytes is allowed

BigFreeMem

Types

Constants

blocksize

Variables


Functions


procedure AddToAddress(var P: Pointer; Increment: Longint);

Since the maximum length of a contiguous piece of memory (allocated with GetMem, deallocated with FreeMem c.q. copied by Move) is 65520, one must use these procedures with blocks smaller than that size. The chosen size is rather arbitrary, but easy when debugging.

**********************) { Procedures for REAL mode } { Procedures for PROTECTED mode } {$ifndef MSDOS


procedure BigBlockRead(var F: file; var buffer; number: Longint; var Result: Longint);

Same as BlockWrite (Turbo Pascal) but permits writing of blocks greater than the BP block size of at most 65535

AddToAddress


procedure BigBlockWrite(var f: file; var buffer; number: Longint; var Result: Longint);

Increments the address of P with 'increment'

BigBlockRead


procedure BigFillChar(address : pointer; size : longint; ch : char);

Same as BlockRead (Turbo Pascal) but permits reading of blocks greater than the BP block size of at most 65535

Move } {$endif} { Procedures for both REAL and PROTECTED mode


procedure BigFreeMem(address: Pointer; size: Longint);

Same as FillChar (Turbo Pascal), but size larger than 65520 bytes is allowed.

BigGetMem


procedure BigGetMem(var address: Pointer; size: Longint);

Same as FreeMem (see Turbo Pascal help about that procedure), but 'size' larger than 65520 bytes is allowed

BigBlockWrite


procedure BigMove(var Source, Dest; Count: Longint);

Same as GetMem (see Turbo Pascal help about that procedure), but 'size' larger than 65520 bytes is allowed. 'Address' returns the starting address of the allocated piece of memory; returns nil if no block of the specified size could be found

BigFillChar


procedure Move(var Source, Dest; Count: Longint);

Same as Move (see declaration hereunder), but 'Count' larger than 65520 bytes is allowed

BigFreeMem


Types


Constants

blocksize = 64000

************************)

Variables