360 Assembly/360 Instructions/EX
< 360 Assembly < 360 InstructionsEX - EXecute - Opcode X / Decimal
Format
- BCTR R1,0
- EX R1,LABEL
- LABEL PACK PACKIT,0(L,R3)
- L will be replaced with last byte value of R1
Availability
The EX instruction is available on all models, 360, 370 and z/System.
Purpose of Instruction
The EX instruction is used to allow a program to modify itself in order to change certain arguments of other instructions without acrually modifying the program's code. One use could be to move a string of 256 bytes or less, by executing an MVC instruction where the EX instruction changes the length value in that instruction.
Exceptions and Faults
- If the target instruction is itself an EX instruction, an Execute Exception occurs
- If the target instruction is not on an even address, an Address Exception occurs
- If the target instruction does not contain a valid opcode, an Operation Exception occurs
- If the target instruction is a privileged instruction, a Protect Violate exception occurs unless this task has the privileged bit in the PSW set
- If the instruction to be executed has an exception, that exception will be thrown
Previous Instruction XXX |
360 Assembly Instructions | Next Instruction XX |
Previous Opcode 00 |
Next Opcode 00 |
360 Assembly Language | |
360 Family | Introduction · Basic FAQ · 360 Family · 360 Architecture |
---|---|
360 Instruction Set | 360 Instructions · Branch Instructions · Data Transfer Instructions · Control Flow Instructions · Arithmetic Instructions · Logic Instructions · Shift and Rotate Instructions · Other Instructions |
Syntaxes and Assemblers | 360 Assemblers· Pseudo Instructions |
Instruction Extensions | Floating Point · High-Level Languages |
This article is issued from Wikibooks. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.