C++ PLIST and EXECOPS interactions

The EXECOPS compiler option allows you to specify runtime options on the command line or in JCL at application invocation. NOEXECOPS indicates that runtime options cannot be so specified. When the EXECOPS compiler option is specified under MVS™, Language Environment alters the MVS parameter list format by removing any runtime options present.

The PLIST compiler option indicates in what form the invoked routine should expect the argument list. You can only specify PLIST with the following value under Language Environment:
OS
The inbound parameter list is assumed to be in an MVS linkage format in which register 1 points to a parameter address list. No runtime options are available. Register 1 is not interrogated by Language Environment.

The EXECOPS, NOEXECOPS, and PLIST compiler options can alter the format of the argument list passed to your application, depending on the combination of options specified. The setting of EXECOPS determines whether Language Environment looks for runtime parameters in the inbound parameter list. The effects of the interactions of these options under MVS, TSO, and the various subsystems are summarized in Table 1:

Table 1. Interactions of C/C++ PLIST and EXECOPS (compiler options)
Operating system Method of invocation Compiler options Runtime options honored? argc/argv __R1/ __osplist and PCBs
MVS EXEC PGM=,

PARM= <runtime options> / <user args>

EXECOPS (or default) Yes argc = number of tokenized args in <user args>

argv[0…argc-1] = tokenized args in <user args>

 
MVS EXEC PGM=,

PARM= <runtime options> / <user args>

NOEXECOPS No argc = number of tokenized args in the entire PARM string, that is, <runtime options> / <user args>

argv[0…argc-1] = tokenized args in the entire PARM string

 
MVS Driver link to C++ main passing noncharacter parameter list PLIST(OS) n/a argc=1

argv[0] = name of C++ main program module

Access register 1 through __osplist macro as defined in stdlib.h
TSO CALL, LOADGO, execute module on TSO command line passing <runtime options> / <user args> EXECOPS (or default) Yes argc = number of tokenized args in <user args>

argv[0…argc-1] = tokenized args in <user args>

 
TSO CALL, LOADGO, execute module on TSO command line passing <runtime options> / <user args> NOEXECOPS No argc = number of tokenized args in <runtime options> / <user args>

argv[0…argc-1] = tokenized args in <user args>

 
TSO CALL PLIST(OS) n/a argc=1

argv[0] = name of module

Access CPPL through __osplist as defined in stdlib.h
IMS™ Start of changeInvoke C/C++ main moduleEnd of change PLIST(OS)

Specify TARGET(IMS) also.

n/a argc=1

Start of changeargv[0] = name of C++ main moduleEnd of change

Access PCBs through C macros as defined in ims.h
CICS® Invoke C++ main module Any (or default) n/a argc=1

argv[0] = transaction ID