Lines Matching +full:non +full:- +full:sticky

1 //===----------------------Hexagon builtin routine ------------------------===//
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
56 #define END(TAG) .size TAG,.-TAG
73 ATMP = insert(A,#MANTBITS,#EXPBITS-1)
74 BTMP = asl(B,#EXPBITS-1)
75 TMP = #-BIAS
83 // H <= 2^31-1. L <= 2^32-1. Therefore, HL <= 2^63-2^32-2^31+1
84 // Adding 2 HLs, we get 2^64-3*2^32+2 maximum.
85 // Therefore, we can add 3 2^32-1 values safely without carry. We only need one.
93 BTMP = combine(##BIAS+BIAS-4,#0)
123 p2 = cmp.gt(TMP,#-1)
130 EXP0 = add(EXP0,#-BIAS-58)
143 // Fortunately, this is pretty easy to detect, we must have +/- 0x0010_0000_0000_0000
174 EXP1 = add(EXP0,#-BIAS-58)
182 EXP1 += add(EXP0,##-BIAS-58)
183 //BTMPH = add(clb(ATMP),#-2)
187 p0 = cmp.gt(EXP1,##BIAS+BIAS-2) // overflow
198 // PP_HH has the partial product with sticky LSB.
201 // The exponent of PP_HH is in EXP1, which is non-positive (0 or negative)
208 // * Shift down bits, with sticky bit, such that the bits are aligned according
213 // * Convert [u]d2df -- will correctly round according to rounding mode
221 p3 = cmp.gt(PP_HH_H,#-1) // is it positive?
236 if (!p0.new) PP_HH_L = or(PP_HH_L,S_ONE) // add sticky bit
253 AH = insert(S_ZERO,#EXPBITS-1,#HI_MANTBITS+1) // Insert correct exponent
261 ATMP = combine(##0x7fefffff,#-1) // positive max finite
275 p0 = !cmp.eq(TMP,#1) // If not round-to-zero and
296 // Any NaN --> NaN, possibly raise invalid if sNaN
308 // Infinity * zero --> NaN, raise invalid
323 // If A and B are both very small (exp(a) < BIAS-MANTBITS),
324 // we go to a single sticky bit, which we can round easily.
335 TMP = add(TMP,#-EXPBITS)
342 AH -= asl(TMP,#HI_MANTBITS)
359 BTMPH ^= lsr(AH,#31) // rounding my way --> set LSB
371 A = #-1
389 A = #-1