10c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
20c1bc742181ded4930842b46e9507372f0b1b963James Dong *
30c1bc742181ded4930842b46e9507372f0b1b963James Dong * File Name:  armCOMM.h
40c1bc742181ded4930842b46e9507372f0b1b963James Dong * OpenMAX DL: v1.0.2
50c1bc742181ded4930842b46e9507372f0b1b963James Dong * Revision:   12290
60c1bc742181ded4930842b46e9507372f0b1b963James Dong * Date:       Wednesday, April 9, 2008
70c1bc742181ded4930842b46e9507372f0b1b963James Dong *
80c1bc742181ded4930842b46e9507372f0b1b963James Dong * (c) Copyright 2007-2008 ARM Limited. All Rights Reserved.
90c1bc742181ded4930842b46e9507372f0b1b963James Dong *
100c1bc742181ded4930842b46e9507372f0b1b963James Dong *
110c1bc742181ded4930842b46e9507372f0b1b963James Dong *
120c1bc742181ded4930842b46e9507372f0b1b963James Dong * File: armCOMM.h
130c1bc742181ded4930842b46e9507372f0b1b963James Dong * Brief: Declares Common APIs/Data Types used across OpenMAX API's
140c1bc742181ded4930842b46e9507372f0b1b963James Dong *
150c1bc742181ded4930842b46e9507372f0b1b963James Dong */
160c1bc742181ded4930842b46e9507372f0b1b963James Dong
170c1bc742181ded4930842b46e9507372f0b1b963James Dong
180c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifndef _armCommon_H_
190c1bc742181ded4930842b46e9507372f0b1b963James Dong#define _armCommon_H_
200c1bc742181ded4930842b46e9507372f0b1b963James Dong
210c1bc742181ded4930842b46e9507372f0b1b963James Dong#include "omxtypes.h"
220c1bc742181ded4930842b46e9507372f0b1b963James Dong
230c1bc742181ded4930842b46e9507372f0b1b963James Dongtypedef struct
240c1bc742181ded4930842b46e9507372f0b1b963James Dong{
250c1bc742181ded4930842b46e9507372f0b1b963James Dong  OMX_F32 Re; /** Real part */
260c1bc742181ded4930842b46e9507372f0b1b963James Dong  OMX_F32 Im; /** Imaginary part */
270c1bc742181ded4930842b46e9507372f0b1b963James Dong
280c1bc742181ded4930842b46e9507372f0b1b963James Dong} OMX_FC32; /** single precision floating point complex number */
290c1bc742181ded4930842b46e9507372f0b1b963James Dong
300c1bc742181ded4930842b46e9507372f0b1b963James Dongtypedef struct
310c1bc742181ded4930842b46e9507372f0b1b963James Dong{
320c1bc742181ded4930842b46e9507372f0b1b963James Dong  OMX_F64 Re; /** Real part */
330c1bc742181ded4930842b46e9507372f0b1b963James Dong  OMX_F64 Im; /** Imaginary part */
340c1bc742181ded4930842b46e9507372f0b1b963James Dong
350c1bc742181ded4930842b46e9507372f0b1b963James Dong} OMX_FC64; /** double precision floating point complex number */
360c1bc742181ded4930842b46e9507372f0b1b963James Dong
370c1bc742181ded4930842b46e9507372f0b1b963James Dong
380c1bc742181ded4930842b46e9507372f0b1b963James Dong/* Used by both IP and IC domains for 8x8 JPEG blocks. */
390c1bc742181ded4930842b46e9507372f0b1b963James Dongtypedef OMX_S16 ARM_BLOCK8x8[64];
400c1bc742181ded4930842b46e9507372f0b1b963James Dong
410c1bc742181ded4930842b46e9507372f0b1b963James Dong
420c1bc742181ded4930842b46e9507372f0b1b963James Dong#include "armOMX.h"
430c1bc742181ded4930842b46e9507372f0b1b963James Dong
440c1bc742181ded4930842b46e9507372f0b1b963James Dong#define  armPI (OMX_F64)(3.1415926535897932384626433832795)
450c1bc742181ded4930842b46e9507372f0b1b963James Dong
460c1bc742181ded4930842b46e9507372f0b1b963James Dong/***********************************************************************/
470c1bc742181ded4930842b46e9507372f0b1b963James Dong
480c1bc742181ded4930842b46e9507372f0b1b963James Dong/* Compiler extensions */
490c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef ARM_DEBUG
500c1bc742181ded4930842b46e9507372f0b1b963James Dong/* debug version */
510c1bc742181ded4930842b46e9507372f0b1b963James Dong#include <stdlib.h>
520c1bc742181ded4930842b46e9507372f0b1b963James Dong#include <assert.h>
530c1bc742181ded4930842b46e9507372f0b1b963James Dong#include <stdio.h>
540c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armError(str) {printf((str)); printf("\n"); exit(-1);}
550c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armWarn(str) {printf((str)); printf("\n");}
560c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIgnore(a) ((void)a)
570c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAssert(a) assert(a)
580c1bc742181ded4930842b46e9507372f0b1b963James Dong#else
590c1bc742181ded4930842b46e9507372f0b1b963James Dong/* release version */
600c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armError(str) ((void) (str))
610c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armWarn(str)  ((void) (str))
620c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIgnore(a)  ((void) (a))
630c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAssert(a)  ((void) (a))
640c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* ARM_DEBUG */
650c1bc742181ded4930842b46e9507372f0b1b963James Dong
660c1bc742181ded4930842b46e9507372f0b1b963James Dong/* Arithmetic operations */
670c1bc742181ded4930842b46e9507372f0b1b963James Dong
680c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armMin(a,b)             ( (a) > (b) ?  (b):(a) )
690c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armMax(a,b)             ( (a) > (b) ?  (a):(b) )
700c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAbs(a)               ( (a) <  0  ? -(a):(a) )
710c1bc742181ded4930842b46e9507372f0b1b963James Dong
720c1bc742181ded4930842b46e9507372f0b1b963James Dong/* Alignment operation */
730c1bc742181ded4930842b46e9507372f0b1b963James Dong
740c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAlignToBytes(Ptr,N)      (Ptr + ( ((N-(int)Ptr)&(N-1)) / sizeof(*Ptr) ))
750c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAlignTo2Bytes(Ptr)       armAlignToBytes(Ptr,2)
760c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAlignTo4Bytes(Ptr)       armAlignToBytes(Ptr,4)
770c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAlignTo8Bytes(Ptr)       armAlignToBytes(Ptr,8)
780c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armAlignTo16Bytes(Ptr)      armAlignToBytes(Ptr,16)
790c1bc742181ded4930842b46e9507372f0b1b963James Dong
800c1bc742181ded4930842b46e9507372f0b1b963James Dong/* Error and Alignment check */
810c1bc742181ded4930842b46e9507372f0b1b963James Dong
820c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armRetArgErrIf(condition, code)  if(condition) { return (code); }
830c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armRetDataErrIf(condition, code) if(condition) { return (code); }
840c1bc742181ded4930842b46e9507372f0b1b963James Dong
850c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifndef ALIGNMENT_DOESNT_MATTER
860c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIsByteAligned(Ptr,N)     ((((int)(Ptr)) % N)==0)
870c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNotByteAligned(Ptr,N)    ((((int)(Ptr)) % N)!=0)
880c1bc742181ded4930842b46e9507372f0b1b963James Dong#else
890c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIsByteAligned(Ptr,N)     (1)
900c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNotByteAligned(Ptr,N)    (0)
910c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif
920c1bc742181ded4930842b46e9507372f0b1b963James Dong
930c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIs2ByteAligned(Ptr)      armIsByteAligned(Ptr,2)
940c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIs4ByteAligned(Ptr)      armIsByteAligned(Ptr,4)
950c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIs8ByteAligned(Ptr)      armIsByteAligned(Ptr,8)
960c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armIs16ByteAligned(Ptr)     armIsByteAligned(Ptr,16)
970c1bc742181ded4930842b46e9507372f0b1b963James Dong
980c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNot2ByteAligned(Ptr)     armNotByteAligned(Ptr,2)
990c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNot4ByteAligned(Ptr)     armNotByteAligned(Ptr,4)
1000c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNot8ByteAligned(Ptr)     armNotByteAligned(Ptr,8)
1010c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNot16ByteAligned(Ptr)    armNotByteAligned(Ptr,16)
1020c1bc742181ded4930842b46e9507372f0b1b963James Dong#define armNot32ByteAligned(Ptr)    armNotByteAligned(Ptr,32)
1030c1bc742181ded4930842b46e9507372f0b1b963James Dong
1040c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
1050c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armRoundFloatToS16_ref/armRoundFloatToS32_ref/armRoundFloatToS64
1060c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1070c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description:
1080c1bc742181ded4930842b46e9507372f0b1b963James Dong * Converts a double precision value into a short int/int after rounding
1090c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1100c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
1110c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in]  Value                 Float value to be converted
1120c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1130c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
1140c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out] converted value in OMX_S16/OMX_S32 format
1150c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1160c1bc742181ded4930842b46e9507372f0b1b963James Dong */
1170c1bc742181ded4930842b46e9507372f0b1b963James Dong
1180c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S16 armRoundFloatToS16 (OMX_F64 Value);
1190c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armRoundFloatToS32 (OMX_F64 Value);
1200c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S64 armRoundFloatToS64 (OMX_F64 Value);
1210c1bc742181ded4930842b46e9507372f0b1b963James Dong
1220c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
1230c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armSatRoundFloatToS16_ref/armSatRoundFloatToS32
1240c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1250c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description:
1260c1bc742181ded4930842b46e9507372f0b1b963James Dong * Converts a double precision value into a short int/int after rounding and saturation
1270c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1280c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
1290c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in]  Value                 Float value to be converted
1300c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1310c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
1320c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out] converted value in OMX_S16/OMX_S32 format
1330c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1340c1bc742181ded4930842b46e9507372f0b1b963James Dong */
1350c1bc742181ded4930842b46e9507372f0b1b963James Dong
1360c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S16 armSatRoundFloatToS16 (OMX_F64 Value);
1370c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatRoundFloatToS32 (OMX_F64 Value);
1380c1bc742181ded4930842b46e9507372f0b1b963James Dong
1390c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
1400c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armSatRoundFloatToU16_ref/armSatRoundFloatToU32
1410c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1420c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description:
1430c1bc742181ded4930842b46e9507372f0b1b963James Dong * Converts a double precision value into a unsigned short int/int after rounding and saturation
1440c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1450c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
1460c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in]  Value                 Float value to be converted
1470c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1480c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
1490c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out] converted value in OMX_U16/OMX_U32 format
1500c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1510c1bc742181ded4930842b46e9507372f0b1b963James Dong */
1520c1bc742181ded4930842b46e9507372f0b1b963James Dong
1530c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_U16 armSatRoundFloatToU16 (OMX_F64 Value);
1540c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_U32 armSatRoundFloatToU32 (OMX_F64 Value);
1550c1bc742181ded4930842b46e9507372f0b1b963James Dong
1560c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
1570c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armSignCheck
1580c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1590c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description:
1600c1bc742181ded4930842b46e9507372f0b1b963James Dong * Checks the sign of a variable:
1610c1bc742181ded4930842b46e9507372f0b1b963James Dong * returns 1 if it is Positive
1620c1bc742181ded4930842b46e9507372f0b1b963James Dong * returns 0 if it is 0
1630c1bc742181ded4930842b46e9507372f0b1b963James Dong * returns -1 if it is Negative
1640c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1650c1bc742181ded4930842b46e9507372f0b1b963James Dong * Remarks:
1660c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1670c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
1680c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in]	    var     Variable to be checked
1690c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1700c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
1710c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMX_INT --   returns 1 if it is Positive
1720c1bc742181ded4930842b46e9507372f0b1b963James Dong *              returns 0 if it is 0
1730c1bc742181ded4930842b46e9507372f0b1b963James Dong *              returns -1 if it is Negative
1740c1bc742181ded4930842b46e9507372f0b1b963James Dong */
1750c1bc742181ded4930842b46e9507372f0b1b963James Dong
1760c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_INT armSignCheck (OMX_S16 var);
1770c1bc742181ded4930842b46e9507372f0b1b963James Dong
1780c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
1790c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armClip
1800c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1810c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description: Clips the input between MAX and MIN value
1820c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1830c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1840c1bc742181ded4930842b46e9507372f0b1b963James Dong * Remarks:
1850c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1860c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
1870c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Min     lower bound
1880c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Max     upper bound
1890c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] src     variable to the clipped
1900c1bc742181ded4930842b46e9507372f0b1b963James Dong *
1910c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
1920c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMX_S32 --   returns clipped value
1930c1bc742181ded4930842b46e9507372f0b1b963James Dong */
1940c1bc742181ded4930842b46e9507372f0b1b963James Dong
1950c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armClip (
1960c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_INT min,
1970c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_INT max,
1980c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_S32 src
1990c1bc742181ded4930842b46e9507372f0b1b963James Dong        );
2000c1bc742181ded4930842b46e9507372f0b1b963James Dong
2010c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
2020c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armClip_F32
2030c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2040c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description: Clips the input between MAX and MIN value
2050c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2060c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2070c1bc742181ded4930842b46e9507372f0b1b963James Dong * Remarks:
2080c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2090c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
2100c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Min     lower bound
2110c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Max     upper bound
2120c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] src     variable to the clipped
2130c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2140c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
2150c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMX_F32 --   returns clipped value
2160c1bc742181ded4930842b46e9507372f0b1b963James Dong */
2170c1bc742181ded4930842b46e9507372f0b1b963James Dong
2180c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_F32 armClip_F32 (
2190c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_F32 min,
2200c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_F32 max,
2210c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_F32 src
2220c1bc742181ded4930842b46e9507372f0b1b963James Dong        );
2230c1bc742181ded4930842b46e9507372f0b1b963James Dong
2240c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
2250c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armShiftSat_F32
2260c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2270c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description: Divides a float value by 2^shift and
2280c1bc742181ded4930842b46e9507372f0b1b963James Dong * saturates it for unsigned value range for satBits.
2290c1bc742181ded4930842b46e9507372f0b1b963James Dong * Second parameter is like "shifting" the corresponding
2300c1bc742181ded4930842b46e9507372f0b1b963James Dong * integer value. Takes care of rounding while clipping the final
2310c1bc742181ded4930842b46e9507372f0b1b963James Dong * value.
2320c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2330c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
2340c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] v          Number to be operated upon
2350c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] shift      Divides the input "v" by "2^shift"
2360c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] satBits    Final range is [0, 2^satBits)
2370c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2380c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
2390c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMX_S32 --   returns "shifted" saturated value
2400c1bc742181ded4930842b46e9507372f0b1b963James Dong */
2410c1bc742181ded4930842b46e9507372f0b1b963James Dong
2420c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_U32 armShiftSat_F32(
2430c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_F32 v,
2440c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_INT shift,
2450c1bc742181ded4930842b46e9507372f0b1b963James Dong        OMX_INT satBits
2460c1bc742181ded4930842b46e9507372f0b1b963James Dong        );
2470c1bc742181ded4930842b46e9507372f0b1b963James Dong
2480c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
2490c1bc742181ded4930842b46e9507372f0b1b963James Dong * Functions: armSwapElem
2500c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2510c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description:
2520c1bc742181ded4930842b46e9507372f0b1b963James Dong * This function swaps two elements at the specified pointer locations.
2530c1bc742181ded4930842b46e9507372f0b1b963James Dong * The size of each element could be anything as specified by <elemSize>
2540c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2550c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
2560c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMXResult -- Error status from the function
2570c1bc742181ded4930842b46e9507372f0b1b963James Dong */
2580c1bc742181ded4930842b46e9507372f0b1b963James DongOMXResult armSwapElem(OMX_U8 *pBuf1, OMX_U8 *pBuf2, OMX_INT elemSize);
2590c1bc742181ded4930842b46e9507372f0b1b963James Dong
2600c1bc742181ded4930842b46e9507372f0b1b963James Dong
2610c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
2620c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armMedianOf3
2630c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2640c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description: Finds the median of three numbers
2650c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2660c1bc742181ded4930842b46e9507372f0b1b963James Dong * Remarks:
2670c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2680c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
2690c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] fEntry     First entry
2700c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] sEntry     second entry
2710c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] tEntry     Third entry
2720c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2730c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
2740c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMX_S32 --   returns the median value
2750c1bc742181ded4930842b46e9507372f0b1b963James Dong */
2760c1bc742181ded4930842b46e9507372f0b1b963James Dong
2770c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armMedianOf3 (
2780c1bc742181ded4930842b46e9507372f0b1b963James Dong    OMX_S32 fEntry,
2790c1bc742181ded4930842b46e9507372f0b1b963James Dong    OMX_S32 sEntry,
2800c1bc742181ded4930842b46e9507372f0b1b963James Dong    OMX_S32 tEntry
2810c1bc742181ded4930842b46e9507372f0b1b963James Dong    );
2820c1bc742181ded4930842b46e9507372f0b1b963James Dong
2830c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
2840c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function: armLogSize
2850c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2860c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description: Finds the size of a positive value and returns the same
2870c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2880c1bc742181ded4930842b46e9507372f0b1b963James Dong * Remarks:
2890c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2900c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parameters:
2910c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] value    Positive value
2920c1bc742181ded4930842b46e9507372f0b1b963James Dong *
2930c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return Value:
2940c1bc742181ded4930842b46e9507372f0b1b963James Dong * OMX_U8 --   returns the size of the positive value
2950c1bc742181ded4930842b46e9507372f0b1b963James Dong */
2960c1bc742181ded4930842b46e9507372f0b1b963James Dong
2970c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_U8 armLogSize (
2980c1bc742181ded4930842b46e9507372f0b1b963James Dong    OMX_U16 value
2990c1bc742181ded4930842b46e9507372f0b1b963James Dong    );
3000c1bc742181ded4930842b46e9507372f0b1b963James Dong
3010c1bc742181ded4930842b46e9507372f0b1b963James Dong/***********************************************************************/
3020c1bc742181ded4930842b46e9507372f0b1b963James Dong                /* Saturating Arithmetic operations */
3030c1bc742181ded4930842b46e9507372f0b1b963James Dong
3040c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
3050c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatAdd_S32()
3060c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3070c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
3080c1bc742181ded4930842b46e9507372f0b1b963James Dong *   Returns the result of saturated addition of the two inputs Value1, Value2
3090c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3100c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
3110c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value1       First Operand
3120c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value2       Second Operand
3130c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3140c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
3150c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
3160c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3170c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3180c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
3190c1bc742181ded4930842b46e9507372f0b1b963James Dong
3200c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatAdd_S32(
3210c1bc742181ded4930842b46e9507372f0b1b963James Dong                OMX_S32 Value1,
3220c1bc742181ded4930842b46e9507372f0b1b963James Dong                OMX_S32 Value2
3230c1bc742181ded4930842b46e9507372f0b1b963James Dong                );
3240c1bc742181ded4930842b46e9507372f0b1b963James Dong
3250c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
3260c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatAdd_S64()
3270c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3280c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
3290c1bc742181ded4930842b46e9507372f0b1b963James Dong *   Returns the result of saturated addition of the two inputs Value1, Value2
3300c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3310c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
3320c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value1       First Operand
3330c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value2       Second Operand
3340c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3350c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
3360c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
3370c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3380c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3390c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
3400c1bc742181ded4930842b46e9507372f0b1b963James Dong
3410c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S64 armSatAdd_S64(
3420c1bc742181ded4930842b46e9507372f0b1b963James Dong                OMX_S64 Value1,
3430c1bc742181ded4930842b46e9507372f0b1b963James Dong                OMX_S64 Value2
3440c1bc742181ded4930842b46e9507372f0b1b963James Dong                );
3450c1bc742181ded4930842b46e9507372f0b1b963James Dong
3460c1bc742181ded4930842b46e9507372f0b1b963James Dong/** Function :armSatSub_S32()
3470c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3480c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
3490c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Returns the result of saturated substraction of the two inputs Value1, Value2
3500c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3510c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
3520c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value1       First Operand
3530c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value2       Second Operand
3540c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3550c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
3560c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
3570c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3580c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
3590c1bc742181ded4930842b46e9507372f0b1b963James Dong
3600c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatSub_S32(
3610c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S32 Value1,
3620c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S32 Value2
3630c1bc742181ded4930842b46e9507372f0b1b963James Dong                    );
3640c1bc742181ded4930842b46e9507372f0b1b963James Dong
3650c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
3660c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatMac_S32()
3670c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3680c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
3690c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Returns the result of Multiplication of Value1 and Value2 and subesquent saturated
3700c1bc742181ded4930842b46e9507372f0b1b963James Dong *     accumulation with Mac
3710c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3720c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
3730c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value1       First Operand
3740c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value2       Second Operand
3750c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Mac          Accumulator
3760c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3770c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
3780c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
3790c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
3800c1bc742181ded4930842b46e9507372f0b1b963James Dong
3810c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatMac_S32(
3820c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S32 Mac,
3830c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S16 Value1,
3840c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S16 Value2
3850c1bc742181ded4930842b46e9507372f0b1b963James Dong                    );
3860c1bc742181ded4930842b46e9507372f0b1b963James Dong
3870c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
3880c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatMac_S16S32_S32
3890c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3900c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
3910c1bc742181ded4930842b46e9507372f0b1b963James Dong *   Returns the result of saturated MAC operation of the three inputs delayElem, filTap , mac
3920c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3930c1bc742181ded4930842b46e9507372f0b1b963James Dong *   mac = mac + Saturate_in_32Bits(delayElem * filTap)
3940c1bc742181ded4930842b46e9507372f0b1b963James Dong *
3950c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
3960c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] delayElem    First 32 bit Operand
3970c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] filTap       Second 16 bit Operand
3980c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] mac          Result of MAC operation
3990c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4000c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
4010c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]  mac        Result of operation
4020c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4030c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
4040c1bc742181ded4930842b46e9507372f0b1b963James Dong
4050c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatMac_S16S32_S32(
4060c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_S32 mac,
4070c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_S32 delayElem,
4080c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_S16 filTap );
4090c1bc742181ded4930842b46e9507372f0b1b963James Dong
4100c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
4110c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatRoundRightShift_S32_S16
4120c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4130c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
4140c1bc742181ded4930842b46e9507372f0b1b963James Dong *   Returns the result of rounded right shift operation of input by the scalefactor
4150c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4160c1bc742181ded4930842b46e9507372f0b1b963James Dong *   output = Saturate_in_16Bits( ( RightShift( (Round(input) , scaleFactor ) )
4170c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4180c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
4190c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] input       The input to be operated on
4200c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] scaleFactor The shift number
4210c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4220c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
4230c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]            Result of operation
4240c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4250c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
4260c1bc742181ded4930842b46e9507372f0b1b963James Dong
4270c1bc742181ded4930842b46e9507372f0b1b963James Dong
4280c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S16 armSatRoundRightShift_S32_S16(
4290c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_S32 input,
4300c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_INT scaleFactor);
4310c1bc742181ded4930842b46e9507372f0b1b963James Dong
4320c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
4330c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatRoundLeftShift_S32()
4340c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4350c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
4360c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Returns the result of saturating left-shift operation on input
4370c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Or rounded Right shift if the input Shift is negative.
4380c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4390c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
4400c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value        Operand
4410c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] shift        Operand for shift operation
4420c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4430c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
4440c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
4450c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4460c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
4470c1bc742181ded4930842b46e9507372f0b1b963James Dong
4480c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatRoundLeftShift_S32(
4490c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_S32 Value,
4500c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_INT shift
4510c1bc742181ded4930842b46e9507372f0b1b963James Dong                        );
4520c1bc742181ded4930842b46e9507372f0b1b963James Dong
4530c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
4540c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatRoundLeftShift_S64()
4550c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4560c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
4570c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Returns the result of saturating left-shift operation on input
4580c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Or rounded Right shift if the input Shift is negative.
4590c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4600c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
4610c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Value        Operand
4620c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] shift        Operand for shift operation
4630c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4640c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
4650c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
4660c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4670c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
4680c1bc742181ded4930842b46e9507372f0b1b963James Dong
4690c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S64 armSatRoundLeftShift_S64(
4700c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_S64 Value,
4710c1bc742181ded4930842b46e9507372f0b1b963James Dong                        OMX_INT shift
4720c1bc742181ded4930842b46e9507372f0b1b963James Dong                        );
4730c1bc742181ded4930842b46e9507372f0b1b963James Dong
4740c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
4750c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatMulS16S32_S32()
4760c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4770c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
4780c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Returns the result of a S16 data type multiplied with an S32 data type
4790c1bc742181ded4930842b46e9507372f0b1b963James Dong *     in a S32 container
4800c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4810c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
4820c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] input1       Operand 1
4830c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] input2       Operand 2
4840c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4850c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
4860c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
4870c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4880c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
4890c1bc742181ded4930842b46e9507372f0b1b963James Dong
4900c1bc742181ded4930842b46e9507372f0b1b963James Dong
4910c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatMulS16S32_S32(
4920c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S16 input1,
4930c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S32 input2);
4940c1bc742181ded4930842b46e9507372f0b1b963James Dong
4950c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
4960c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armSatMulS32S32_S32()
4970c1bc742181ded4930842b46e9507372f0b1b963James Dong *
4980c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description :
4990c1bc742181ded4930842b46e9507372f0b1b963James Dong *     Returns the result of a S32 data type multiplied with an S32 data type
5000c1bc742181ded4930842b46e9507372f0b1b963James Dong *     in a S32 container
5010c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5020c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
5030c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] input1       Operand 1
5040c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] input2       Operand 2
5050c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5060c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
5070c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation
5080c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5090c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
5100c1bc742181ded4930842b46e9507372f0b1b963James Dong
5110c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armSatMulS32S32_S32(
5120c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S32 input1,
5130c1bc742181ded4930842b46e9507372f0b1b963James Dong                    OMX_S32 input2);
5140c1bc742181ded4930842b46e9507372f0b1b963James Dong
5150c1bc742181ded4930842b46e9507372f0b1b963James Dong
5160c1bc742181ded4930842b46e9507372f0b1b963James Dong/**
5170c1bc742181ded4930842b46e9507372f0b1b963James Dong * Function :armIntDivAwayFromZero()
5180c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5190c1bc742181ded4930842b46e9507372f0b1b963James Dong * Description : Integer division with rounding to the nearest integer.
5200c1bc742181ded4930842b46e9507372f0b1b963James Dong *               Half-integer values are rounded away from zero
5210c1bc742181ded4930842b46e9507372f0b1b963James Dong *               unless otherwise specified. For example 3//2 is rounded
5220c1bc742181ded4930842b46e9507372f0b1b963James Dong *               to 2, and -3//2 is rounded to -2.
5230c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5240c1bc742181ded4930842b46e9507372f0b1b963James Dong * Parametrs:
5250c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Num        Operand 1
5260c1bc742181ded4930842b46e9507372f0b1b963James Dong * [in] Deno       Operand 2
5270c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5280c1bc742181ded4930842b46e9507372f0b1b963James Dong * Return:
5290c1bc742181ded4930842b46e9507372f0b1b963James Dong * [out]             Result of operation input1//input2
5300c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5310c1bc742181ded4930842b46e9507372f0b1b963James Dong **/
5320c1bc742181ded4930842b46e9507372f0b1b963James Dong
5330c1bc742181ded4930842b46e9507372f0b1b963James DongOMX_S32 armIntDivAwayFromZero (OMX_S32 Num, OMX_S32 Deno);
5340c1bc742181ded4930842b46e9507372f0b1b963James Dong
5350c1bc742181ded4930842b46e9507372f0b1b963James Dong
5360c1bc742181ded4930842b46e9507372f0b1b963James Dong/***********************************************************************/
5370c1bc742181ded4930842b46e9507372f0b1b963James Dong/*
5380c1bc742181ded4930842b46e9507372f0b1b963James Dong * Debugging macros
5390c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5400c1bc742181ded4930842b46e9507372f0b1b963James Dong */
5410c1bc742181ded4930842b46e9507372f0b1b963James Dong
5420c1bc742181ded4930842b46e9507372f0b1b963James Dong
5430c1bc742181ded4930842b46e9507372f0b1b963James Dong/*
5440c1bc742181ded4930842b46e9507372f0b1b963James Dong * Definition of output stream - change to stderr if necessary
5450c1bc742181ded4930842b46e9507372f0b1b963James Dong */
5460c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_STREAM stdout
5470c1bc742181ded4930842b46e9507372f0b1b963James Dong
5480c1bc742181ded4930842b46e9507372f0b1b963James Dong/*
5490c1bc742181ded4930842b46e9507372f0b1b963James Dong * Debug printf macros, one for each argument count.
5500c1bc742181ded4930842b46e9507372f0b1b963James Dong * Add more if needed.
5510c1bc742181ded4930842b46e9507372f0b1b963James Dong */
5520c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef DEBUG_ON
5530c1bc742181ded4930842b46e9507372f0b1b963James Dong#include <stdio.h>
5540c1bc742181ded4930842b46e9507372f0b1b963James Dong
5550c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_0(a)                                               fprintf(DEBUG_STREAM, a)
5560c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_1(a, b)                                            fprintf(DEBUG_STREAM, a, b)
5570c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_2(a, b, c)                                         fprintf(DEBUG_STREAM, a, b, c)
5580c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_3(a, b, c, d)                                      fprintf(DEBUG_STREAM, a, b, c, d)
5590c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_4(a, b, c, d, e)                                   fprintf(DEBUG_STREAM, a, b, c, d, e)
5600c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_5(a, b, c, d, e, f)                                fprintf(DEBUG_STREAM, a, b, c, d, e, f)
5610c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_6(a, b, c, d, e, f, g)                             fprintf(DEBUG_STREAM, a, b, c, d, e, f, g)
5620c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_7(a, b, c, d, e, f, g, h)                          fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h)
5630c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_8(a, b, c, d, e, f, g, h, i)                       fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i)
5640c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_9(a, b, c, d, e, f, g, h, i, j)                    fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i, j)
5650c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_10(a, b, c, d, e, f, g, h, i, j, k)                fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i, j, k)
5660c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_11(a, b, c, d, e, f, g, h, i, j, k, l)             fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i, j, k, l)
5670c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_12(a, b, c, d, e, f, g, h, i, j, k, l, m)          fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i, j, k, l, m)
5680c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_13(a, b, c, d, e, f, g, h, i, j, k, l, m, n)       fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i, j, k, l, m, n)
5690c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_14(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o)    fprintf(DEBUG_STREAM, a, b, c, d, e, f, g, h, i, j, k, l, m, n, o)
5700c1bc742181ded4930842b46e9507372f0b1b963James Dong#else /* DEBUG_ON */
5710c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_0(a)
5720c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_1(a, b)
5730c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_2(a, b, c)
5740c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_3(a, b, c, d)
5750c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_4(a, b, c, d, e)
5760c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_5(a, b, c, d, e, f)
5770c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_6(a, b, c, d, e, f, g)
5780c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_7(a, b, c, d, e, f, g, h)
5790c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_8(a, b, c, d, e, f, g, h, i)
5800c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_9(a, b, c, d, e, f, g, h, i, j)
5810c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_10(a, b, c, d, e, f, g, h, i, j, k)
5820c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_11(a, b, c, d, e, f, g, h, i, j, k, l)
5830c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_12(a, b, c, d, e, f, g, h, i, j, k, l, m)
5840c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_13(a, b, c, d, e, f, g, h, i, j, k, l, m, n)
5850c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_PRINTF_14(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o)
5860c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* DEBUG_ON */
5870c1bc742181ded4930842b46e9507372f0b1b963James Dong
5880c1bc742181ded4930842b46e9507372f0b1b963James Dong
5890c1bc742181ded4930842b46e9507372f0b1b963James Dong/*
5900c1bc742181ded4930842b46e9507372f0b1b963James Dong * Domain and sub domain definitions
5910c1bc742181ded4930842b46e9507372f0b1b963James Dong *
5920c1bc742181ded4930842b46e9507372f0b1b963James Dong * In order to turn on debug for an entire domain or sub-domain
5930c1bc742181ded4930842b46e9507372f0b1b963James Dong * at compile time, one of the DEBUG_DOMAIN_* below may be defined,
5940c1bc742181ded4930842b46e9507372f0b1b963James Dong * which will activate debug in all of the defines it contains.
5950c1bc742181ded4930842b46e9507372f0b1b963James Dong */
5960c1bc742181ded4930842b46e9507372f0b1b963James Dong
5970c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef DEBUG_DOMAIN_AC
5980c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODECHANPAIRELT_MPEG4
5990c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODECHANPAIRELT
6000c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODEDATSTRELT
6010c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODEFILLELT
6020c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODEISSTEREO_S32
6030c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODEMSPNS_S32
6040c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODEMSSTEREO_S32_I
6050c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODEPRGCFGELT
6060c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DECODETNS_S32_I
6070c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_DEINTERLEAVESPECTRUM_S32
6080c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_ENCODETNS_S32_I
6090c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_LONGTERMPREDICT_S32
6100c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_LONGTERMRECONSTRUCT_S32
6110c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_MDCTFWD_S32
6120c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_MDCTINV_S32_S16
6130c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_NOISELESSDECODE
6140c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_QUANTINV_S32_I
6150c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_UNPACKADIFHEADER
6160c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACAAC_UNPACKADTSFRAMEHEADER
6170c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_HUFFMANDECODESFBMBP_S32
6180c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_HUFFMANDECODESFB_S32
6190c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_HUFFMANDECODE_S32
6200c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_MDCTINV_S32
6210c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_REQUANTIZESFB_S32_I
6220c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_REQUANTIZE_S32_I
6230c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_SYNTHPQMF_S32_S16
6240c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_UNPACKFRAMEHEADER
6250c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_UNPACKSCALEFACTORS_S8
6260c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACMP3_UNPACKSIDEINFO
6270c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* DEBUG_DOMAIN_AC */
6280c1bc742181ded4930842b46e9507372f0b1b963James Dong
6290c1bc742181ded4930842b46e9507372f0b1b963James Dong
6300c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef DEBUG_DOMAIN_VC
6310c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_AVERAGE_16X
6320c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_AVERAGE_4X
6330c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_AVERAGE_8X
6340c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_DEBLOCKCHROMA_U8_C1IR
6350c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_DEBLOCKLUMA_U8_C1IR
6360c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_DECODECHROMADCCOEFFSTOPAIRCAVLC_U8
6370c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_DECODECOEFFSTOPAIRCAVLC_U8
6380c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_DEQUANTTRANSFORMACFROMPAIR_U8_S16_C1_DLX
6390c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_EXPANDFRAME
6400c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_FILTERDEBLOCKINGCHROMA_HOREDGE_U8_C1IR
6410c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_FILTERDEBLOCKINGCHROMA_VEREDGE_U8_C1IR
6420c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_FILTERDEBLOCKINGLUMA_HOREDGE_U8_C1IR
6430c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_FILTERDEBLOCKINGLUMA_VEREDGE_U8_C1IR
6440c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_PREDICTINTRACHROMA8X8_U8_C1R
6450c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_PREDICTINTRA_16X16_U8_C1R
6460c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_PREDICTINTRA_4X4_U8_C1R
6470c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SADQUAR_16X
6480c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SADQUAR_4X
6490c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SADQUAR_8X
6500c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SAD_16X
6510c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SAD_4X
6520c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SAD_8X
6530c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_SATD_4X4
6540c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_TRANSFORMDEQUANTCHROMADCFROMPAIR_U8_S16_C1
6550c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_TRANSFORMDEQUANTLUMADCFROMPAIR_U8_S16_C1
6560c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_TRANSFORMQUANT_CHROMADC
6570c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P10_TRANSFORMQUANT_LUMADC
6580c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_BLOCKMATCH_HALF_16X16
6590c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_BLOCKMATCH_HALF_8X8
6600c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_BLOCKMATCH_INTEGER_16X16
6610c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_BLOCKMATCH_INTEGER_8X8
6620c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_COMPUTETEXTUREERRORBLOCK_SAD_U8_S16
6630c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_COMPUTETEXTUREERRORBLOCK_U8_S16
6640c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_DCT8X8BLKDLX
6650c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_DECODEBLOCKCOEF_INTER_S16
6660c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_DECODEPADMV_PVOP
6670c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_DECODEVLCZIGZAG_INTER_S16
6680c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_DECODEVLCZIGZAG_INTRAACVLC_S16
6690c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_DECODEVLCZIGZAG_INTRADCVLC_S16
6700c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_ENCODEMV_U8_S16
6710c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_ENCODEVLCZIGZAG_INTER_S16
6720c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_ENCODEVLCZIGZAG_INTRAACVLC_S16
6730c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_ENCODEVLCZIGZAG_INTRADCVLC_S16
6740c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_FINDMVPRED
6750c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_IDCT8X8BLKDLX
6760c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_LIMITMVTORECT
6770c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_MOTIONESTIMATIONMB
6780c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_PADMBGRAY_U8
6790c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_PADMBHORIZONTAL_U8
6800c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_PADMBVERTICAL_U8
6810c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_PADMV
6820c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_QUANTINTER_S16_I
6830c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_QUANTINTRA_S16_I
6840c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_QUANTINVINTER_S16_I
6850c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_QUANTINVINTRA_S16_I
6860c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_TRANSRECBLOCKCEOF_INTER
6870c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXVCM4P2_TRANSRECBLOCKCEOF_INTRA
6880c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* DEBUG_DOMAIN_VC */
6890c1bc742181ded4930842b46e9507372f0b1b963James Dong
6900c1bc742181ded4930842b46e9507372f0b1b963James Dong
6910c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef DEBUG_DOMAIN_IC
6920c1bc742181ded4930842b46e9507372f0b1b963James Dong/* To be filled in */
6930c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* DEBUG_DOMAIN_IC */
6940c1bc742181ded4930842b46e9507372f0b1b963James Dong
6950c1bc742181ded4930842b46e9507372f0b1b963James Dong
6960c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef DEBUG_DOMAIN_SP
6970c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_DOTPROD_S16
6980c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_BLOCKEXP_S16
6990c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_BLOCKEXP_S32
7000c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_COPY_S16
7010c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_DOTPROD_S16
7020c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_DOTPROD_S16_SFS
7030c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTFWD_CTOC_SC16_SFS
7040c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTFWD_CTOC_SC32_SFS
7050c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTFWD_RTOCCS_S16S32_SFS
7060c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTFWD_RTOCCS_S32_SFS
7070c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTGETBUFSIZE_C_SC16
7080c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTGETBUFSIZE_C_SC32
7090c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTGETBUFSIZE_R_S16_S32
7100c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTGETBUFSIZE_R_S32
7110c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINIT_C_SC16
7120c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINIT_C_SC32
7130c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINIT_R_S16_S32
7140c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINIT_R_S32
7150c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINV_CCSTOR_S32S16_SFS
7160c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINV_CCSTOR_S32_SFS
7170c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINV_CTOC_SC16_SFS
7180c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FFTINV_CTOC_SC32_SFS
7190c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FILTERMEDIAN_S32_I
7200c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FILTERMEDIAN_S32
7210c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIRONE_DIRECT_S16_ISFS
7220c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIRONE_DIRECT_S16_I
7230c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIRONE_DIRECT_S16
7240c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIRONE_DIRECT_S16_SFS
7250c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIR_DIRECT_S16_ISFS
7260c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIR_DIRECT_S16_I
7270c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIR_DIRECT_S16
7280c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_FIR_DIRECT_S16_SFS
7290c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIRONE_BIQUADDIRECT_S16_I
7300c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIRONE_BIQUADDIRECT_S16
7310c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIRONE_DIRECT_S16_I
7320c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIRONE_DIRECT_S16
7330c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIR_BIQUADDIRECT_S16_I
7340c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIR_BIQUADDIRECT_S16
7350c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIR_DIRECT_S16_I
7360c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXACSP_IIR_DIRECT_S16
7370c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* DEBUG_DOMAIN_SP */
7380c1bc742181ded4930842b46e9507372f0b1b963James Dong
7390c1bc742181ded4930842b46e9507372f0b1b963James Dong
7400c1bc742181ded4930842b46e9507372f0b1b963James Dong#ifdef DEBUG_DOMAIN_IP
7410c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPBM_ADDC_U8_C1R_SFS
7420c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPBM_COPY_U8_C1R
7430c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPBM_COPY_U8_C3R
7440c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPBM_MIRROR_U8_C1R
7450c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPBM_MULC_U8_C1R_SFS
7460c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_COLORTWISTQ14_U8_C3R
7470c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_RGB565TOYCBCR420LS_MCU_U16_S16_C3P3R
7480c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_RGB565TOYCBCR422LS_MCU_U16_S16_C3P3R
7490c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_RGB565TOYCBCR444LS_MCU_U16_S16_C3P3R
7500c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_RGBTOYCBCR420LS_MCU_U8_S16_C3P3R
7510c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_RGBTOYCBCR422LS_MCU_U8_S16_C3P3R
7520c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_RGBTOYCBCR444LS_MCU_U8_S16_C3P3R
7530c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR420RSZROT_U8_P3R
7540c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR420TORGB565LS_MCU_S16_U16_P3C3R
7550c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR420TORGB565_U8_U16_P3C3R
7560c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR420TORGBLS_MCU_S16_U8_P3C3R
7570c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422RSZCSCROTRGB_U8_C2R
7580c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422RSZROT_U8_P3R
7590c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422TORGB565LS_MCU_S16_U16_P3C3R
7600c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422TORGB565_U8_U16_C2C3R
7610c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422TORGBLS_MCU_S16_U8_P3C3R
7620c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422TORGB_U8_C2C3R
7630c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422TOYCBCR420ROTATE_U8_C2P3R
7640c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR422TOYCBCR420ROTATE_U8_P3R
7650c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR444TORGB565LS_MCU_S16_U16_P3C3R
7660c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCR444TORGBLS_MCU_S16_U8_P3C3R
7670c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCRTORGB565_U8_U16_C3R
7680c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCRTORGB565_U8_U16_P3C3R
7690c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPCS_YCBCRTORGB_U8_C3R
7700c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPPP_GETCENTRALMOMENT_S64
7710c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPPP_GETSPATIALMOMENT_S64
7720c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPPP_MOMENTGETSTATESIZE_S64
7730c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPPP_MOMENTINIT_S64
7740c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPPP_MOMENTS64S_U8_C1R
7750c1bc742181ded4930842b46e9507372f0b1b963James Dong#define DEBUG_OMXIPPP_MOMENTS64S_U8_C3R
7760c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* DEBUG_DOMAIN_IP */
7770c1bc742181ded4930842b46e9507372f0b1b963James Dong
7780c1bc742181ded4930842b46e9507372f0b1b963James Dong
7790c1bc742181ded4930842b46e9507372f0b1b963James Dong#endif /* _armCommon_H_ */
7800c1bc742181ded4930842b46e9507372f0b1b963James Dong
7810c1bc742181ded4930842b46e9507372f0b1b963James Dong/*End of File*/
7820c1bc742181ded4930842b46e9507372f0b1b963James Dong
7830c1bc742181ded4930842b46e9507372f0b1b963James Dong
7840c1bc742181ded4930842b46e9507372f0b1b963James Dong
7850c1bc742181ded4930842b46e9507372f0b1b963James Dong
786