The result of this operation replaces the former contents of
word 2. Word 2 now contains the original value of word 1.
Lastly, execution of the instruction
Machine FormatOp Code L Bl Dl B2 02 Assembler Format OpCode 01 (L,B
1
),02(B
2
)XC 0(4,7),8(7)
produces the following result:
Word 1:0000 0000 0000 0000 0000 0011 1001 00012 :=00 00 03 91
Word 2:0000 0000 0000 0000 0001 0111 1001 00002 := 00 00 17 90 Result: 0000 0000 0000 0000 0001 0100 0000 00012 := 00 00 14 01 The result of this operation replaces the former contents of
word 1. Word 1 now contains the original value of word 2.
Notes:
1. With theXC instruction, fields up to 256 bytes in length
can be exchanged.
2. With the XR the contents of two registers
can be exchanged.
3. Because the X instruction operates storage-to-register
only, an exchange cannot be made solely by the use of
x.
4. A fieldEXCLUSIVE ORed with itself is cleared to zeros.
Execute (EX)
TheEXECUTE instruction causes one instruction in main
storage to be executed out of sequence without actually
branching to the object instruction.EXECUTE may be
used to supply the length field for an SS instruction without
modifying the SSinstruction in storage. For example, as sume that a MOVE (MVC) instruction is located at address 3820, with a fonnat as follows:
Machine FormatOp Code L Bl Dl B2 02 Assembler Format OpCode Dl (L,B
1
),D2(B
2
)MVC 3(1,12),0(13)
where register 12 contains00 00 89 13 and register 13
contains00 00 90 AO. Further assume that at storage address 5000, the following EXECUTE instruction is located:
298 System/370Principles of Operation
Machine Format
4411 1 0 I A 000 A sse mbler Format Op Code R
1
, D2 (X
2
, B
2
)
EX1,0(0,10) where register 10 contains 00 00 38 20 and register 1 con tains 00 OF FO 03. When the instruction at 5000 is executed, bits 24-31 of
register 1 areORed with bits 8-15 of the instruction at 3820: Bits 8-15: 0000 00002 = 00 Bits 24-31: 0000 00112 = 03 Result: 0000 0011
2 = 03 causing the instruction at 3820 to be executed as if it orig inally were:
Machine FormatOp Code L
D203 I C I Assembler Format Op Code Dl (L, B
1
), D2 (B
2
)MVC 3(4,12),0(13)
However, after execution:
Register 1 is unchanged003 [he instruction at 3820 is l.lflchanged D 000 The contents of the four bytes starting atlocation 90AOhave been
moved to the four bytes starting at location 8916
TheCPU next executes the instruction at address 5004 (PSW bits 40-63 contain 00 50 04) Load (L, LR)
TheLOAD instructions place, unchanged, the contents of
a word in storage or of a register into another register. For
example, assume that the four bytes starting with location21004 (a fullword boundary) are to be loaded into register 10. Initially:
Register 5 contains00 02 00 00 Register 6 contains 00 00 10 04 The contents of register 10 are not significant
Storage locations21004-21007 contain 00 00 AB CD
To load register10, the RX form of the instruction can
be used:
Machine FormatOp Code Rl X
2
B2000 Assembler Format Op Code R
1
, D2 (X
2
, B
2
)
L10,0(5,6)
word 2. Word 2 now contains the original value of word 1.
Lastly, execution of the instruction
Machine Format
1
),02(B
2
)
produces the following result:
Word 1:
Word 2:
word 1. Word 1 now contains the original value of word 2.
Notes:
1. With the
can be exchanged.
2. With the XR
can be exchanged.
3. Because the X instruction operates storage-to-register
only, an exchange cannot be made solely by the use of
x.
4. A field
Execute (EX)
The
storage to be executed out of sequence without actually
branching to the object instruction.
used to supply the length field for an SS instruction without
modifying the SS
Machine Format
1
),D2(B
2
)
where register 12 contains
contains
298 System/370
Machine Format
44
1
, D2 (X
2
, B
2
)
EX
register 1 are
2
Machine Format
D2
1
), D2 (B
2
)
However, after execution:
Register 1 is unchanged
moved to the four bytes starting at location 8916
The
The
a word in storage or of a register into another register. For
example, assume that the four bytes starting with location
Register 5 contains
Storage locations
To load register
be used:
Machine Format
2
B2
1
, D2 (X
2
, B
2
)
L