Motorola DSP96002 User Manual page 674

32-bit digital signal processor
Table of Contents

Advertisement

_inan
ori
_qnan
move
move
move
ori
jmp
;
; Check if Addend 0 is a Denormalized Number
;
_mant3
tst
jne
tst
jne
cmp
jgt
;
; Check if Addend 1 is a Denormalized Number
;
_mant4
tst
jne
tst
jne
jclr
jmp
;
; Addend 0 is a Denormalized Number
;
_den0
bset
inc
tst
jgt
tst
jne
tst
jne
jmp
_bden
bset
inc
_ftz
jclr
jmp
;
; Addend 1 is a Denormalized Number
;
_den1
jclr
bset
inc
jclr
_tfr
move
move
move
and
cmp
jne
move
MOTOROLA
#$10,ier
; set invalid operation bit
#qnane,d1.h
; get QNaN exponent
#qnanmh,d1.m
; get QNaN mantissa high
#qnanml,d1.l
; get QNaN mantissa low
#$20,ccr
; set Not-a-Number bit
_done
; result is a NaN
d2
; check mant0.high = zero
_den0
; jump if a0 is a denorm
d0
; check mant0.low = zero
_den0
; jump if a0 is a denorm
d7,d5
; check min exp for a1
_done
; a1 is the answer
d3
; check mant1.high = zero
_den1
; jump if a1 is a denorm
d1
; check mant1.low = zero
_den1
; jump if a1 is a denorm
#0,d6.l,_bzero
; jump if both are zero
_tfr
; move result to d1
#0,d0.h
; get denorm exponent
d4
;
d5
; check if a1 is a denorm
_ftz
; jump if a1 is a normal number
d3
; check mant1.high = zero
_bden
; jump if a1 is a denorm
d1
; check mant1.low = zero
_bden
; jump if a1 is a denorm
_tfr
; move result to d1
#0,d1.h
; get denorm exponent
d5
;
#27,sr,_nadd
; jump to add for ieee mode
_done
; a0 is flushed-to-zero
#0,d6.l,_done
; a1 is the answer
#0,d1.h
; get denorm exponent
d5
;
#27,sr,_nadd
; jump to add for ieee mode
#eden,d7.l
; get denorm exponent
d0.h,d5.l
; get expr
#emsk,d4.l
; get exponent mask
d4,d5
; delete tags and sign
d7,d5
d0.h,d5.l ; compare exps, get expr
_tmov
; jump if not a denorm
d0.m,d3.l
; get mantr.high
DSP96002 USER'S MANUAL
"
"
"
B-155

Advertisement

Table of Contents
loading

Table of Contents