MSA 011110 |
001 |
df/m |
ws |
wd |
BIT 001010 |
6 |
3 |
7 |
5 |
5 |
6 |
SAT_U.df |
Immediate Unsigned Saturate | |
SAT_U.B wd,ws,m |
MSA |
Immediate Unsigned Saturate |
SAT_U.H wd,ws,m |
MSA |
Immediate Unsigned Saturate |
SAT_U.W wd,ws,m |
MSA |
Immediate Unsigned Saturate |
SAT_U.D wd,ws,m |
MSA |
Immediate Unsigned Saturate |
Immediate Unsigned Saturate
Immediate selected bit width saturation of unsigned values.
wd[i] = saturate_unsigned(ws[i], m+1)
Unsigned elements in vector ws are saturated to unsigned values of m+1 bits without changing the data width. The result is written to vector wd.
The operands and results are values in integer data format df.
No data-dependent exceptions are possible.
SAT_U.B for i in 0 .. WRLEN/8-1 WR[wd]8i+7..8i = sat_u(WR[ws]8i+7..8i, 8, m+1) endfor SAT_U.H for i in 0 .. WRLEN/16-1 WR[wd]16i+15..16i = sat_u(WR[ws]16i+15..16i, 16, m+1) endfor SAT_U.W for i in 0 .. WRLEN/32-1 WR[wd]32i+31..32i = sat_u(WR[ws]32i+31..32i, 32, m+1) endfor SAT_U.D for i in 0 .. WRLEN/64-1 WR[wd]64i+63..64i = sat_u(WR[ws]64i+63..64i, 64, m+1) endfor function sat_u(tt, n, b) if ttn-1..b != 0n-b then return 0n-b || 1b else return tt endif endfunction sat_u
Reserved Instruction Exception, MSA Disabled Exception.