Hi, Paul --
In a BAKR R14,R15 instruction, the R14 value is the value to which the
branched-to routine will return when it executes the PR. So your statement
"Register 14 (operand 1) would contain the next sequential instruction" is
correct if you're talking about the value of R14 _before_ the execution of
the BAKR. If you want the branched-to routine to return to the instruction
after the BAKR, you should code BAKR 0,R15. This will save the instruction
after the BAKR as the return value in the linkage stack.
Depending on what R14 was set to before the BAKR was executed, this would
explain the behavior that you're seeing. The value in the register denoted
by operand 1 (in this case R14) is unaffected by the BAKR instruction.
HTH,
Gary
-Original Message-
From: IBM Mainframe Assembler List On
Behalf Of esst...@juno.com
Sent: Sunday, May 27, 2018 4:10 PM
To: ASSEMBLER-LIST@LISTSERV.UGA.EDU
Subject: BAKR Instruction
Hi,
.
Question About the BAKR Instruction
.
.
I thought I understood the BAKR instruction.
.
I load the address of a load module into Register 15 Then I issue a BAKR
R14,R15 .
My understanding is that a Linkage stack entry is created And The PSW would
be updated with the Address in R15 (operand 2).
Register 14 (operand 1) would contain the next sequential instruction.
.
Do I understand this correctly.
.
The Sub-routine which was brought into memory via a LOAD does get invoked.
.
It does not have a BAKR not a SAVE macro as its first instruction.
It actually issues an LARL instruction to set a Base Register and then
issues a STORAGE OBTAIN to get working storage.
.
When The Sub-Routine exits and returns to the calling module.
It issues a STORAGE Release and a Program Return (PR) instruction.
.
There is a WTO Identifying the SUB-Routine was entered and another WTO
stating the SUB-Routine is exiting.
.
What it looks like - is the PR instruction returns to the beginning of the
Sub-Routine as it goes into a loop producing thousands of wto Entering and
Exiting Messages.
.
Any Ideas as to how to proceed.
.
Paul D'Angelo
.
.