IBM OS/390 User Manual

Page of 673
(MVS)
LOAD
EP=PROGB
LOAD the load-module
LR
15,0
pass address
CALL
(15),parm1,parm2
invoke PROGB
FETCH Macro
The VSE FETCH macro loads the phase specified in the first parameter and
passes control to the address specified by the second. The MVS LINK and XCTL
macros pass control to a specified entry point. When modifying programs from
VSE to MVS, use LINK when the called phase does not overlay the calling phase.
Use XCTL when the called phase does overlay the calling phase. When using
XCTL, ensure that all DCBs and ACBs in the calling programs have been closed
prior to issuing XCTL.
CDLOAD and CDDELETE Macros
The MVS LOAD and DELETE macros have functions similar to the VSE CDLOAD
and CDDELETE macros. The CDLOAD macro can be used repetitively against
the same module, first to load it, then to retrieve its address. In this case, to
achieve the same result in MVS with the LOAD macro, the loaded module must
be link-edited with the REUS attribute.
Example:
(VSE)
LA
1,PHASENM
address of the phase name
CDLOAD (1)
LOAD the phase
LR
15,1
pass address
CALL
(15),parm1,parm2
invoke PROGB
 (MVS)
LOAD
EPLOC=PHASENM
LOAD the load-module
LR
15,0
pass address
CALL
(15),parm1,parm2
invoke PROGB
WTO and WTOR Macros
The MVS WTO and WTOR macros have functions similar to the VSE/ESA WTO
and WTOR macros.
GETIME Macro
The VSE GETIME macro provides the time of day, (local or Greenwich Mean
Time) based on a 24-hour clock, in register 1 in a form dependent upon the
operand(s).
The MVS TIME macro has the same basic function as the VSE GETIME LOCAL
macro. The main differences between the two macros is in register usage and
degree of precision (Figure 30 on page 279). For the DEC, BIN, and TU
operands, the TIME macro returns the time in register 0 and the Julian date in
register 1. The date is returned in register 1 as packed decimal digits in the form
0C YY DD DF, where 0C is the century indicator, YY is the last two digits of the
year, DDD is the day of the year and F is a sign character that allows the date to
be unpacked and printed. If the date is needed as day/month or month/day, you
must provide a routine to convert the data.
278
VSE to OS/390 Migration Workbook