Extensions
Forms
36 (12 Legacy, 24 EVEX)
Data
Intel XED v2026.08.23

RCR rotates its operand right through the carry flag: CF and the operand form one ring of 9, 17, 33 or 65 bits, so the bit leaving bit 0 goes into CF and the old CF comes in at the top. By one bit, it is a right shift that brings CF in at the top, which is how assembly shifts a number wider than a register right: SHR, or SAR for a signed number, on the highest word, then RCR by 1 on each word below. The same step halves a sum that overflowed: after an ADD that set CF, RCR by 1 gives the true average. RCL is the mirror image, and its page gives the rules for the count, which RCR shares.

OF, and the counts that do nothing

Both manuals define OF for a count of 1 alone, as the exclusive or of the result’s two top bits, that is, the old top bit XOR the old CF. In the 97 recorded cases with a larger masked count, Zen 5 set OF by the same rule. Eight were whole turns, a byte by 9, 18 or 27 or a word by 17, which left the value and CF as they were but changed OF in five; code should not rely on it.

A masked count of 0 changes no flag, and in its 37 such cases Zen 5 changed none. It still wrote a 32-bit register: by 0, 32 or 64, RCR cleared bits 63:32, as any write of a 32-bit register does.

In compiled code

Neither GCC 14 nor Clang 23 used RCR at -O2 in our builds. A 128-bit x >> 1 became SHRD and SHR (SAR when signed). The average of two 64-bit numbers through a 128-bit sum became ADD, ADC and SHRD in GCC, while Clang computed (a & b) + ((a ^ b) >> 1), which needs no carry.

Cost and other forms

AMD’s Zen 5 guide lists RCR with an immediate count as one macro-op with a latency of one cycle, and as microcoded with the count in CL. APX adds forms with a new destination register, but none that leaves the flags alone.

Forms

Every encoding of RCR that Intel XED knows, one row per XED instruction form (iform). How to read the notation.
InstructionEncodingRequires
RCR m8, imm8 RCR_MEMb_IMMbC0 /3 ibBase instruction set
RCR r8, imm8 RCR_GPR8_IMMbC0 /3 ibBase instruction set
RCR m16/32/64, imm8 RCR_MEMv_IMMbC1 /3 ibBase instruction set
RCR r16/32/64, imm8 RCR_GPRv_IMMbC1 /3 ibBase instruction set
RCR m8, 1 RCR_MEMb_ONED0 /3Base instruction set
RCR r8, 1 RCR_GPR8_ONED0 /3Base instruction set
RCR m16/32/64, 1 RCR_MEMv_ONED1 /3Base instruction set
RCR r16/32/64, 1 RCR_GPRv_ONED1 /3Base instruction set
RCR m8, CL RCR_MEMb_CLD2 /3Base instruction set
RCR r8, CL RCR_GPR8_CLD2 /3Base instruction set
RCR m16/32/64, CL RCR_MEMv_CLD3 /3Base instruction set
RCR r16/32/64, CL RCR_GPRv_CLD3 /3Base instruction set
RCR r8, imm8 RCR_GPR8i8_IMM8_APXEVEX.LLZ.NP.MAP4.WIG C0 /3 ibAPX_F
RCR m8, imm8 RCR_MEMi8_IMM8_APXEVEX.LLZ.NP.MAP4.WIG C0 /3 ibAPX_F
RCR r16/32/64, r16/32/64, imm8 NDD RCR_GPRv_GPRv_IMM8_APX_N3EVEX.LLZ.NP.MAP4.SCALABLE C1 /3 ib ND=1APX_F + APX_NCI_NDD_NF
RCR r16/32/64, m16/32/64, imm8 NDD RCR_GPRv_MEMv_IMM8_APX_N3EVEX.LLZ.NP.MAP4.SCALABLE C1 /3 ib ND=1APX_F + APX_NCI_NDD_NF
RCR r8, 1 RCR_GPR8i8_ONE_APXEVEX.LLZ.NP.MAP4.WIG D0 /3APX_F
RCR m8, 1 RCR_MEMi8_ONE_APXEVEX.LLZ.NP.MAP4.WIG D0 /3APX_F
RCR r8, r8, 1 NDD RCR_GPR8i8_GPR8i8_ONE_APX_N3EVEX.LLZ.NP.MAP4.WIG D0 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r8, m8, 1 NDD RCR_GPR8i8_MEMi8_ONE_APX_N3EVEX.LLZ.NP.MAP4.WIG D0 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r16/32/64, 1 RCR_GPRv_ONE_APXEVEX.LLZ.NP.MAP4.SCALABLE D1 /3APX_F
RCR m16/32/64, 1 RCR_MEMv_ONE_APXEVEX.LLZ.NP.MAP4.SCALABLE D1 /3APX_F
RCR r16/32/64, r16/32/64, 1 NDD RCR_GPRv_GPRv_ONE_APX_N3EVEX.LLZ.NP.MAP4.SCALABLE D1 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r16/32/64, m16/32/64, 1 NDD RCR_GPRv_MEMv_ONE_APX_N3EVEX.LLZ.NP.MAP4.SCALABLE D1 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r8, CL RCR_GPR8i8_CL_APXEVEX.LLZ.NP.MAP4.WIG D2 /3APX_F
RCR m8, CL RCR_MEMi8_CL_APXEVEX.LLZ.NP.MAP4.WIG D2 /3APX_F
RCR r8, r8, CL NDD RCR_GPR8i8_GPR8i8_CL_APX_N3EVEX.LLZ.NP.MAP4.WIG D2 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r8, m8, CL NDD RCR_GPR8i8_MEMi8_CL_APX_N3EVEX.LLZ.NP.MAP4.WIG D2 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r16/32/64, CL RCR_GPRv_CL_APXEVEX.LLZ.NP.MAP4.SCALABLE D3 /3APX_F
RCR m16/32/64, CL RCR_MEMv_CL_APXEVEX.LLZ.NP.MAP4.SCALABLE D3 /3APX_F
RCR r16/32/64, r16/32/64, CL NDD RCR_GPRv_GPRv_CL_APX_N3EVEX.LLZ.NP.MAP4.SCALABLE D3 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r16/32/64, m16/32/64, CL NDD RCR_GPRv_MEMv_CL_APX_N3EVEX.LLZ.NP.MAP4.SCALABLE D3 /3 ND=1APX_F + APX_NCI_NDD_NF
RCR r8, r8, imm8 NDD RCR_GPR8i8_GPR8i8_IMM8_APX_N3EVEX.LLZ.NP.MAP4.WIG C0 /3 ib ND=1APX_F + APX_NCI_NDD_NF
RCR r8, m8, imm8 NDD RCR_GPR8i8_MEMi8_IMM8_APX_N3EVEX.LLZ.NP.MAP4.WIG C0 /3 ib ND=1APX_F + APX_NCI_NDD_NF
RCR r16/32/64, imm8 RCR_GPRv_IMM8_APXEVEX.LLZ.NP.MAP4.SCALABLE C1 /3 ibAPX_F
RCR m16/32/64, imm8 RCR_MEMv_IMM8_APXEVEX.LLZ.NP.MAP4.SCALABLE C1 /3 ibAPX_F

Latency and throughput

What the scheduling models of LLVM 23.1.2 give for each form, not measurements: latency / reciprocal throughput in cycles, the ports under them. A row is a model, or models that agree; a dash, a form that its processors lack. Memory forms: latency from the address, ports without the load and store units. Which processors each model covers.
Modelm8, imm8r8, imm8m16, imm8
m32, imm8
m64, imm8
r16, imm8r32, imm8
r64, imm8
m8, 1r8, 1
r16, 1
r32, 1
r64, 1
m16, 1
m32, 1
m64, 1
m8, CLr8, CLm16, CL
m32, CL
m64, CL
r16, CLr32, CL
r64, CL
Sandy Bridge11 / 3.5p053 / 2.67p01511 / 3.5p053 / 2.67p0153 / 2.67p01511 / 3.5p052 / 1p01511 / 3.5p0511 / 3.5p055 / 4p0511 / 3.5p055 / 4p055 / 4p05
Haswell9 / 0.75p01565 / 2p01569 / 0.75p01565 / 2p01565 / 2p01569 / 0.75p01562 / 0.75p01569 / 0.75p015619 / 2.25p015614 / 2.5p015619 / 2.25p015611 / 2p015611 / 2p0156
Broadwell, Skylake, Skylake-SP, Ice Lake8 / 0.75p01565 / 2p01568 / 0.75p01565 / 2p01565 / 2p01568 / 0.75p01562 / 0.75p01568 / 0.75p015618 / 2.25p015614 / 2.5p015618 / 2.25p015611 / 2p015611 / 2p0156
Alder Lake, Sapphire Rapids13 / 1p0 p1 p5 p6 p112 / 1p0 p1 p5 p6 p1112 / 1p0 p1 p5 p6 p112 / 1p0 p1 p5 p6 p112 / 1p0 p1 p5 p6 p1113 / 1p0 p1 p5 p6 p112 / 1p0 p1 p5 p6 p1112 / 1p0 p1 p5 p6 p1120 / 3p0 p1 p5 p6 p119 / 3p0 p1 p5 p6 p1119 / 2p0 p1 p5 p6 p118 / 2p0 p1 p5 p6 p118 / 2p0 p1 p5 p6 p11
Lunar Lake13 / 0.67p0123452 / 0.67p01234512 / 0.67p0123452 / 0.67p0123452 / 0.67p01234513 / 0.67p0123452 / 0.67p01234512 / 0.67p01234520 / 1.5p0123459 / 1.67p01234519 / 1.67p0123458 / 1.17p0123458 / 1.17p012345
Bonnell1 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p01 / 1p0
Silvermont4 / 2IEC0 MEC1 / 1IEC04 / 2IEC0 MEC1 / 1IEC01 / 1IEC04 / 2IEC0 MEC1 / 1IEC04 / 2IEC0 MEC4 / 2IEC0 MEC1 / 1IEC04 / 2IEC0 MEC1 / 1IEC01 / 1IEC0
Piledriver5 / 2EX0 EX112 / 11.5EX0 EX15 / 2EX0 EX110 / 9.5EX0 EX17 / 7EX0 EX15 / 2EX0 EX11 / 1EX0 EX15 / 2EX0 EX15 / 2EX0 EX111 / 11EX0 EX15 / 2EX0 EX19 / 9EX0 EX17 / 6.5EX0 EX1
Zen, Zen 2100 / 0.251 / 0.25ALU0 ALU1 ALU2 ALU3100 / 0.251 / 0.25ALU0 ALU1 ALU2 ALU31 / 0.25ALU0 ALU1 ALU2 ALU3100 / 0.251 / 0.25ALU0 ALU1 ALU2 ALU3100 / 0.25100 / 0.251 / 0.25ALU0 ALU1 ALU2 ALU3100 / 0.251 / 0.25ALU0 ALU1 ALU2 ALU31 / 0.25ALU0 ALU1 ALU2 ALU3
Zen 3, Zen 47 / 4ALU1 ALU23 / 3ALU1 ALU27 / 4ALU1 ALU23 / 3ALU1 ALU23 / 3ALU1 ALU25 / 1ALU1 ALU21 / 1ALU1 ALU25 / 1ALU1 ALU27 / 4ALU1 ALU23 / 3ALU1 ALU27 / 4ALU1 ALU23 / 3ALU1 ALU23 / 3ALU1 ALU2
Jaguar4 / 1ALU0 ALU11 / 0.5ALU0 ALU14 / 1ALU0 ALU11 / 0.5ALU0 ALU11 / 0.5ALU0 ALU14 / 1ALU0 ALU11 / 0.5ALU0 ALU14 / 1ALU0 ALU14 / 1ALU0 ALU11 / 0.5ALU0 ALU14 / 1ALU0 ALU11 / 0.5ALU0 ALU11 / 0.5ALU0 ALU1

Operation

What the forms do, in pseudocode that our tests run against results recorded on real processors. How to read.

All forms but the NDD forms
a = dest.read()
n = count & (0x3F if OSIZE == 64 else 0x1F)   # the count is masked,
k = n % (OSIZE + 1)              # then taken modulo OSIZE + 1: CF is a
                                 # bit of the rotation (9 for 8 bits)
x = cf << OSIZE | a              # CF above the operand
y = x >> k | x << (OSIZE + 1 - k)
r = low(y)
if n != 0:                       # a count of 0 changes no flag
    cf = y >> OSIZE & 1          # the bit rotated out of bit 0; CF as
                                 # it was when k is 0
    flip = msb(r) ^ (r >> (OSIZE - 2) & 1)
    of = flip if n == 1 else UNDEFINED   # the top two bits differ
dest.write(r)                    # even for a count of 0, a 32-bit register
                                 # gets bits 63:32 cleared

Run on AMD Zen 5 (EPYC 9645): 227 cases. The APX forms were not run: none of these processors has APX.

NDD forms
a = src.read()
n = count & (0x3F if OSIZE == 64 else 0x1F)   # the count is masked,
k = n % (OSIZE + 1)              # then taken modulo OSIZE + 1: CF is a
                                 # bit of the rotation (9 for 8 bits)
x = cf << OSIZE | a              # CF above the operand
y = x >> k | x << (OSIZE + 1 - k)
r = low(y)
if n != 0:                       # a count of 0 changes no flag
    cf = y >> OSIZE & 1          # the bit rotated out of bit 0; CF as
                                 # it was when k is 0
    flip = msb(r) ^ (r >> (OSIZE - 2) & 1)
    of = flip if n == 1 else UNDEFINED   # the top two bits differ
dest.write(r)                    # the new destination: bits 63:OSIZE
                                 # cleared, even for 8 and 16 bits

Not run on a processor: none of these processors has APX.

Operands

What each form reads and writes, as Intel XED records it: the operands of its syntax, in order, and the implicit ones that the syntax does not name. How to read.
OperandKindAction
RCR r/m8, imm8 RCR r/m16/32/64, imm8
r/m8/16/32/64explicitread, write
imm8explicitread
RFLAGSimplicitread, write
RCR r/m8, 1 RCR r/m16/32/64, 1
r/m8/16/32/64explicitread, write
1explicitread
RFLAGSimplicitread, write
RCR r/m8, CL RCR r/m16/32/64, CL
r/m8/16/32/64explicitread, write
CLexplicitread
RFLAGSimplicitread, conditional write
RCR r8, r/m8, imm8 NDD RCR r16/32/64, r/m16/32/64, imm8 NDD
r8/16/32/64explicitwrite
r/m8/16/32/64explicitread
imm8explicitread
RFLAGSimplicitread, write
RCR r8, r/m8, 1 NDD RCR r16/32/64, r/m16/32/64, 1 NDD
r8/16/32/64explicitwrite
r/m8/16/32/64explicitread
1explicitread
RFLAGSimplicitread, write
RCR r8, r/m8, CL NDD RCR r16/32/64, r/m16/32/64, CL NDD
r8/16/32/64explicitwrite
r/m8/16/32/64explicitread
CLexplicitread
RFLAGSimplicitread, conditional write

Flags

T tested, M modified, U undefined; blank: not affected. How to read.

Exceptions

The exception class is XED's name for the set of exception conditions that a form follows. How to read.

Legacy forms
none in XED
EVEX forms
APX-EVEX-INT

CPUID and processors

Each form belongs to an XED ISA set. A form can be used when the processor reports every CPUID bit of one of its ISA set's alternatives.

CPUID requirements and processors of the XED ISA sets above. Alternatives are separated by “or”; processors follow XED’s chip model, whose AMD processors end with Zen 2, and the CPU data of this site for Zen 3 to Zen 6.
ISA setCPUIDProcessors
I186

No CPUID bit: part of the base instruction set.

Every x86-64 processor in XED’s model and Zen 3 to Zen 6
I86

No CPUID bit: part of the base instruction set.

Every x86-64 processor in XED’s model and Zen 3 to Zen 6
APX_F

APX_F
CPUID.(EAX=07H,ECX=1):EDX[21] APX_F

Nova Lake, Diamond Rapids
APX_F_N3

APX_F + APX_NCI_NDD_NF
CPUID.(EAX=07H,ECX=1):EDX[21] APX_F
CPUID.(EAX=29H,ECX=0):EBX[0] APX_NCI_NDD_NF

Same as APX_F

More General-purpose instructions

All 109 General-purpose instructions

More APX instructions

All 88 APX instructions

Sources

  1. Intel XED v2026.08.23 (commit 0bcb6237345c): forms, encodings, operands, flags, exception classes, attributes, ISA sets, CPUID bits and chip model.
  2. The CPU data of x86-64.net: Zen 3 to Zen 6, from GCC’s -march feature sets and AMD’s Processor Programming References, which the page of each processor cites.
  3. LLVM 23.1.2's x86 scheduling models (commit 85ac56026243): the latency, reciprocal throughput and ports of each form, as llvm-mca reports them.
  4. Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 2 (325383-093, September 2026): Volume 2B, page 4-533 (RCL/RCR/ROL/ROR)
  5. Intel Advanced Performance Extensions (Intel APX) Architecture Specification, revision 9.0 (355828-009, August 2026)
  6. AMD64 Architecture Programmer's Manual, Volume 3: General-Purpose and System Instructions (24594, rev. 3.39, October 2026)
  7. Software Optimization Guide for the AMD Zen5 Microarchitecture (58455, rev. 1.00, August 2024), Wayback Machine copy of AMD's ZIP

The tables are derived from Intel XED, Copyright Intel Corporation, licensed under the Apache License 2.0; x86-64.net converted and reformatted them. The timings come from LLVM's scheduling models, part of the LLVM Project, licensed under the Apache License 2.0 with LLVM Exceptions. The text is our own.