Subi, Subo - Intel i960 Jx Developer's Manual

Microprocessor
Table of Contents

Advertisement

INSTRUCTION SET REFERENCE
6.2.65

subi, subo

Mnemonic:
subi
subo
Format:
sub*
Description:
Subtracts src1 from src2 and stores the result in dst. The binary results from
these two instructions are identical. The only difference is that
signal an integer overflow.
Action:
subo:
dst = (src2 - src1)[31:0];
subi:
true_result = (src2 - src1);
dst = true_result[31:0];
if((true_result > (2**31) - 1) || (true_result < -2**31)) # Check for overflow
{
if(AC.om == 1)
else
}
STANDARD
Faults:
ARITHMETIC.OVERFLOW
Example:
subi g6, g9, g12
Opcode:
subi
subo
See Also:
addi, addo, subc, addc
6-112
Subtract Integer
Subtract Ordinal
src1,
src2,
reg/lit
reg/lit
AC.of = 1;
generate_fault(ARITHMETIC.OVERFLOW);
Refer to
For
# g12
593H
REG
592H
REG
dst
reg
section 6.1.6, "Faults" (pg.
subi.
g9 - g6
can
subi
6-5).

Advertisement

Table of Contents
loading

Table of Contents