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.
Hi,
We could see that the following loop was causing some problem with Code gen tool 7.3.1. (The code was not working as expected)
#pragma MUST_ITERATE (CHAR_BIT, CHAR_BIT)
for (w=0, b=0; b<CHAR_BIT; b++, n++)
w |= (tUInt8)(*pLlrPtr++ & 0x80) >> b;
When we unrolled the loop the issue disappeared and worked as expected.
w = (tUInt8)(*pLlrPtr++ & 0x80);
w |= (tUInt8)((*pLlrPtr++ & 0x80) >> 1);
w |= (tUInt8)((*pLlrPtr++ & 0x80) >> 2);
w |= (tUInt8)(*pLlrPtr++ & 0x80) >> 3;
w |= (tUInt8)(*pLlrPtr++ & 0x80) >> 4;
w |= (tUInt8)(*pLlrPtr++ & 0x80) >> 5;
w |= (tUInt8)(*pLlrPtr++ & 0x80) >> 6;
w |= (tUInt8)(*pLlrPtr++ & 0x80) >> 7;
The issue was not seen with 7.3.4 version. We wanted to know if this is an issue with the code gen tool or with the code itself.
Thanks and regards,
Thomas
Could you be more specific about what symptom you were observing? The code did not work as expected; how did it actually work? Did you get the wrong output? Was the performance not what you expected? Did your hard drive melt?
By the way, the cast to tUInt8 is probably unnecessary.