static void revert_cdlms(WmallDecodeCtx *s, int tile_size)

{

    int icoef, ich;

    int32_t pred, channel_coeff;

    int ilms, num_lms;



    for (ich = 0; ich < s->num_channels; ich++) {

        if (!s->is_channel_coded[ich])

            continue;

        for (icoef = 0; icoef < tile_size; icoef++) {

            num_lms = s->cdlms_ttl[ich];

            channel_coeff = s->channel_residues[ich][icoef];

            if (icoef == s->transient_pos[ich]) {

                s->transient[ich] = 1;

                use_high_update_speed(s, ich);

            }

            for (ilms = num_lms; ilms >= 0; ilms--) {

                pred = lms_predict(s, ich, ilms);

                channel_coeff += pred;

                lms_update(s, ich, ilms, channel_coeff, pred);

            }

            if (s->transient[ich]) {

                --s->channel[ich].transient_counter;

                if(!s->channel[ich].transient_counter)

                    use_normal_update_speed(s, ich);

            }

            s->channel_coeffs[ich][icoef] = channel_coeff;

        }

    }

}

static void revert_cdlms(WmallDecodeCtx *s, int tile_size)

{

    int icoef, ich;

    int32_t pred, channel_coeff;

    int ilms, num_lms;



    for (ich = 0; ich < s->num_channels; ich++) {

        if (!s->is_channel_coded[ich])

            continue;

        for (icoef = 0; icoef < tile_size; icoef++) {

            num_lms = s->cdlms_ttl[ich];

            channel_coeff = s->channel_residues[ich][icoef];

            if (icoef == s->transient_pos[ich]) {

                s->transient[ich] = 1;

                use_high_update_speed(s, ich);

            }

            for (ilms = num_lms; ilms >= 0; ilms--) {

                pred = lms_predict(s, ich, ilms);

                channel_coeff += pred;

                lms_update(s, ich, ilms, channel_coeff, pred);

            }

            if (s->transient[ich]) {

                --s->channel[ich].transient_counter;

                if(!s->channel[ich].transient_counter)

                    use_normal_update_speed(s, ich);

            }

            s->channel_coeffs[ich][icoef] = channel_coeff;

        }

    }

}

            for (ilms = num_lms; ilms >= 0; ilms--) {
static void FUNC_0(WmallDecodeCtx *VAR_0, int VAR_1)

{

    int VAR_2, VAR_3;

    int32_t pred, channel_coeff;

    int VAR_4, VAR_5;



    for (VAR_3 = 0; VAR_3 < VAR_0->num_channels; VAR_3++) {

        if (!VAR_0->is_channel_coded[VAR_3])

            continue;

        for (VAR_2 = 0; VAR_2 < VAR_1; VAR_2++) {

            VAR_5 = VAR_0->cdlms_ttl[VAR_3];

            channel_coeff = VAR_0->channel_residues[VAR_3][VAR_2];

            if (VAR_2 == VAR_0->transient_pos[VAR_3]) {

                VAR_0->transient[VAR_3] = 1;

                use_high_update_speed(VAR_0, VAR_3);

            }

            for (VAR_4 = VAR_5; VAR_4 >= 0; VAR_4--) {

                pred = lms_predict(VAR_0, VAR_3, VAR_4);

                channel_coeff += pred;

                lms_update(VAR_0, VAR_3, VAR_4, channel_coeff, pred);

            }

            if (VAR_0->transient[VAR_3]) {

                --VAR_0->channel[VAR_3].transient_counter;

                if(!VAR_0->channel[VAR_3].transient_counter)

                    use_normal_update_speed(VAR_0, VAR_3);

            }

            VAR_0->channel_coeffs[VAR_3][VAR_2] = channel_coeff;

        }

    }

}

static void FUNC_0(WmallDecodeCtx *VAR_0, int VAR_1)
{ int VAR_2, VAR_3; int32_t pred, channel_coeff; int VAR_4, VAR_5; for (VAR_3 = 0; VAR_3 < VAR_0->num_channels; VAR_3++) { if (!VAR_0->is_channel_coded[VAR_3])
continue; for (VAR_2 = 0; VAR_2 < VAR_1; VAR_2++) { VAR_5 = VAR_0->cdlms_ttl[VAR_3]; channel_coeff = VAR_0->channel_residues[VAR_3][VAR_2]; if (VAR_2 == VAR_0->transient_pos[VAR_3]) { VAR_0->transient[VAR_3] = 1; use_high_update_speed(VAR_0, VAR_3); } for (VAR_4 = VAR_5; VAR_4 >= 0; VAR_4--) { pred = lms_predict(VAR_0, VAR_3, VAR_4); channel_coeff += pred; lms_update(VAR_0, VAR_3, VAR_4, channel_coeff, pred); } if (VAR_0->transient[VAR_3]) { --VAR_0->channel[VAR_3].transient_counter; if(!VAR_0->channel[VAR_3].transient_counter)
use_normal_update_speed(VAR_0, VAR_3); } VAR_0->channel_coeffs[VAR_3][VAR_2] = channel_coeff; } } }