fsqrt.d
riscv_unified_db)RV32 / RV64 (Ratified & Standard Extensions)
main
userD, ZdinxSummary
The fsqrt.d instruction computes the square root of fs1 and result is written in fd. It is defined analogously to its single-precision counterpart, but operates on double-precision operands and produces double-precision results.
Syntax / Encoding
fsqrt.d fd, fs1, rm | 010110100000xxxxxxxxxxxxx1010011 (mask=0xfff0007f match=0x5a000053)
Cross-Chip Latency & Throughput (11 cores)
| Microarchitecture | Latency (cycles) | Recip. TP | uops | Ports | Source |
|---|---|---|---|---|---|
| Andes 45-Series | 1 | 1 | 1 | Andes45FDIV | llvm_sched_models |
| MIPS P8700 (RISC-V) | 1 | 1 | 2 | p8700IssueFPUL+p8700FpuApu | llvm_sched_models |
| SiFive 7-Series (U74) | 1 | 1 | 2 | PipeB+FDiv | llvm_sched_models |
| SpacemiT X100 | 1 | 0.5 | 1 | SMTX100_FQ0 | llvm_sched_models |
| SpacemiT X60 (K1) | 1 | 1 | 1 | SMX60_FP | llvm_sched_models |
| Tenstorrent Ascalon-X | 1 | 1 | 1 | AscalonFP | llvm_sched_models |
| XiangShan KunMingHu | 1 | 0.5 | 1 | XSPipeGroupFDIV | llvm_sched_models |
| SiFive P870 / P800 | 29 | 28 | 2 | SiFiveP800FEXQ1+SiFiveP800FloatDiv | llvm_sched_models |
| XiangShan NanHu | 31 | 0.5 | 1 | XS2FMISC | llvm_sched_models |
| Syntacore SCR7 | 32 | 30 | 2 | FPU_IS+FDIVSQRT | llvm_sched_models |
| SiFive P670 / P600 | 33 | 32 | 2 | SiFiveP600FEXQ1+SiFiveP600FloatDiv | llvm_sched_models |
Binary Encodings (1)
| Width | Format | Bit Pattern | Mask / Match |
|---|---|---|---|
| 32 | RV | 010110100000xxxxxxxxxxxxx1010011 | 0xfff0007f / 0x5a000053 |
Operands
| Name | Description |
|---|---|
fs1 | bits [19:15] |
rm | bits [14:12] |
fd | bits [11:7] |
Reference Notes
The `fsqrt.d` instruction computes the square root of `fs1` and result is written in `fd`. It is defined analogously to its single-precision counterpart, but operates on double-precision operands and produces double-precision results.