HLASM Toolkit Feature User's Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


IF macro option B

HLASM Toolkit Feature User's Guide
GC26-8710-10

Read syntax diagramSkip visual syntax diagram
>>-IF--(instruction mnemonic,parm1,parm2,condition)------------><

Option B needs all four parameters.

The instruction mnemonic is any other than a compare, that sets the condition code. (Use option A if the condition code has been set previously.)

The parameters parm1 and parm2 are the two fields associated with the instruction.

Condition is the value that the condition code mask must assume for the THEN clause to be executed. The condition parameter is either one of the condition mnemonics given in Table 1, or a numeric condition code mask.

This example of option B:
        IF  (TM,BYTE,X'80',Z)  THEN
          Code for F1
        ELSE
          Code for B2
        ENDIF
produces:
        IF  (TM,BYTE,X'80',Z)  THEN
               TM              BYTE,X'80'
          BC    15-8,#@LB1
          Code for F1
        ELSE
          BC    15,#@LB3
#@LB1     DC    0H
          Code for B2
        ENDIF
#@LB3     DC    0H
Option B also provides for three-operand instructions such as those that are available on the System/370. For example:
        IF  (ICM,R1,M3,B2(D2),4)
produces:
        ICM  R1,M3,B2(D2)
          BC    15-4,L1

In all option B formats, the instruction is coded first, followed by the appropriate operands in the same order as used in open code, and followed by the condition operand.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014