This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

pointing to linear assembler function wuth CGT 7.2.2



I'm building a C project for the 6424 DSP, and am currently upgrading from CGT 6.0.8 to 7.2.2.

I have this const:

const fpWhiteNoiss pdT_fnWhiteNoise[4] =
{
     PD_WhiteNoise04, PD_WhiteNoise06, PD_WhiteNoise08, PD_WhiteNoise10
};

refrencing 4 different linear assembly functiuons.

in 6.0.8 this works fine:

prSt->s16Seed = (*pdT_fnWhiteNoise[(u16LpcOrd>>1)-2])
                (prSt->as16Par, prSt->as16GDly, u16FrmSz, prSt->s16Seed, s16Fct, pS16Frm);

after compiling with 7.2.2 this line results in an exeption (looking at IERR reg its unknown opcode fetch if I am not mistaken).
If I change this line to a switch (without using the const array) everything works again.

  • Do all of these functions have a prototype compatible with the typedef fpWhiteNoiss?  That is, do they all take exactly 6 arguments of the same type and return the same type?

    This is not enough code to diagnose the problem.  We would need something that we could compile so we can reproduce the problem.

    What is the value of the PC when the opcode fetch exception happens?   Does it fall within one of those four functions?  Try single-stepping through the indirect call and looking for the point at which things look wrong.

  • Logically everything is fine - as I said it was working with previus tool version and also when I use a switch-case instaed of the const array it works.

    I opened an SR (1-20132182) in siebel and I'll send sources there I guess. it's not a big deal - the performance difference is pretty negligable.