On Thu, 12 Apr 2012 10:14:34 -0500, McKown, John wrote:

>"Has IBM upgraded the PL/AS(current name?) compiler to emit 
>Relative and Immediate instructions?".

Probably, since the R&I facility was required for OS/390 2.10.

>The new instructions may (or may not) be less resource 
>efficient that the older versions.

Well, on the z10, 668 of the 894 instructions are implemented 
entirely in hardware.  I would assume that they are very efficient.

>IMO, the only time to use a relative instruction is in "baseless" 
>code. 

We can disagree here.  I use relative branches in all new code 
unless I need the branch to be indexed.  Relative branches avoid 
Address-Generation-Interlocks.

>Again, the only time to use immediate instructions is when the 
>value is a constant and will fit into a halfword.

For my code, I can not use the Extended-Immediate instructions 
because our customers may be running on processors that do not 
include those instructions.

>Oh, and one other reason to use at least one Branch instruction 
>in your program instead of a Brance Relative. If the start of a 
>program starts with the sequence:
>
>  USING *,15
>  B AROUND
>  DC C'some character string'
>AROUND DS 0H
>
>Then the SYSUDUMP will print "some character string" in the 
>save area trace portion of the dump. In most cases, this 
>works because GPR15 points to the B instruction.

You get the same thing if the first instruction is
  J AROUND

If your program is ATTACHed in AMODE 64, the
  B AROUND
won't work.  In that case, register 15 does not contain the 
entry point address.  You are expected to use relative 
branching.

-- 
Tom Marchant

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

Reply via email to