FMUL.S

RISC-V FMUL.S Instruction Details

Instruction ManualR-type

Performs single-precision floating-point multiplication: rd = rs1*rs2.

Instruction Syntax

fmul.s rd, rs1, rs2, rm
Operand Breakdown
rd: destination floating-point register receiving the formatted result.
rs1/rs2: source floating-point registers; arithmetic/rounding forms with rm use rm or dynamic frm for rounding mode.
FFloating-Point Arithmetic

Instruction Behavior

FMUL.S multiplies single-precision values in rs1 and rs2; result to rd. R-type. Rounding by rm. Subnormals are supported, and applicable IEEE 754 floating-point exception flags are accrued.

Common Usage Scenarios

Floating Point Basic

Understand this scenario with real code like «fmul.s f0, f1, f2 # f0 = f1*f2 (RNE)».

Pre-Use Checklist

Syntax Check
  • Confirm the current instruction format is R-type.
  • Confirm the operand order matches the example.
Semantic Check
  • Ensure the destination register usage is compatible with the calling convention.
  • Confirm this is not the lower-level form of a pseudo-instruction expansion.

Pitfalls / Common Confusions

may cause overflow or underflow