# `roxr`

[M68K Documentation](https://asm-editor.specy.app/documentation/m68k.md) › [Instructions](https://asm-editor.specy.app/documentation/m68k/instruction.md)

Web page: https://asm-editor.specy.app/documentation/m68k/instruction/roxr

**Rotate right with extend**

Category: Shifts and rotates

Rotates the destination to the right through the extend flag.

## Flags

| Flag | Effect |
| --- | --- |
| X | depends on the result |
| N | depends on the result |
| Z | depends on the result |
| V | always 0 |
| C | depends on the result |

Reads: X

## Forms

- `roxr <ea>, Dn` · Sizes .b .w .l, .w by default
  - Source: Dn, #imm
- `roxr <ea>` · Size .w
  - Operand: (An), (An)+, -(An), d(An), d(An,Xn), abs (memory alterable)

## Operands

- [`<ea>`](https://asm-editor.specy.app/documentation/m68k/addressing-mode.md): An operand using one of the addressing modes listed for this form. The list determines whether it can be a register, memory or an immediate value. With `opt p=68020`, an allowed `d(An,Xn)` or `d(PC,Xn)` mode also permits the corresponding 68020 indexed and memory indirect forms. See [68020 addressing](https://asm-editor.specy.app/documentation/m68k/addressing-mode/68020.md).
- [`Dn`](https://asm-editor.specy.app/documentation/m68k/addressing-mode/direct.md): A data register, `d0` to `d7`.
- [`#imm`](https://asm-editor.specy.app/documentation/m68k/addressing-mode/immediate.md): An immediate rotate count from `1` to `8`, for example `#3`.

## Description

The register form takes a data-register or immediate count; the memory form rotates one word by one place.
