Search code examples
assemblymainframe

Format of CLI instructions in IBM 360


I have a instruction CLI =F'3',3 I want to know whether it will compare the value 3 with the contents of register 3 or will it compare value 3 with other value '3'. please help me.


Solution

  • Everything you'd ever want to know about IBM360 is here:
    http://bitsavers.trailing-edge.com/pdf/ibm/360

    The assembly language is explained in: http://bitsavers.trailing-edge.com/pdf/ibm/360/asm/C28-6514-5_IBM_System_360_Assembler_Language_Level_E_F_Dec67.pdf

    CLI stands for logical compare immediate.
    So you should know you're comparing against an immediate, not the contents of a register.

    Here's the relevant section of that manual:

    enter image description here

    Note that you're using the implicit operand version, so the relevant column is 5, not 4.
    S1 is the storage register.
    I2 is the immediate value S1 is compared with.

    So the answer is option A:

    it will compare the value 3 with the contents of register 3

    See page 119 and 120 for details.