SVC 203 is called by macros to perform various internal system functions. It is used to define SVC calls for which no parameter list
is provided. For example, parameters are passed in registers 0 and 1.
A typical calling sequence for an SVC 203 call is as follows: SVC 203 DC H'code'
The halfvord decimal code following the SVC 203 indicates the
specific routine being called. DMSITS examines this halfword code,
taking the absolute value of the code by an LPR instruction. The first
byte of the result is ignored, and the second byte of the resulting
halfvord is used as an index to a branch table. ine address of the correct routine is loaded, and centrol is transferred to it.
It is possible for the address in the SVC 203 index table to be-zero.
In this case, the index entry will contain an 8-byte routine or co.mand name, which will be handled in the same way as the 8-byte name passed in
the parameter list to an SVC 202. The programmer indicates an error return by the sign of the halfword
code. If an error return is desired, then the code is negative. If the
code is positive, then no error return is made. The sign of the
halfword code has no effect on determining the routine that is to be
called, since DMSITS takes the absolute value of the code to determine
the routine called.
Since only the second byte of the absolute value of the code is
examined by DMSITS, seven bits (bits 1-7) are available as flags or for
other uses. Thus, for example, uses these seven bits to
indicate such things as conditional requests and variable requests. When an SVC 203 is invoked, DMSITS stores the halfword code into the IUCON location CODE203, so that the called routine can examine the seven
bits made available to it.
All calls made by means of SVC 203 should be made by macros, with the macro expansion computing and specifying the correct halfword code.
The programmer may use the HNDSVC macro to specify the address of a
routine that will handle any SVC call other than for SVC 202 and SVC 203. In this case, the linkage conventions are as required by the
user-specified SVC-handling routine. supports selected SVC calls generated by 05 and DeS/VS macros, by
simulating the effect of these macro calls. DMSITS is the initial SVC interrupt handler. If the SET DOS command has been issued, a flag in NUCON will indicate that DOS/VS macro simulation is to be used. Control
is then passed to DMSDOS. Otherwise, as macro simulation is assumed and DMSITS passes control to the appropriate as simulation routine. CftS Introduction 2-27
There are several types of invalid SVC calls recognized by 1. Invalid SVC number. If the SVC number does not fit into any of the
four classes described above, then it is not handled by D6SITS. An
appropriate error message is displayed at the terminal, and control
is returned directly to the caller.
2. Invalid routine name in SVC 202 parameter list. If the routine
named in the SVC 202 parameter list is invalid or cannot be found, DMSITS handles the situation in the same way as it handles an error
return from a legitimate SVC routine. The error code is -3.
3. Invalid SVC 203 code. If an invalid code follows SVC 203 inline,
then an error message is displayed, and the abend routine is called
to terminate execution. SEARCH RIER!RCH! FOP. SYC When a program issues SVC 202, passing a routine or command name in the parameter list, then DMSITS must be searched for the specified routine
or command. (In the case of SVC 203 with a zero in the table entry for
the specified index, the same logic must be applied.)
1.
The search algorithm is as follows: I check is made to see if there is a routine with
name currently occupying the system transient area.
case, then control is transferred there.
the specified
If this is the
2. The system function name table is searched, to see if a co.mand by
this name is a nucleus-resident command. If the search is
successful, control goes to the specified nucleus routine.
3. A search is then made for a disk file with the specified name as
the filename, and MODULE as the filetype. The search is made in
the standard disk search crder. If this search is successful, then
the specified module is loaded (via the LOIDMOD command), and
control passes to the storage location now occupied by the command. 4. If all searches so far have failed, then DftSINI (IEEREV) is called,
to see if the specified routine name is a valid system abbreviation
for a system co •• and or function. User-defined abbreviations and
synonyms are also checked. If this search is successful, then
steps 2 through 4 are repeated with the full function name. 5. If all searches fail, then an error code of -3 is issued. When a command is entered from the terminal, DMSINT processes the
command line, and calls the scan routine to convert it into a parameter
list consisting of eight-byte entries. The following search is
performed:
1. DMSINT searches for a disk file whose filename is the command name, and whose filetype is EXEC. If this search is successful, EXEC is
invoked to process the EXEC file.
2-28 IBM VM/370 System Logic and Program Determination--Volume 2
Previous Page Next Page