MSA 011110 |
110010101 |
df |
ws |
wd |
2RF 011110 |
6 |
9 |
1 |
5 |
5 |
6 |
FRCP.df |
Vector Approximate Floating-Point Reciprocal | |
FRCP.W wd,ws |
MSA |
Vector Approximate Floating-Point Reciprocal |
FRCP.D wd,ws |
MSA |
Vector Approximate Floating-Point Reciprocal |
Vector Approximate Floating-Point Reciprocal
Vector floating-point reciprocal.
wd[i] = 1.0 / ws[i]
The reciprocals of fl oating-point elements in vector ws are calculated as specif ied below. The result is w ritten to vector wd.
The compliant reciprocal operation is defined as 1.0 divided by element value, where the IEEE Standard for FloatingPoint Arithmetic 754TM-2008 defined divide operation is affected by the rounding mode bits RM and flush-to-zero bit FS in MSA Control and Status Register MSACSR. The compliant reciprocals signal all the exceptions specified by the IEEE Standard for Floating-Point Arithmetic 754TM-2008 for the divide operation.
The reciprocal operation is allowed to be approximate. The approximation differs from the compliant reciprocal representation by no more than one unit in the least significant place. Approximate reciprocal operations signal the Inexact exception if the compliant reciprocal is Inexact or if there is a chance the approximated result may differ from the compliant reciprocal. Approximate reciprocal operations are allowed to not signal the Overflow or Underflow exceptions. The Invalid and divide by Zero exceptions are signaled based on the IEEE Standard for Floating-Point Arithmetic 754TM-2008 defined divide operation.
The operands and results are values in floating-point data format df.
Data-dependent exceptions are poss ible as s pecified by the I EEE Standard for Floating-Point Arithmetic 754TM2008.
FRCP.W for i in 0 .. WRLEN/32-1 WR[wd]32i+31..32i = ReciprocalFP(WR[ws]32i+31..32i, 32) endfor FRCP.D for i in 0 .. WRLEN/64-1 WR[wd]64i+63..64i = ReciprocalFP(WR[ws]64i+63..64i, 64) endfor function ReciprocalFP(tt, ts, n) /* Implementation defined Reciprocal operation. */ endfunction ReciprocalFP
Reserved Instruction Exception, MSA Disabled Exception, MSA Floating Point Exception.