fsqrts

Floating Square Root Single

fsqrts FRT, FRB

Computes square root (Single).

Details

Computes the square root of a single-precision floating-point value in FRB and places the double-precision result in FRT. FPSCR exception flags (XX, ZX, UX, OX, VXSQRT) are updated appropriately.

Pseudocode Operation

FRT ← sqrt(FRB)
FPSCR[FPRF, XX, ZX, UX, OX, VXSQRT] ← updated based on operation

Programming Note

The fsqrts instruction is commonly used for calculating the square root of single-precision floating-point numbers. Ensure that the input register FRB contains a valid single-precision float; otherwise, the result may be undefined or trigger an exception. The instruction operates at user privilege level and does not require any specific ordering or alignment of data. Be aware of rounding modes controlled by RN, as they can affect the precision of the result.

Example

fsqrts f1, f3

Encoding

Binary Layout
59
0
FRT
6
0
11
FRB
16
22
21
/
31
 
Format X-form
Opcode 0xEC00002C
Extension Floating-Point
Registers Altered FPSCR

Operands

  • FRT
    Target
  • FRB
    Source