Data transformation instructions produce new data from one or more source operands. The new data is placed into the destination register. There are 4 types of data transformation instructions.
Instruction | Operation | |
---|---|---|
add | Rd, Rs1, Rcs2 | add int |
div | Rd, Rs1, Rcs2 | divide int |
mul | Rd, Rs1, Rcs2 | multiply int |
neg | Rd, Rs | negate int (with overflow) |
negu | Rd, Rs | negate int (without overflow) |
rem | Rd, Rs1, Rcs2 | divide int (Rd = remainder) |
sub | Rd, Rs1, Rcs2 | subtract int |
Instruction | Operation | |
---|---|---|
add | Rd, Rs1, Rcs2 | add int |
div | Rd, Rs1, Rcs2 | divide int |
mul | Rd, Rs1, Rcs2 | multiply int |
neg | Rd, Rs | negate int |
rem | Rd, Rs1, Rcs2 | divide int (Rd = remainder) |
sub | Rd, Rs1, Rcs2 | subtract int |
Instruction | Operation | |
---|---|---|
abs.d | Rd, Rs | absolute value double |
abs.s | Rd, Rs | absolute value float |
add.d | Fd, Fs1, Fcs2 | add double |
add.s | Fd, Fs1, Fcs2 | add float |
div.d | Fd, Fs1, Fcs2 | divide double |
div.s | Fd, Fs1, Fcs2 | divide float |
mul.d | Fd, Fs1, Fcs2 | multiply double |
mul.s | Fd, Fs1, Fcs2 | multiply float |
neg.d | Fd, Fs | negate double |
neg.s | Fd, Fs | negate float |
sub.d | Fd, Fs1, Fcs2 | subtract double |
sub.s | Fd, Fs1, Fcs2 | subtract float |
Instruction | Operation | |
---|---|---|
abs.d | Rd, Rs | absolute value double |
add.d | Fd, Fs1, Fcs2 | add double |
div.d | Fd, Fs1, Fcs2 | divide double |
mul.d | Fd, Fs1, Fcs2 | multiply double |
neg.d | Fd, Fs | negate double |
sub.d | Fd, Fs1, Fcs2 | subtract double |
Instruction | Operation | |
---|---|---|
and | Rd, Rs1, Rcs2 | bitwise and |
nand | Rd, Rs1, Rcs2 | bitwise nand |
nor | Rd, Rs1, Rcs2 | bitwise nor |
not | Rd, Rs | bitwise not |
or | Rd, Rs1, Rcs2 | bitwise or |
rol | Rd, Rs1, Rcs2 | left rotate |
ror | Rd, Rs1, Rcs2 | right rotate |
sll | Rd, Rs1, Rcs2 | left shift |
sra | Rd, Rs1, Rcs2 | arithmetic (sign extended) right shift |
srl | Rd, Rs1, Rcs2 | logical (zero extended) right shift |
xor | Rd, Rs1, Rcs2 | bitwise exclusive or |
For shift and rotate instructions Rcs2 specifies the shift amount.
Instruction | Operation | |
---|---|---|
cvt.d.s | Fd, Fs | convert float to double |
cvt.d.w | Fd, Rs | convert integer to double |
cvt.s.d | Fd, Fs | convert double to float |
cvt.s.w | Fd, Rs | convert integer to float |
cvt.w.d | Rd, Fs | convert double to integer |
cvt.w.s | Rd, Fs | convert float to integer |