Is rs2 a source register in fcvt.s.h?
No. The assembly syntax has rd, rs1 only; the encoded rs2 field selects the source H FP format.
Convert half-precision FP to single-precision FP; widening conversion is exact and does not use rm.
fcvt.s.h reads a half-precision source value from FP register rs1, converts it to a single-precision FP result, and writes FP register rd. In the OP-FP encoding, fmt=S (00) denotes the destination format and rs2=H (10) denotes the source format; this widening conversion is exact and has no rm assembly operand.
Shows the Zfh-extension FCVT flow: decode OP-FP fields, fmt/rs2 conversion selection, rm rounding, read the floating-point source, then write the floating-point destination.
The word is split as an R-type OP-FP instruction; FCVT conversion instructions use opcode 1010011.
H-to-S is a floating-point widening conversion; the current finite example is exact, does not need rm rounding, and leaves example fflags at 0.
H-to-S is a floating-point widening conversion; the current finite example is exact, does not need rm rounding, and leaves example fflags at 0.
This animation shows only Zfh-extension FCVT ISA-visible encoding, source/destination register direction, rounding field, and example fflags; it does not model FPU pipelines, exception handling, NaN payloads, or microarchitecture.
fcvt.s.h is an FP-to-FP format conversion: rd and rs1 are FP registers, fmt encodes destination S, and rs2 encodes source H. The widening conversion is exact and does not use rm.
Understand this scenario with real code like «fcvt.s.h f0, f1 # f0 = (single-precision)(f1 as half-precision)».
Understand this scenario with real code like «fcvt.s.h f0, f1 # f0 = (single-precision)(f1 as half-precision)».
No. The assembly syntax has rd, rs1 only; the encoded rs2 field selects the source H FP format.
It does not. This widening conversion is exact and has no rm assembly operand.
In this form, both rd and rs1 are FP registers; W/WU/L/LU forms convert between integer and FP registers.