Texas Instruments TMS320C67X/C67X+ DSP manual SUB2, Src1 and placed in the lower-half of dst

Models: TMS320C67X/C67X+ DSP

1 465
Download 465 pages 63.87 Kb
Page 328
Image 328

SUB2 Subtract Two 16-Bit Integers on Upper and Lower Register Halves

 

 

 

 

Subtract Two 16-Bit Integers on Upper and Lower Register Halves

 

 

SUB2

 

 

 

 

 

Syntax

 

 

 

 

SUB2 (.unit) src1, src2, dst

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

.unit = .S1 or .S2

 

 

 

 

 

 

 

 

 

 

 

 

Compatibility

 

 

C62x, C64x, C67x, and C67x+ CPU

 

 

 

 

 

 

 

 

 

 

Opcode

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

31

29

28

27

23

22

18

17

13

12

11

6

5

4

3

2

1

0

creg

3

z

1

dst

 

src2

src1

 

x

0 1 0 0 0

1

1

0

0

0

s

p

5

 

5

5

1

 

 

 

 

 

 

1

1

 

 

 

 

 

 

 

 

 

 

 

 

 

Opcode map field used...

 

For operand type...

 

 

 

Unit

 

 

 

 

 

 

 

 

 

 

 

 

 

src1

 

sint

 

 

.S1, .S2

 

 

 

src2

 

xsint

 

 

 

 

 

 

 

 

 

dst

 

sint

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Description

The upper and lower halves of src2 are subtracted from the upper and lower

 

halves of src1 and the result is placed in dst. Any borrow from the lower-half

 

subtraction does not affect the upper-half subtraction. Specifically, the

 

upper-half of src2 is subtracted from the upper-half of src1 and placed in the

 

upper-half of dst. The lower-half of src2 is subtracted from the lower-half of

 

src1 and placed in the lower-half of dst.

31

16

15

0

 

 

 

 

 

 

 

a_hi

 

a_lo

 

 

 

 

 

 

 

 

 

src1

SUB2

 

b_hi

 

b_lo

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

31

16

15

0

 

 

 

 

 

 

 

a_hi − b_hi

 

a_lo − b_lo

 

 

 

 

 

 

 

 

 

 

 

src2

dst

3-268

Instruction Set

SPRU733

Page 328
Image 328
Texas Instruments TMS320C67X/C67X+ DSP manual SUB2, Src1 and placed in the lower-half of dst