Hi 

I am having all sorts of problems with the TEST Call  subcommand
specifically restoring the USER program R14 value  

The Documentation says the return value whether you use RESUME  "which
specifies upon completion of execution, the called program returns control
to the address of the last breakpoint before the CALL".

In this case r14 points to address of where the breakpoint is 

Or you can explicitly set where you want to return by coding RETURN and
having R14 point to where you want to return 

The problem is in either case one has to set the USER programs R14 back 

What I wanted to do is return to the breakpoint which had the call only this
time without calling the user program  

Now it seems to me the only way to get this done is by 


First Save the address of where the breakpoint is upon entry 
 
Then have R14 point to a DUMMY breakpoint by that I mean you have a workarea
obtained with TEST subcommand  GETMAIN (passed as a parm) to the user prog
have some area 2 bytes with a nop 

X'0700' and in the called program branch back  to it so for example

use the following TEST subcommand
Assume the original R14 was saved in workarea+4 
 
AT WORKAREA+30 (COPY WORKAREA+4 R14 LENGTH(4); AT WORKAREA+40? ; GO
WORKAREA+40?)



This code would 

First seem to go to dummy breakpoint
Second retore the user program value of R14 Third set a breakpoint at the
original breakpoint (without a call) Fourth go to the breakpoint

However I keep on getting a S0C4       


The following is snippets of the user program


USERPROG  CSECT
                           USING R3,USERPROG
                           LR        R3,R15
                          ST        R14,RETURN
                    
                      MVC DUMMYBREAK,=X'0700'

                     LA    R14,DUMMYBREAK
                    BR  R14




 WORKAREA DSECT


 0030       DUMMYBREAK DS XL2       
 0040      RETRUN               DS  A

----------------------------------------------------------------------


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

Reply via email to