CKON CKOPP UREC CALOC r ,
turns on a flag that causes the CHECK routine to be
invoked each time a call is made to DMSFREE or DMSFRET. This can be useful for debugging purposes (for example, when you wish to identify the routine that destroyed free
storage management pointers). Care should be taken when
using this option, since the CHECK routine is coded to be
thorough rather than efficient. Thus, after the CKeN option has been invoked, each call to DMSFREE or DMSFRET will take much longer to be completed than before.
turns off the flag that was turned on by the CKOB option.
is used by DMSABN during the abend recovery process to
release all user storage.
is used by DMSABN after the abend recovery process has
been It invokes a routine which returns, in
register 0, the number of doublewords of free storage
that have been allocated. This number is used by DMSAEN to determine whether or not the abend recovery has been
successful. I indicates how control is passed to DMSFES. Since DMSFRES IBALRI is a nucleus-resident routine, other nucleus-resident
L J routines can branch directly to it, (TYPCALL=BALR) while
routines that are not nucleus-resident must use SVC linkage (TYPCALL=SVC). ERROR CODES FROM DMSFRES, DMSFREE, AND DMSFRET A nonzero return code upon return from DMSPRES, DMSFREE, or DMSFRET indicates that the request could not be satisfied. Register 15 contains
this return code, indicating which error has occurred. The following
codes apply to the DMSFRES, DMSFREE, and DMSFRET macros. Code -,- 2
3
Error (DftSFREE) Insufficient storage space is available to satisfy
the request for free storage. In the case of a variable
request, even the minimum request could not be satisfied. (DMSFREE or DMSFRET) User storage pointers destroyed. (DMSFREE, DMSFRET, or DMSFRES) destroyed.
Nucleus storage pointers
4 (DMSFREE) An invalid size was requested. This error exit is
5
taken if the requested size is not greater than zero. In the
case of variable requests, this error exit is taken if the
m1n1mum request is greater than the maximum request.
(However, the latter error is not detected if DMSFREE is able
to satisfy the maximum request.)
(DMSFRET) An invalid size was passed to the
This error exit is taken if the specified
positive. DMSFRET macro.
length is not
254 IBM VM/370 System Programmer's Guide
April 1, 1981 (DMSFRET) The block of storage that is being released was
never allocated by DMSFREE. such an error is detected if one of the following errors is found: The block does not lie entirely inside either the low
storage free storage area or the user proqram area between FREELOWE and FREEUPPR. The block crosses a
allocated for USER NUCLEUS type storage.
page boundary
storaqe from
that separates a page
a page allocated for The block overlaps another block already on the free
storaqe chain.
7 (DMSFRET) The address given for the block being released is
not doubleword aligned.
8 (DMSFRES) An invalid request code vas passed to the DKSFRES routine. Since all request codes are generated by the DKSFRES macro, this error code should never appear.
9 (DMSFREE, DMSFRET, or DMSFRES) Unexpected and unexplained
error in the free storage management routine. eMS Handling of PSW Keys
The purpose of the CMS Nucleus protection scheme is to protect the CMS nucleus from inadvertent destruction by a user program. Without it, it
would be possible, for example, for a FORTRAN user who accidentally
assigns an incorrectly subscripted array element to destroy nucleus
code, wipe out a crucial table or constant area, or even destroy an
entire disk by destroying the contents of the master file directory.
In general, user programs and disk-resident CMS commands are executed
with a PSW key of X'E', while nucleus code is executed with a PSi key of X' 0'.
There are, however, some exceptions to this rule. Certain
disk-resident CMS commands run with a PSW key of X'O', since they have a
constant need to modify nucleus pointers and storage. The nucleus
routines called by the GET, PUT, READ, and WRITE macros run with a user PSW key of X'E', to increase efficiency.
Two macros are available to any routine that wishes to change its PSi key for some special purpose. These are the DMSKEY macro and the DMSEXS macro.
The DMSKEY macro may be used to change the PSW key to the user value
or the nucleus value. The DMSKEY NUCLEUS option causes the current PSW key to be placed in a stack, and a value of 0 to be placed in the PSi key. The DMSKEY USER option causes the current PSi key to be placed in
a stack; and a value of X'E' to be placed in the PSW key. The DMSKEY RESET option causes the top value in the DMSKEY stack to be removed and
re-inserted into the PSW. It is a requirement of the CMS system that when a routine terminates,
the DMSKEY stack must be empty. This means that a routine should
execute a DMSKEY RESET option for each DMSKEY NUCLEUS option and each DMSKEY USER option executed by the routine. Part 3. Conversational Monitor System (CMS) 255
Previous Page Next Page