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.

Compiler/TMS320C28346: INTERNAL ERROR: no match for ASG, ti-cgt-c2000_18.12.2.LTS

Part Number: TMS320C28346

Tool/software: TI C/C++ Compiler

Hey, I Use CCS9 with 18.12.2 LTS Compiler.

I'm trying to compile this piece of code with -O2 optimizations.

               for (s16_index = 7; s16_index >= 0; s16_index--)
               {
                  s32_temp_vd2[s16_index] = ((long)(s64_temp_vd[s16_index]));    // check for numeric overflow
                  if ((long long)s32_temp_vd2[s16_index] != s64_temp_vd[s16_index])
                  {
                     u16_numeric_overflow_flag = 1;
                  }
               }

and i get this error:

>> ../source/BG/Velocity.c, line 3983: INTERNAL ERROR: no match for ASG


This may be a serious problem. Please contact customer support with a
description of this problem and a sample of the source files that caused this
INTERNAL ERROR message to appear.

Cannot continue compilation - ABORTING!

gmake: *** [Velocity.obj] Error 1

from spru514p:

--opt_level=2 or -O2
Performs all --opt_level=1 (-O1) optimizations, plus:
– Performs loop optimizations
– Eliminates global common subexpressions
– Eliminates global unused assignments
– Performs loop unrolling

So i change the for loop to:

               for (s16_index = 0; s16_index < 8; ++s16_index)
               {
                  s32_temp_vd2[s16_index] = ((long)(s64_temp_vd[s16_index]));    // check for numeric overflow
                  if ((long long)s32_temp_vd2[s16_index] != s64_temp_vd[s16_index])
                  {
                     u16_numeric_overflow_flag = 1;
                  }
               }

And it compiles well.

With optimizations less than -O2 both variants compile well.

Please shine some light on this issue.

My compiler flags:

-v28 -ml -mt --float_support=fpu32 -O2 --opt_for_speed=2 --advice:performance=all --define="_DEBUG" --define="LARGE_MODEL" --symdebug:none --diag_error=225 --diag_error=2082 --display_error_number --issue_remarks --quiet --abi=coffabi -k --asm_listing --c_src_interlist --asm_directory="${CWD}" --obj_directory="${CWD}"