In a message dated 8/22/2008 9:39:54 P.M. Central Daylight Time,
[EMAIL PROTECTED] writes:
.Do you have anything that needs re-locating? I would use directed LOAD.
This means statements in your (Lindy's) program (the SRB routine that is to
run in the other address space) like DC A(xxxx), where xxxx is a symbolic
label within the program. If you dynamically acquire storage somewhere
(whether CSA or not) and then move executable code into that storage, which is
one
way to get your SRB routine into CSA, you will have to write the code yourself
to relocate all such address constants. A directed load means you acquire
the storage, then code the LOAD macro to load your module at the specific
address of the storage you just allocated. This assumes your load module is
in a
separately loadable module in a library somewhere. If it is simply a small
part of your program that is not in a separate module, then you will have to
copy the code into the storage yourself, then relocate the address constants
in the copy. Or else relocate them in your code,then copy the code. But
this means your program stores into itself, which may not be a good idea. Or
you could add some code into the SRB routine that does the relocation once it
starts to execute. This is called self-relocating code, and is something I
did a lot of back in the days of DOS/360. Do something like this:
SRBRTN ... beginning of code that runs in SRB mode in another address
space
LA R0,blahblah
ST R0,adressxyz
...
blahblah xxx more executable code
...
adressxyz DC A(blahblah)
This code will correctly relocate the address constant no matter where the
code is loaded into storage.
If you do an undirected LOAD, the LOAD process handles all the relocation of
relocatable address constants into whatever load address the LOAD macro picks
for your module to be loaded into.
Bill Fairchild
Rocket Software
**************It's only a deal if it's where you want to go. Find your travel
deal here.
(http://information.travel.aol.com/deals?ncid=aoltrv00050000000047)
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html