20 lines
1.1 KiB
Text
20 lines
1.1 KiB
Text
SWAP CSECT , control section start
|
|
BAKR 14,0 stack caller's registers
|
|
LR 12,15 entry point address to reg.12
|
|
USING SWAP,12 use as base
|
|
MVC A,=C'5678____' init field A
|
|
MVC B,=C'____1234' init field B
|
|
LA 2,L address of length field in reg.2
|
|
WTO TEXT=(2) Write To Operator, results in:
|
|
* +5678________1234
|
|
XC A,B XOR A,B
|
|
XC B,A XOR B,A
|
|
XC A,B XOR A,B. A holds B, B holds A
|
|
WTO TEXT=(2) Write To Operator, results in:
|
|
* +____12345678____
|
|
PR , return to caller
|
|
LTORG , literals displacement
|
|
L DC H'16' halfword containg decimal 16
|
|
A DS CL8 field A, 8 bytes
|
|
B DS CL8 field B, 8 bytes
|
|
END SWAP program end
|