From 67645c1be4fed113695dcabc31857d769505e2d3 Mon Sep 17 00:00:00 2001 From: saratoga Date: Sun, 29 Jul 2007 05:21:20 +0000 Subject: [PATCH] Fix mp3 playback on the gigabeat by not putting code in IRAM. Someone actually familar with the gigabeat port should check this. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14050 a1c6a512-1295-4272-9138-f99709370657 --- apps/codecs/libmad/dct32_arm.S | 2 +- apps/codecs/libmad/synth.c | 16 ++++++++-------- apps/codecs/libmad/synth_full_arm.S | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/apps/codecs/libmad/dct32_arm.S b/apps/codecs/libmad/dct32_arm.S index 4d94896b0..8ead5af89 100644 --- a/apps/codecs/libmad/dct32_arm.S +++ b/apps/codecs/libmad/dct32_arm.S @@ -23,7 +23,7 @@ /* This performs slower in IRAM on PP502x and there is no space in mpegplayer on the PP5002 */ -#if defined(CPU_PP502x) || (CONFIG_CPU == PP5002 && defined(MPEGPLAYER)) +#if defined(CPU_PP502x) || (CONFIG_CPU == PP5002 && defined(MPEGPLAYER)) || defined(TOSHIBA_GIGABEAT_F) .section .text,"ax",%progbits #else .section .icode,"ax",%progbits diff --git a/apps/codecs/libmad/synth.c b/apps/codecs/libmad/synth.c index c3a868a0d..00e00ad5f 100644 --- a/apps/codecs/libmad/synth.c +++ b/apps/codecs/libmad/synth.c @@ -584,7 +584,7 @@ void synth_full(struct mad_synth *, struct mad_frame const *, */ /* optimised version of synth_full */ -# ifdef FPM_COLDFIRE_EMAC +# ifdef FPM_COLDFIRE_EMAC static void synth_full(struct mad_synth *synth, struct mad_frame const *frame, unsigned int nch, unsigned int ns) @@ -630,7 +630,7 @@ void synth_full(struct mad_synth *synth, struct mad_frame const *frame, "msac.l %%d5, %%a5, 20(%2), %%a5, %%acc0\n\t" "msac.l %%d6, %%a5, 12(%2), %%a5, %%acc0\n\t" "msac.l %%d7, %%a5, (%2), %%a5, %%acc0\n\t" - + "movem.l (%3), %%d0-%%d7\n\t" "mac.l %%d0, %%a5, 56(%2), %%a5, %%acc0\n\t" "mac.l %%d1, %%a5, 48(%2), %%a5, %%acc0\n\t" @@ -713,7 +713,7 @@ void synth_full(struct mad_synth *synth, struct mad_frame const *frame, "mac.l %%d6, %%a5, 12(%2), %%a5, %%acc0\n\t" "mac.l %%d7, %%a5, %%acc0\n\t" "movclr.l %%acc0, %0\n\t" - : "=r" (hi0) : "a" (*fo), "a" (*D0ptr) + : "=r" (hi0) : "a" (*fo), "a" (*D0ptr) : "d0", "d1", "d2", "d3", "d4", "d5", "d6", "d7", "a5"); pcm[0] = -(hi0 << 3); @@ -731,7 +731,7 @@ void synth_full(struct mad_synth *synth, struct mad_frame const *frame, "msac.l %%d5, %%a5, 16(%2), %%a5, %%acc0\n\t" "msac.l %%d6, %%a5, 8(%2), %%a5, %%acc0\n\t" "msac.l %%d7, %%a5, 4(%2), %%a5, %%acc0\n\t" - + "movem.l (%3), %%d0-%%d7\n\t" "mac.l %%d0, %%a5, 60(%2), %%a5, %%acc0\n\t" "mac.l %%d1, %%a5, 52(%2), %%a5, %%acc0\n\t" @@ -814,7 +814,7 @@ void synth_full(struct mad_synth *synth, struct mad_frame const *frame, "mac.l %%d6, %%a5, 8(%2), %%a5, %%acc0\n\t" "mac.l %%d7, %%a5, %%acc0\n\t" "movclr.l %%acc0, %0\n\t" - : "=r" (hi0) : "a" (*fo), "a" (*D0ptr) + : "=r" (hi0) : "a" (*fo), "a" (*D0ptr) : "d0", "d1", "d2", "d3", "d4", "d5", "d6", "d7", "a5"); pcm[0] = -(hi0 << 3); @@ -1044,7 +1044,7 @@ void synth_full2(mad_fixed_t *pcm, mad_fixed_t (*fo)[8], mad_fixed_t (*fe)[8], /* This performs slower in IRAM on PP502x and there is no space in mpegplayer on the PP5002 */ -#if !defined(CPU_PP502x) && !(CONFIG_CPU == PP5002 && defined(MPEGPLAYER)) +#if !defined(CPU_PP502x) && !(CONFIG_CPU == PP5002 && defined(MPEGPLAYER)) && !defined(TOSHIBA_GIGABEAT_F) static void synth_full(struct mad_synth *synth, struct mad_frame const *frame, unsigned int nch, unsigned int ns) ICODE_ATTR; @@ -1117,7 +1117,7 @@ void synth_full(struct mad_synth *synth, struct mad_frame const *frame, D1ptr += 15; fo += 15; fe += 15; - + ptr = *(D0ptr + 1); PROD_ODD_0(hi, lo, *fo, ptr); /* @@ -1166,7 +1166,7 @@ void synth_full(struct mad_synth *synth, struct mad_frame const *frame, D1ptr += 15; fo += 15; fe += 15; - + ptr = *(D0ptr + 1); /* ML0(hi, lo, (*fo)[0], ptr[ 0]); diff --git a/apps/codecs/libmad/synth_full_arm.S b/apps/codecs/libmad/synth_full_arm.S index b880a7b3c..3e81f77ec 100644 --- a/apps/codecs/libmad/synth_full_arm.S +++ b/apps/codecs/libmad/synth_full_arm.S @@ -21,7 +21,7 @@ /* This performs slower in IRAM on PP502x and there is no space in mpegplayer on the PP5002 */ -#if defined(CPU_PP502x) || (CONFIG_CPU == PP5002 && defined(MPEGPLAYER)) +#if defined(CPU_PP502x) || (CONFIG_CPU == PP5002 && defined(MPEGPLAYER)) || defined(TOSHIBA_GIGABEAT_F) .section .text,"ax",%progbits #else .section .icode,"ax",%progbits -- 2.11.4.GIT