From a26917e2075ccda527f50f1035ae5be19072f81f Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Mon, 12 Mar 2007 08:36:42 +0000 Subject: Coldfire DSP Assembly: Fix a bug in the resampler that would only affect one frame on the transition from up to down. Fix a bug in sample output that could be the cause of reported FLAC glitching. Output routines now pass all alignment and size combination tests. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12733 a1c6a512-1295-4272-9138-f99709370657 --- apps/dsp_cf.S | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/dsp_cf.S b/apps/dsp_cf.S index 497b551be3..af9ac1fa4b 100644 --- a/apps/dsp_cf.S +++ b/apps/dsp_cf.S @@ -170,7 +170,7 @@ dsp_upsample: clr.w %d5 | eor.l %d5, %d6 | pos == 0? beq.b .usstart_0 | no? transistion from down - cmp.l %d3, %d6 | past end of samples? + cmp.l %d2, %d6 | past end of samples? bge.b .usloop_skip | yes? skip loop lea.l -4(%a3, %d6.l*4), %a3 | %a3 = s = &s[pos-1] (previous) move.l (%a3)+, %d0 | %d0 = *s++ @@ -347,8 +347,8 @@ sample_output_stereo: moveq.l #28, %d0 | %d0 = second line bound add.l %a4, %d0 | and.l #0xfffffff0, %d0 | - cmp.l %a4, %d0 | at least a full line? - blo.w .sos_longloop_1_start | no? jump to trailing longword + cmp.l %a0, %d0 | at least a full line? + bhi.w .sos_longloop_1_start | no? jump to trailing longword sub.l #16, %d0 | %d1 = first line bound cmp.l %a4, %d0 | any leading longwords? bls.b .sos_lineloop_start | no? jump to line loop @@ -441,8 +441,8 @@ sample_output_mono: moveq.l #28, %d0 | %d0 = second line bound add.l %a3, %d0 | and.l #0xfffffff0, %d0 | - cmp.l %a3, %d0 | at least a full line? - blo.w .som_longloop_1_start | no? jump to trailing longword + cmp.l %a0, %d0 | at least a full line? + bhi.w .som_longloop_1_start | no? jump to trailing longword sub.l #16, %d0 | %d1 = first line bound cmp.l %a3, %d0 | any leading longwords? bls.b .som_lineloop_start | no? jump to line loop -- cgit v1.2.3