SPRUIE9D May 2017 – May 2024 DRA74P , DRA75P , DRA76P , DRA77P
Absolute Value
ABS src2, dst
Functional unit = L
16 bit
15 | 13 | 12 | 10 | 9 | 0 |
dst | src2 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 |
3 | 3 | opcode |
The absolute value of src2 is placed in dst. Note that src2 is considered a signed 32-bit value.
CSR[2]EQ = (dst == 0)
dst = (src2 < 0)? -src2:src2