From 0e5bd54cbb26768a2059ed5aadd7b2c15974fe6f Mon Sep 17 00:00:00 2001 From: Magnus Holmgren Date: Sun, 24 Sep 2006 13:15:24 +0000 Subject: Add profiling support for libfaad, and enable a small optimization. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11037 a1c6a512-1295-4272-9138-f99709370657 --- apps/codecs/libfaad/Makefile | 2 +- apps/codecs/libfaad/fixed.h | 9 +-------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/apps/codecs/libfaad/Makefile b/apps/codecs/libfaad/Makefile index 57c871fba7..1cb6c9246b 100644 --- a/apps/codecs/libfaad/Makefile +++ b/apps/codecs/libfaad/Makefile @@ -16,7 +16,7 @@ endif FAADOPTS = -O2 -Wno-char-subscripts CFLAGS = $(INCLUDES) $(GCCOPTS) $(TARGET_INC) $(FAADOPTS) $(TARGET) \ - $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} + $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} $(PROFILE_OPTS) # This sets up 'SRC' based on the files mentioned in SOURCES include $(TOOLSDIR)/makesrc.inc diff --git a/apps/codecs/libfaad/fixed.h b/apps/codecs/libfaad/fixed.h index 9bd77173c6..7478d2ef0f 100644 --- a/apps/codecs/libfaad/fixed.h +++ b/apps/codecs/libfaad/fixed.h @@ -71,22 +71,15 @@ static INLINE real_t MUL_F(real_t A, real_t B) return A; } -#if 0 -/* this currently provokes an ICE in gcc 3.4.x */ static INLINE real_t MUL_C(real_t A, real_t B) { asm volatile ( "mac.l %[A], %[B], %%acc0\n\t" "movclr.l %%acc0, %[A]\n\t" - "asl.l #3, %[A]" : [A] "+&d" (A) : [B] "r" (B) ); - return A; + return A << 3; } -#else -/* keep this one around until the ICE is solved */ -#define MUL_C(A,B) (real_t)(((int64_t)(A)*(int64_t)(B)+(1 << (COEF_BITS-1))) >> COEF_BITS) -#endif /* MUL_R needs too many shifts for us to just operate on the top 32 bits the emac unit gives as usual, so we do a full 64 bit mul here. */ -- cgit v1.2.3