xori or xoril (XOR Immediate) instruction
Purpose
XORs the lower 16 bits of a general-purpose register with a 16-bit unsigned integer and places the result in another general-purpose register.
Syntax
Bits | Value |
---|---|
0-5 | 26 |
6-10 | RS |
11-15 | RA |
16-31 | UI |
Description
The xori and xoril instructions XOR the contents of general-purpose register (GPR) RS with the concatenation of x'0000' and a 16-bit unsigned integer UI and store the result in GPR RA.
The xori and xoril instructions have only one syntax form and do not affect the Fixed-Point Exception Register or Condition Register Field 0.
Parameters
Item | Description |
---|---|
RA | Specifies target general-purpose register where result of operation is stored. |
RS | Specifies source general-purpose register for operation. |
UI | Specifies 16-bit unsigned integer for operation. |
Examples
The following code XORs GPR 4 with 0x0000 5730 and places the result in GPR 6:
# Assume GPR 4 contains 0x7B41 92C0.
xori 6,4,0x5730
# GPR 6 now contains 0x7B41 C5F0.