For a non-XPLINK 31-bit z/OS XLC C or C++ program, there is no doubt in my mind 
but that extern "OS" gives you "old-fashioned" OS/360 parm passing. For example 
(working code)

extern "OS" void ABEND(int code, int reason);   

ABEND    EDCPRLG DSALEN=CDSALEN,BASEREG=NONE 
         USING CDSASTOR,R13         Use R13 as base for reentrant store
*
*  Pick up the C-passed parameters
         L     R1,4(,R13)           Get previous save area
         L     R10,24(,R1)          Caller's R1 now in R10
*
*  Set up and issue an ABEND
         L     R2,PARM1(,R10)       Parm 1 - &ABEND code
         L     R2,0(,R2)                     ABEND code
         L     R3,PARM2(,R10)       Parm 2 - &Reason
         L     R3,0(,R3)                     Reason
*
         ABEND (R2),,,,REASON=(R3)

Charles

On Thu, 4 Sep 2025 12:37:29 +0000, Peter Relson <[email protected]> wrote:

>If you look at the interface definition files provided by IBM for its 
>"callable services" you will see definition of the linkage as OS31_NOSTACK or 
>OS64_NOSTACK. They used to use OS but I recollect that this was 
>(unfortunately, and wrongly in my opinion) changed incompatibly not to mean 
>what it was created/defined to mean.
>
>That is how you tell the compiler to build a "standard" parameter list to 
>provide to the target routine, located by register 1.
>
>Peter RelsonĀ 
>
>----------------------------------------------------------------------
>For IBM-MAIN subscribe / signoff / archive access instructions,
>send email to [email protected] with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to