Skip to content

ROR

Operation

Rotates the destination right by the count modulo the selected width without changing FLAGS.

Assembler Syntax

ROR.{L|Q}(z) Rn(s), Rn(d)

ROR.{B|W|L|Q}(z) Rn(s), <ea>(e)

ROR.{B|W|L|Q}(z) imm6(i), <ea>(e)

Privilege

Unprivileged

Repeat eligibility

REP eligible; REPcc observes dst

Rotates the selected-width destination value right by the effective count and writes the result to the destination. The effective count is the count operand modulo the selected operand width: B uses mod 8, W uses mod 16, L uses mod 32, and Q uses mod 64. If the effective count is zero, the selected-width result equals the original selected-width value; an Rn destination is still written and a sub-Q result is zero-extended to 64 bits, while a memory destination rewrites the same selected bytes. FLAGS are unchanged for all counts.

2.75in

Encodings

ROR.{L|Q}(z) Rn(s), Rn(d)

Format: Instruction format for ROR.{L|Q}(z) Rn(s), Rn(d)

Format: Instruction format for ROR.{L|Q}(z) Rn(s), Rn(d)

2.75in ROR.{B|W|L|Q}(z) Rn(s), <ea>(e)

Format: Instruction format for ROR.{B|W|L|Q}(z) Rn(s), <ea>(e)

Format: Instruction format for ROR.{B|W|L|Q}(z) Rn(s), <ea>(e)

dstexcluded: immediate [invalid_destination]

2.75in ROR.{B|W|L|Q}(z) imm6(i), <ea>(e)

Format: Instruction format for ROR.{B|W|L|Q}(z) imm6(i), <ea>(e)

Format: Instruction format for ROR.{B|W|L|Q}(z) imm6(i), <ea>(e)

dstexcluded: immediate [invalid_destination]