Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
Converting Housekeeping Instruction To Macro

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & ASSEMBLER
Author Message
yogeshpawar

New User


Joined: 01 Mar 2006
Posts: 17
Location: Sussex-UK

PostPosted: Tue May 13, 2008 6:55 pm    Post subject: Converting Housekeeping Instruction To Macro
Reply with quote

Hi,

The Housekeeping instruction are as follows

Code:

PGM CSECT

      STM R14,R12,12(R13)

      LR R3,R15

      USING PGM,R3               <---- At the start

      LA R12,SAVE

      ST R12,8(,R13)

      ST R13,4(,R12)

      LR R13,R12
      :
      :
      :
      :
      L R13,SAVE+4                  <----- At the end

      LM R14,R12,12(R13)


and the corresponding macro instruction which I think of are

Code:

MACRO  HSKEEP &ACT=,&NAME=,&LABEL=

&LABEL CSECT

       AIF (&ACT EQ 1).FIRST

       AIF (&ACT EQ 2).LAST

.FIRST STM 14,12,12(13)

       LR 3,15

       USING &LABEL,3

       LA 12,&NAME

       ST 12,8(0,13)

       ST 13,4(0,12)

       LR 13,12

       MEXIT

.LAST  L 13,&NAME+4

       LM 14,12,12(13)

       BR 14

       MEND


But while compiling I am getting error as ASMA307E which refers to 'No active USING for operand SAVE'. SAVE is of 18 words. Do I need one more USING or am I doing something wrong? Can you please let me know?
Back to top
View user's profile Send private message
References
PostPosted: Tue May 13, 2008 6:55 pm    Post subject: Re: Converting Housekeeping Instruction To Macro Reply with quote

CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 1088
Location: At my desk

PostPosted: Tue May 13, 2008 7:03 pm    Post subject:
Reply with quote

In
Code:
   MACRO  HSKEEP 1,SAVE,PGM
Where is 'SAVE' defined?
Back to top
View user's profile Send private message
yogeshpawar

New User


Joined: 01 Mar 2006
Posts: 17
Location: Sussex-UK

PostPosted: Tue May 13, 2008 7:06 pm    Post subject: Reply to: Converting Housekeeping Instruction To Macro
Reply with quote

SAVE is 18 word save area defined below at the end
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 1088
Location: At my desk

PostPosted: Tue May 13, 2008 7:13 pm    Post subject: Re: Reply to: Converting Housekeeping Instruction To Macro
Reply with quote

yogeshpawar wrote:
SAVE is 18 word save area defined below at the end
According to your error, it is out of range of any USINGs....
Another CSECT? DSECT?
After a DROP?
More than 4k bytes away?
Back to top
View user's profile Send private message
yogeshpawar

New User


Joined: 01 Mar 2006
Posts: 17
Location: Sussex-UK

PostPosted: Wed May 14, 2008 4:12 pm    Post subject: Reply to: Converting Housekeeping Instruction To Macro
Reply with quote

Thanks for your time. It worked when CSECT statement was removed from Macro.
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 1088
Location: At my desk

PostPosted: Wed May 14, 2008 6:27 pm    Post subject:
Reply with quote

Strange, you lost &LABEL?
How about putting the CSECT
Code:
.FIRST ANOP
&LABEL CSECT
       STM 14,12,12(13)

(I think ANOP is correct....)
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & ASSEMBLER All times are GMT + 6 Hours
Page 1 of 1