EasyManua.ls Logo

Infineon TriCore TC1.6E - SUBC - Subtract with Carry

Infineon TriCore TC1.6E
484 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
TriCore
®
TC1.6P & TC1.6E
32-bit Unified Processor Core
Instruction Set
V1.0 2013-07
User Manual (Volume 2) 3-372
SUBC
Subtract With Carry
Description
Subtract the contents of data register D[b] from contents of data register D[a] plus the carry bit minus one. Put the
result in data register D[c]. The operands are treated as 32-bit integers. The PSW carry bit is set to the value of
the ALU carry out.
SUBCD[c], D[a], D[b] (RR)
result = D[a] - D[b] + PSW.C - 1;
D[c] = result[31:0];
carry_out = carry(D[a],~D[b],PSW.C);
Status Flags
Examples
subc d3, d1, d2
See Also
SUB, SUBS, SUBS.U, SUBX
C PSW.C = carry_out;
V overflow = (result > 7FFFFFFF
H
) OR (result < -80000000
H
);
if (overflow) then PSW.V = 1 else PSW.V = 0;
SV if (overflow) then PSW.SV = 1 else PSW.SV = PSW.SV;
AV advanced_overflow = result[31] ^ result[30];
if (advanced_overflow) then PSW.AV = 1 else PSW.AV = 0;
SAV if (advanced_overflow) then PSW.SAV = 1 else PSW.SAV = PSW.SAV;
31
c
28 27
0D
H
20 19
-
18 17
-
16 15
b
12 11
a
8 7
0B
H
0

Table of Contents

Related product manuals