Motorola DSP96002 User Manual page 664

32-bit digital signal processor
Table of Contents

Advertisement

SP
i nt
jset
-
intu
jset
B.3
IEEE RECOMMENDED FUNCTIONS AND PREDICATES
The following functions are recommended by the IEEE-754 standard but are not required.
Functions that require explicit knowledge of the variable precision and may lead to families of functions on
high level languages are 4, 5, and 10. Functions 1 and 2 have an arithmetic form (signals IOP if the source
is a NaN) and a non-arithmetic form.
B.3.1 Copysign(x,y)
Copysign(x,y) returns y with the sign of x.
fcopys.s
Non-Arithmetic Implementation Of
bclr
jclr
bset
_bitclr
MOTOROLA
I
d0
#20,sr,_error
SP
U
d0
#20,sr,_error
Arithmetic Implementation Of
Copysign(d1,d0)
d1,d0
Copysign(d1,d0)
#31,d0.h
#31,d1.h,_bitclr
#31,d0.h
DSP96002 USER'S MANUAL
;convert to integer
;jump if invalid op set
;convert to integer
;jump if invalid op set
;copy sign of d1 to d0
;clear sign bit
;sign bit clear
;set sign bit
Program ICycles
Words
1
1
2
3
---
--
3
4
Program ICycles
Words
1
1
2
3
---
---
3
4
Program ICycles
Words
1
1
---
---
Totals:
1
1
Program ICycles
Words
2
2
2
3
2
2
---
---
Totals:
6
7
43
B-145

Advertisement

Table of Contents
loading

Table of Contents