Page 1 of 1

AMODE and RMODE why strange

PostPosted: Fri May 06, 2011 2:46 pm
by msnirmal1487
Hi all,

I'm using the following compile JCL to compile two programs (FDUAA & FAAAA).
//CMPLINKJ  EXEC YOPTCLNK                         
//COMP.SYSLIB  DD DSN=MACRO.PRODY2K,DISP=SHR                   
//             DD DSN=MACRO.TRANY2K,DISP=SHR                   
//             DD DSN=MACRO.TESTY2K,DISP=SHR                   
//COMP.SYSIN   DD DSN=MSN.PL1.SOURCE(*),DISP=SHR     << *FAAAA or FDUAA
//LINK.SYSLMOD DD DSN=MSN.COMPL.PL1.LOAD,DISP=SHR           
//LINK.SYSIN   DD *                                                 
 NAME FAABK(R)                                                       
/*                                                                   


But wen i look at the load i could see that
the load of FDUAA is generated with AMODE = 24, RMODE = 24
but
the load of FAAAA is generated with AMODE = 31, RMODE = ANY.

Both are almost similar programs.

Can anyone please explain this behaviour.

Thanks in advance
Nirmal.

Re: AMODE and RMODE why strange

PostPosted: Fri May 06, 2011 3:50 pm
by NicC
does one have dataset use and the other not?

Re: AMODE and RMODE why strange

PostPosted: Sat May 07, 2011 12:19 am
by msnirmal1487
no...

FAAAA program reads 2 datasets in main program and 2 data sets in a called module.
FDUAA program reads 3 datasets in main program and 2 data sets in a called module.

Re: AMODE and RMODE why strange

PostPosted: Sat May 07, 2011 5:12 am
by steve-myers
Unless you tell it differently, the Binder uses the AMODE and RMODE of the input modules (including any modules brought in from SYSLIB) to establish the AMODE and RMODE of the load module it creates. Now I'm not very familiar with the more recent PL/I releases, but the source code may have a mechanism to specify the AMODE and RMODE. This is what you should be investigating.