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.

CCSTUDIO: 1011

Part Number: CCSTUDIO

Hello,

I'm using the ccs1011 ti-cgt-c2000_21.6.0 compiler to compile a project. I have an error in the _ti_config.h file and I don't know what is causing it :

"C:\\ti\\ccs1011\\ccs\\tools\\compiler\\ti-cgt-c2000_21.6.0.LTS\\include\\_ti_config.h",line 54: error #1212:
this pragma cannot be used in a _Pragma operator (a #pragma directive must be used)
_Pragma("diag_push")

Before this error, I have several warning : 

[C:\ti\ccs1011\ccs\tools\compiler\ti-cgt-c2000_21.6.0.LTS\include/stddef.h:53] Syntax error: typedef __PTRDIFF_T_TYPE__ ptrdiff_t;
[C:\ti\ccs1011\ccs\tools\compiler\ti-cgt-c2000_21.6.0.LTS\include/stddef.h:59] Syntax error: typedef __SIZE_T_TYPE__ size_t;
[C:\ti\ccs1011\ccs\tools\compiler\ti-cgt-c2000_21.6.0.LTS\include/stddef.h:75] Syntax error: typedef __WCHAR_T_TYPE__ wchar_t;

The project is generated from a scade model. Unfortunately I can't share any part of the code here. If someone knows what can cause this compilation error it would really help me.

Thanks,

Sébastien.

  • Hi -- can you provide the compiler build options you are using to build your project? A reduced test case that shows the issue would be nice if you can remove the code you can't share.  For that, please follow the directions in the article How to Submit a Compiler Test Case. BUt if you can't do that, the build/compiler options would be needed.

    Thanks!

  • Hi, here are the compiler options :

    -g -v28 -ml -mt -O0 --opt_for_speed=2 --fp_mode=relaxed --advice:performance=all --float_support=fpu32

    I'm not sure which part of the code is causing the issue, and I can't send you the whole code. I will check with my superiors what I can share.

    Thank you for your time.

  • The compiler RTS header files like stddef.h are very unlikely to have problems like ...

    [C:\ti\ccs1011\ccs\tools\compiler\ti-cgt-c2000_21.6.0.LTS\include/stddef.h:53] Syntax error: typedef __PTRDIFF_T_TYPE__ ptrdiff_t;

    If they did, that would be found in the extensive testing performed before every release.  Or, many other customers would have reported it by now.  The root cause is likely to be in something that appears before this header file is included.  

    I suspect you can debug the problem on your own.  Use the compiler option --gen_preprocessor_listing.  It creates a listing file that has the same name as the source file, with the file extension changed to .rl.  To learn how to use this listing file, please search the C28x compiler manual for the sub-chapter titled Generating a Raw Listing File.  

    Thanks and regards,

    -George

  • Thanks for your help, I will try that.