The contents of a general purpose register are rotated left a specified number of bits. A generated mask is used to insert a specified bit-field into the corresponding bit-field of another general purpose register.
PowerPC | |
---|---|
rldimi | RA, RS, SH, MB (Rc=0) |
rldimi. | RA, RS, SH, MB (Rc=1) |
The contents of general purpose register (GPR) RS are rotated left the number of bits specified by operand SH. A mask is generated having 1 bits from bit MB through bit 63 - SH and 0 bits elsewhere. The rotated data is inserted into RA under control of the generated mask.
Note that rldimi can be used to insert an n-bit field, that is right-justified in RS, into RA starting at bit position b, by setting SH = 64 - (b + n) and MB = b.
Other registers altered:
Condition Register (CR0 field):
Affected: LT, GT, EQ, SO (if Rc = 1)
This instruction is defined only for 64-bit implementations. Using it on a 32-bit implementation will cause the system illegal instruction error handler to be invoked.