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.

64 bit division on C6748

I am using a C6748 DSP with CCS3.3.  I cannot seem to get it to correctly divide two 64 bit numbers.  I am defining my numbers as long.  The results of the division is incorrect.  I am coding in C.

  • Not sure if I can help. Some more info is required.

    Are you using COFF or EABI? The type "long" is 40 bits for COFF and 32 bits for EABI. The type "long long" is 64 bits in either format.

    What optimization level? I've seen 64 bit math errors at higher optimization levels. It was under specific conditions and has been fixed in later compiler versions. CCS3.3 is quite old. If possible, you should update to the latest. Understandable if you can't for licence reasons.

    Do you have a reproducible test case is code? In any case, you might want to post in the "Development Tools" -> "TI C/C++ Compiler" forum. You'll more likely to get answers there.