s390: clcl instruction requires register pairs for operands
Ensures that the CLCL instruction on s390 uses register pairs for its operands, as required by the architecture.
The CLCL instruction on s390 requires its R1 and R2 operands to designate even-odd pairs of general registers. This commit enforces this requirement by updating the instruction format and adding tests to verify correct operand usage. It prevents specification exceptions that could occur if non-even registers were used.
In Details
The s390 CLCL instruction, a block character move operation, operates on register pairs (R1, R2). These pairs must be even-numbered registers (e.g., R0/R1, R2/R3) to correctly address memory. Previous implementations may not have strictly enforced this, leading to potential exceptions. This change updates opcodes/s390-opc.c and gas/testsuite/gas/s390/esa-g5.* to use the RR_RERE format and add tests.
- CLCL
- A s390 architecture instruction that performs a block character move. It copies a specified number of bytes from a source to a destination memory location.
- s390
- A family of mainframe computer architectures developed by IBM. Binutils includes support for assembling and disassembling code for s390 processors.
- Register Pair
- On s390, certain instructions require two adjacent general-purpose registers to function as a single 64-bit address or data unit. The even-numbered register in the pair typically holds the most significant part, and the odd-numbered register holds the least significant part.
- Specification Exception
- An interrupt or trap generated by the hardware when an instruction is executed with operands or conditions that violate the architecture's rules, preventing correct operation.