Subtract Two Signed Integers With Saturation SSUB

Pipeline

 

 

Pipeline

E1

 

 

Stage

 

 

 

 

Read

src1, src2

 

Written

dst

 

Unit in use

.L

 

 

 

Instruction Type

Single-cycle

 

Delay Slots

0

 

See Also

SUB

 

Example 1

SSUB .L2 B1,B2,B3

 

Before instruction

1 cycle after instruction

2 cycles after instruction

B1

5A2E

51A3h

1512984995

B1

 

 

 

 

 

 

 

 

 

 

B2

802A

3FA2h

−2144714846

B2

 

 

 

 

 

 

 

 

B3

xxxx xxxxh

 

B3

 

 

 

 

 

 

 

 

 

 

CSR

0001

0100h

 

CSR

 

 

 

 

 

5A2E 51A3h

802A 3FA2h

7FFF FFFFh

0001 0100h

B1

5A2E 51A3h

 

 

B2 802A 3FA2h

2147483647 B3 7FFF FFFFh

CSR 0001 0300h Saturated

Example 2

SSUB .L1

A0,A1,A2

 

Before instruction

 

1 cycle after instruction

2 cycles after instruction

A0

4367

71F2h

1130852850

A0

 

 

 

 

 

 

 

 

 

 

A1

5A2E

51A3h

1512984995

A1

 

 

 

 

 

 

 

 

A2

xxxx xxxxh

 

A2

 

 

 

 

 

 

 

 

 

 

CSR

0001

0100h

 

CSR

 

 

 

 

 

4367 71F2h

5A2E 51A3h

E939 204Fh

0001 0100h

 

A0

4367

71F2h

 

 

 

 

 

 

 

 

 

 

 

 

A1

5A2E

51A3h

 

 

 

 

 

 

 

 

 

 

 

−382132145

A2

E939

204Fh

 

 

 

 

 

 

 

 

 

 

 

 

CSR

0001

0100h

Not saturated

 

 

 

 

 

SPRU733

Instruction Set

3-235

Page 295
Image 295
Texas Instruments TMS320C67X/C67X+ DSP manual Sub