Extensions
Forms
4 (4 Legacy)
Data
Intel XED v2026.08.23

FDIVR divides with the operands the other way round from FDIV: the destination receives the source divided by the destination. fdivr st, st(i) computes ST(i) / ST(0) into ST(0), fdivr st(i), st computes ST(0) / ST(i) into ST(i), and the memory forms divide the single or double by ST(0). FDIVRP does the same into ST(i) and pops, and FIDIVR divides an integer. FDIV’s page covers the precision control, the speed and the AT&T names, which swap the R in the forms with ST(i) as destination; FSUBR’s page shows how the encoding pairs the forms.

The destination is the divisor

Every check that FDIV makes on its divisor, FDIVR makes on its destination. A zero in ST(0) with fdivr st, st(i) or a memory operand is a division by zero: ZE, and with it masked an infinity. Zen 5, with ZE unmasked, left ST(0) = +0 alone for 1 / +0 and raised #MF at the next waiting instruction. Zero over zero, through fdivr st(0), st as well, is invalid: IE and, masked, the QNaN indefinite.

Where compilers use it

A reciprocal or a constant over a variable puts the variable second, and the x87 order of loads makes that a reversed division:

  • 1.0L / x on a long double is FLD of x, FLD1 and fdivrp st(1), st in GCC 14 and Clang 23 at -O2;
  • *c / x with a double in memory is FLD of x and fdivr qword ptr [rdi];
  • *n / x with an int is FIDIVR in Clang, and FILD with FDIVP in GCC;
  • with -m32 -march=i386, GCC divides a double in memory by an integer with FILD of the integer and FDIVR of the double.

Overflow left on the stack

With OE unmasked, Zen 5 divided the largest finite value by 0.5, kept the result in ST(0) with its exponent reduced by 24576 and its significand intact, set OE, and raised #MF at the next waiting instruction. Intel’s manual describes this scaling so that a handler can rescale the value; with OE masked the result would be an infinity or the largest finite value, by the rounding mode. AMD’s Zen 5 guide lists FDIVR like FDIV: one macro-op on pipe FP1, a new one every five cycles at most.

Forms

Every encoding of FDIVR that Intel XED knows, one row per XED instruction form (iform). How to read the notation.
InstructionEncodingRequires
FDIVR m32fp FDIVR_ST0_MEMmem32realD8 /7FPU
FDIVR ST(0), st(i) FDIVR_ST0_X87D8 F8+iFPU
FDIVR m64fp FDIVR_ST0_MEMm64realDC /7FPU
FDIVR st(i), ST(0) FDIVR_X87_ST0DC F0+iFPU

Operation

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

Register forms
if empty(dest) or empty(src):
    underflow()                  # IE, SF, C1 = 0
    dest.write(INDEFINITE)       # the QNaN indefinite
else:
    dest.write(div(src, dest))   # reversed: the source divided by
                                 # the destination
c0 = c2 = c3 = UNDEFINED

Run on AMD Zen 5 (EPYC 9645): 26 cases.

Memory forms
if empty(st0):
    underflow()                  # IE, SF, C1 = 0
    st0 = INDEFINITE
else:
    st0 = div(src, st0)          # the single or double over ST(0)
c0 = c2 = c3 = UNDEFINED

Run on AMD Zen 5 (EPYC 9645): 12 cases.

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
FDIVR m32fp FDIVR m64fp
m32/64fpexplicitread
x87 status wordimplicitwrite
FDIVR ST(0), st(i)
ST(0)explicitread, write
st(i)explicitread
x87 status wordimplicitwrite
FDIVR st(i), ST(0)
st(i)explicitread, write
ST(0)explicitread
x87 status wordimplicitwrite

Flags

M modified, U undefined; blank: not affected. How to read.
C0C1C2C3
All forms
UMUU

Attributes

What else XED records about the forms. How to read.

All forms
may abort a TSX transaction

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
X87

FPU
CPUID.01H:EDX[0] FPU

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

More x87 instructions

All 90 x87 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. Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 2 (325383-093, September 2026): Volume 2A, page 3-336 (FDIVR/FDIVRP/FIDIVR)
  4. Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 1 (253665-093, September 2026)
  5. AMD64 Architecture Programmer's Manual, Volume 5: 64-Bit Media and x87 Floating-Point Instructions (26569, rev. 3.16, November 2021), Wayback Machine copy of AMD's PDF
  6. 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 text is our own.