Re: BASR to AMODE 64 (Baseless code)

2019-12-03 Thread Seymour J Metz
I disagree; good practice is to start your code at offset zero and put your data in a LOCTR that goes at the end. But if you want to do it the other way, there is no need to branch around anything. What is the oldest processor you have to support? If you are allowed to use relative, then the

Re: BASR to AMODE 64

2019-12-03 Thread Seymour J Metz
> What does CSECT size have to do with base registers? It's no rocket science. The distance between an instruction and its target determines whether a relative instruction is possible. If the distance is too large then you need to access the target via a register. -- Shmuel (Seymour J.) Metz

Re: BASR to AMODE 64

2019-12-03 Thread Seymour J Metz
I would expect the Binder to detect the error. -- Shmuel (Seymour J.) Metz http://mason.gmu.edu/~smetz3 From: IBM Mainframe Assembler List on behalf of Paul Gilmartin <0014e0e4a59b-dmarc-requ...@listserv.uga.edu> Sent: Tuesday, December 3, 2019

Re: BASR to AMODE 64 (Baseless code)

2019-12-03 Thread Seymour J Metz
If it's large then you'll need three and if it's too long for Load Relative Long then you'll need four. I prefer to break things into smaller assemblies unless there is a good reason to assemble them together. -- Shmuel (Seymour J.) Metz http://mason.gmu.edu/~smetz3

Re: BASR to AMODE 64 (Baseless code)

2019-12-03 Thread Ngan, Robert
We use TWO LOCTR's, one for constants required to be within 4K of the base register and a second for constants only referenced by relative long or long displacement instructions. Useful when your combined constants size exceeds 4K as it moves the "yonder" fields out of the 4K space. I wish

Re: BASR to AMODE 64

2019-12-03 Thread Ed Jaffe
On 12/3/2019 11:07 AM, Paul Gilmartin wrote: Are cross-CSECT relative branches supported? That feels like an invitation to disaster: errors that can not be detected before execution. They have been supported since z/OS 1.7 or 1.8. Very handy to have!!! -- Phoenix Software International

Re: BASR to AMODE 64

2019-12-03 Thread Paul Gilmartin
On 2019-12-03, at 07:10:42, Peter Relson wrote: > > ... And, yes, there are cases were relocation applies even to > use of relative branches. I'll leave that teaser as an exercise for the > readers. > Are cross-CSECT relative branches supported? That feels like an invitation to disaster:

Re: BASR to AMODE 64

2019-12-03 Thread Steve Smith
...inline... On Tue, Dec 3, 2019 at 9:10 AM Peter Relson wrote: > Steve Smith wrote > > I found that a couple of > IBM AMODE 64 callable routines expect R15 to be set to their EPA, although > most do not. I discovered these when I made the calls using JASL ( > > I trust you are aware that

Re: BASR to AMODE 64

2019-12-03 Thread Tom Marchant
On Tue, 3 Dec 2019 09:10:42 -0500, Peter Relson wrote: >I suggest that you look up what the value in reg 15 >means for this case (it should be documented somewhere), and for the other >system-assisted linkage cases. It is documented. For example:

Re: BASR to AMODE 64

2019-12-03 Thread Peter Relson
Steve Smith wrote I found that a couple of IBM AMODE 64 callable routines expect R15 to be set to their EPA, although most do not. I discovered these when I made the calls using JASL ( I trust you are aware that "callable" really does mean using "CALL" (whether in a HLL or, in assembler, by