| MC API | Subsystem list | Top level |
giRECmaxFreeMem
(in MClocal.inc) to a non-zero value.
At the start of each script, the recovery system (i.e. ScriptEnter)
will check the application to see how much free memory it has.
If the application has more than the amount specified by giRECmaxFreeMem,
the recovery system will "steal" memory from the application
to reduce its free memory to the specified amount.Note that this only happens at the beginning of each script, not at the beginning of each testcase.
If giRECmaxFreeMem is set to zero, recovery system
will not perform this check.
giRECminFreeMem to a non-zero value.
At the start of each script and each testcase, the recovery system
(i.e. ScriptEnter and TestcaseEnter)
will check the application to see how much free memory it has.
If the application has less than the amount specified by
giRECminFreeMem, then the recovery system
will raise an exception.
In your script you can change the minimum free memory parameter
by calling RECsetMinFreeMem.
If giRECminFreeMem is set to zero, recovery system
will not perform this check.
MEMgetFree,
MEMsteal and
MEMreturn.
MEMblockID - identifies a block of stolen memory
integer
| MEMgetFree
| ()
|
MEMblockID
| MEMsteal
| (integer iNumBytes)
|
void
| MEMreturn
| (MEMblockID)
|
void
| RECsetMinFreeMem
| (integer iNumBytes)
|
integer
| RECgetMinFreeMem
| ()
|
giRECmaxFreeMem
- maximum free memory at start of script
giRECminFreeMem
- minimum free memory at start of testcase
MEMsteal.
You can only obtain legal values of this type from
MEMsteal, and
the only legal use of a value of this type is to pass it to
MEMreturn.
type RECblockID is /* implementation is private! */
SYS_GetFreeMemory.
In particular, the QAP function cannot be used on UNIX.
integer MEMgetFree ( )
ReturnsMEMreturn.
MEMblockID MEMreturn
(integer iNumBytes)
iNumBytesReturnsX_MEM_INSUFFICIENT_MEMORYMEMsteal.
Note that you can only return a block once; returning it
twice is a programming error and will cause an exception to be raised.
void MEMreturn (MEMblockID uBlockID)
uBlockIDMEMsteal.X_MEM_BOGUS_BLOCKSets the minimum allowable amount of application free memory. If this is set to a non-zero value, the recovery system will check the application at the start of each script and each testcase to see how much free memory it has. If the application has less than the specified amount, then the recovery system will raise an exception.
If this parameter is set to zero, recovery system will not perform this check.
The initial value of this parameter is specified by the
variable giRECminFreeMem.
void RECsetMinMem (integer iNumBytes)
iNumBytes
Returns the current minimum allowable amount of free memory,
as set by the most recent call to RECsetMinFreeMem.
integer RECgetMinFreeMem ();
ReturnsLast updated 26 October 1996.