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: compiler error protection

Other Parts Discussed in Thread: TMS570LS0714

Tool/software: TI C/C++ Compiler

Hi,

Recently we have received feedback from customers,They think the compiler may compile errors,So they want us to set the compiler error protection measures.It is recommended that we  can add a security code to a data segment or code segment .I would like to ask how this specific operation,Or do you have any preventive measures against compiler errors?

Compiler version numbe:ti-cgt-arm_5.2.7

MCU device type: TMS570ls0714

  • I apologize, but I do not understand your request.  Are you aware of another compiler with a similar feature?  If so, please point me to the documentation of that feature for that compiler, so that I can learn more about it.

    Thanks and regards,

    -George

  • I'm so sorry to reply you so late.The compiler error I'm talking about does not refer to a specific compiler.The client means that the compiler may have compilation optimization errors or compilation errors.Resulting in the program can not run normally.

    My question is as follows.

    1.If the compiler optimization function is closed, then there will be compiler optimization error?

    2.How to prevent compiler optimization errors

    thanks a lot.

  • sam said:
    1.If the compiler optimization function is closed, then there will be compiler optimization error?

    I'm not sure what you mean by "closed".  Perhaps you are asking whether the TI compiler is open source or closed source.  It is closed source.  The source code is not part of a open source community project like gcc.

    sam said:
    2.How to prevent compiler optimization errors

    I think you refer to instances where the compiler attempts to optimize the generated code, and somehow makes an error.  We work very hard to prevent this from occurring.  The compiler testing procedure is very extensive, and growing all the time, precisely to avoid such errors.  All that said, the compiler is complicated software.  Therefore, we cannot guarantee there will never be any optimization errors.

    Thanks and regards,

    -George

  • I mean to turn off the optimization options when compiling the program.But I'm not sure whether the program will output optimization errors after the optimization option is turned off.

  • When you use the term "optimization errors", do you mean errors that occur in source code you write?  The compiler's capability to detect errors in your source code is not affected by the optimization level you use.

    Thanks and regards,

    -George

  • I think he means where optimization incorrectly changes the sense of the code. If this is the case, he needs to create a small test program that illustrates the error and send it in to have it fixed.