NORM Normalize Integer
3-192 Instruction Set SPRU733
Normalize IntegerNORM
Syntax NORM (.unit) src2, dst
.unit = .L1 or .L2
Compatibility C62x, C64x, C67x, and C67x+ CPU
Opcode
31 29 28 27 23 22 18 17 13 12 11 5 4 3 2 1 0
creg z dst src2 00000x op 110s p
3 1 5 5 1 7 1 1
Opcode map field used... For operand type... Unit Opfield
src2
dst
xsint
uint
.L1, .L2 1100011
src2
dst
slong
uint
.L1, .L2 1100000
Description The number of redundant sign bits of src2 is placed in dst. Several examples
are shown in the following diagram.
1 1111111101111111111111111111111
x01xxxxxx xxxxxxxxxxxxxxxxx xxxxxx
In this case, NORM returns 3:
In this case, NORM returns 30:
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
In this case, NORM returns 0:
In this case, NORM returns 31:
x00001xxx xxxxxxxxxxxxxxxxx xxxxxx
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
1 1111111111111111111111111111111
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
src2
src2
src2
src2