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