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.

undefined symbol mspabi_srli

I get the following error when compiling. But only at optimization level off and 0. At higher lever run the programm.

__mspabi_srli_4 ./System/Timer.obj
 __mspabi_srli_5 ./System/Timer.obj
 __mspabi_srli_8 ./System/Timer.obj
 __mspabi_srli_9 ./System/Timer.obj

I use compiler V4.4.4

  • This missing 'function' is a helper code stub to perform a multi-bit shift operations. It helps keeping code size small at the expense of a function call. (the code calls different entry points into a chain of shift instructions, to perform 9,8,5 or 4 shift operations before returning)
    I don't know why it is not linked.
    On higher optimization levels, the compiler may inline the shifting code (higher speed) or even eliminate some of the shifts by re-arranging instructions. So this code isn't needed.

    BTW: it is a linker error, not a compiler error.

**Attention** This is a public forum