COBOL PASSING PARAMETER TO ASM IN REGISTER 0



Support for OS/VS COBOL, VS COBOL II, COBOL for OS/390 & VM and Enterprise COBOL for z/OS

COBOL PASSING PARAMETER TO ASM IN REGISTER 0

Postby rbarnach1 » Thu Nov 07, 2013 3:20 pm

Hi,

How do I pass a parameter from COBOL to an assembler program? In the Assembler called program, it is expecting the data in REGISTER 0.

Thanks in advance.

Regards,
rbarnach1
 
Posts: 7
Joined: Sat Sep 21, 2013 4:35 am
Has thanked: 0 time
Been thanked: 0 time

Re: COBOL PASSING PARAMETER TO ASM IN REGISTER 0

Postby dick scherrer » Thu Nov 07, 2013 8:12 pm

Hello,

In the Assembler called program, it is expecting the data in REGISTER 0.
I suspect it is Not the data . . . I suspect it is the address to the parm(s).
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: COBOL PASSING PARAMETER TO ASM IN REGISTER 0

Postby chaat » Thu Nov 07, 2013 10:44 pm

assuming that you're running in a Z/OS environment...

this seems strange in that the common linkage convention is that the parameter list is passed as a list of addresses in REGISTER 1.

I'm pretty sure that COBOL would always use REGISTER 1.
chaat
 
Posts: 27
Joined: Sun Aug 16, 2009 11:07 pm
Location: St. Cloud, Minnesota
Has thanked: 0 time
Been thanked: 1 time

Re: COBOL PASSING PARAMETER TO ASM IN REGISTER 0

Postby dick scherrer » Thu Nov 07, 2013 11:16 pm

Yes, it does.

Sorry that my original reply was less than clear . . .

d
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times


Return to IBM Cobol

 


  • Related topics
    Replies
    Views
    Last post