2 * qmath functions used in arithmatic and DSP operations where
3 * fractional operations, saturation support is needed.
5 * Copyright (C) 2011, Broadcom Corporation
8 * This is UNPUBLISHED PROPRIETARY SOURCE CODE of Broadcom Corporation;
9 * the contents of this file may not be disclosed to third parties, copied
10 * or duplicated in any form, in whole or in part, without the prior
11 * written permission of Broadcom Corporation.
13 * $Id: qmath.h 241182 2011-02-17 21:50:03Z $
25 qm_mul321616(int16 op1
, int16 op2
);
28 qm_mul16(int16 op1
, int16 op2
);
31 qm_muls321616(int16 op1
, int16 op2
);
34 qm_mulu16(uint16 op1
, uint16 op2
);
37 qm_muls16(int16 op1
, int16 op2
);
40 qm_add32(int32 op1
, int32 op2
);
43 qm_add16(int16 op1
, int16 op2
);
46 qm_sub16(int16 op1
, int16 op2
);
49 qm_sub32(int32 op1
, int32 op2
);
52 qm_mac321616(int32 acc
, int16 op1
, int16 op2
);
55 qm_shl32(int32 op
, int shift
);
58 qm_shr32(int32 op
, int shift
);
61 qm_shl16(int16 op
, int shift
);
64 qm_shr16(int16 op
, int shift
);
73 qm_div_s(int16 num
, int16 denom
);
79 qm_div16(int16 num
, int16 denom
, int16
*qQuotient
);
85 qm_div163232(int32 num
, int32 denom
, int16
*qquotient
);
88 qm_mul323216(int32 op1
, int16 op2
);
91 qm_mulsu321616(int16 op1
, uint16 op2
);
94 qm_muls323216(int32 op1
, int16 op2
);
97 qm_mul32(int32 a
, int32 b
);
100 qm_muls32(int32 a
, int32 b
);
103 qm_log10(int32 N
, int16 qN
, int16
*log10N
, int16
*qLog10N
);
106 qm_1byN(int32 N
, int16 qN
, int32
*result
, int16
*qResult
);
108 #endif /* #ifndef __QMATH_H__ */