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.

  • TI Thinks Resolved

Compiler/TMS570LS0714: TMS570 compiling time too long

Part Number: TMS570LS0714

Tool/software: TI C/C++ Compiler

Hi Champ,

My customer use TMS570LS0714 ,customer met issue that the compiling time too long.

 

The detail as below:

 

LS0714 project compiling time around 50 minutes to rebuild(Build All) the project, while similar project which use Infineon Tri-core just used 10minute for rebuild(Build All),

 

CCS and compiler condition:

  1. CCS version:6.1.0

  2. Compiler version: 5.0.4

  3. Compiler option:

    -mv7R4 --code_state=32 --float_support=VFPv3D16 --abi=eabi -O3 -g  --define=_TMS570LS07x_ --define=_VFP_SUPPORT_=1 --diag_warning=225 --diag_warning=16004 --display_error_number --diag_wrap=off --enum_type=packed --asm_listing --obj_directory="BSW/src/BSW/Gen/Dcm/src"

     

4.Customer already select “enable parallel build –Use optimal jobs(4)” option.

5.Customer cannot try the new LTS version compiler due to below reason:

           a. The EATS OS limited the compiler version to 5.1.0 or more  old version. If use the LTS version compiler , the OS will cannot  compiler.

b. Customer project with ISO26262 ASIL-C requirement, the SDL CSP and MCAL CSP are based on 5.0.4 compiler.

 

Issue:

The project with AUTOSAR ,OS,MCAL and application SW. When select “ Rebuild Project  “ operation, will need around 50 minutes to finish TMS570 project compiling and generate the .out file.  And most time are spend on the build stage and link time is very short .

Customer has similar project which used Infineon TC23x, the project also with AUTOSAR ,OS ,MCAL and application SW, with the same computer ,use Tasking environment to rebuild project just need 10minutes.

 

We really need you help to look  into this issue and help to reduce the compiling time.

  • Please consider these two possible solutions.

    The CCS indexer might take a long time.  To learn about the indexer, why it might be the problem, and how to disable it, please see the indexer part of the larger article CCS Project and Build Handbook.

    It might be the case that one or two very large functions take a lot of build time.  Working through this issue requires finding the largest functions, then either making those functions smaller, or building them with lower optimization.

    To find the largest functions, start by using a command similar to ...

    % armofd --func_info final_executable.out > size_data.csv

    armofd is the Object File Display utility.  It is a command line utility that is part of the ARM compiler installation.  It is documented in the ARM assembly tools manual.  The option --func_info causes it to emit one line of information about each function in the program.  The input in the example is final_executable.out.  Replace that with the final executable file created by the linker.  The output is written to a file named size_data.csv.  

    To understand what is in size_data.csv, here are 3 typical lines ...

    "ti_sysbios_BIOS_nullFunc__I","package/cfg/app_pem3.c",0x00016b86,0x00016b88,2
    "ti_sysbios_BIOS_registerRTSLock__I","package/cfg/app_pem3.c",0x0001739c,0x000173b4,24
    "ti_sysbios_BIOS_removeRTSLock__I","package/cfg/app_pem3.c",0x000173c0,0x000173da,26

    The information is in comma separated values (CSV) format.  The fields are function name, source file name, start address, end address, size.  A CSV file can be directly loaded into a spreadsheet application like Excel.  Then sort on the size column (the last one).  Focus your attention on the first few functions.

    Rebuild just one of those source files.  In CCS, select the file, right click, then choose Build Selected File(s).  If the build of that one file takes a long time, then you have found the problem.  Or, maybe a big part of the problem.

    Once the problem function, or functions, is found, consider splitting the function into multiple smaller functions.  Or, perhaps lower the optimization used when building just this one source file.  For details, see the File Specific Options part of the build handbook.

    Thanks and regards,

    -George


    TI C/C++ Compiler Forum Moderator
    Please click This Resolved My Issue on the best reply to your question
    The CCS Youtube Channel
     has short how-to videos
    The 
    Compiler Wiki answers most common questions
    Track an issue with SDOWP. Enter your bug id in the Search box.

  • In reply to George Mock:

    Hi George ,

    I will let customer to try.
    And will update later!
  • In reply to George Mock:

    Hi George,

    Customer has try disable the index, but the compiling time almost no change.

    Customer also try no optimization and lower optimization, the compiling time change not obviously change.

    based on customer information , not one or certain file take long build time.

    Could you advise how to settle customer compiling time issue?

    Could we provide one MCAL example project which "rebuild all "compiling time is around one mintue to you , if you could reduce the compiling time obviously based on this example project , we can let customer to try the same method.
  • In reply to Huihuang Chen:

    Huihuang Chen
    Could we provide one MCAL example project which "rebuild all "compiling time is around one mintue

    That sounds like a good idea.  But I am concerned about one thing.  If this project needs other software packages to be installed on the system, that increases the risk I will not be able to build the project.  I have experienced failure to build before.  In that case, an example project depended on other software packages, and I could not work out what packages, what version, where they should be installed, and other such configuration details.

    So, it is ideal if the project is self-contained.  If that is not practical, then please tell me what software packages are needed, where to download them, what version, where they should be installed, and any other such detail that might be needed.

    To package up the project, please use the directions in the article Project Sharing.

    Thanks and regards,

    -George


    TI C/C++ Compiler Forum Moderator
    Please click This Resolved My Issue on the best reply to your question
    The CCS Youtube Channel
     has short how-to videos
    The 
    Compiler Wiki answers most common questions
    Track an issue with SDOWP. Enter your bug id in the Search box.

  • In reply to George Mock:

    Hello George,

    I think the project is self contained.you just need to install  ARM compiler.

    Please refer to the attachment, if you have any problem, you can contact with me by E-mail, my mail is :huihuang-chen@ti.com.

    Thanks!Sample_Project_LS07x.7z

  • In reply to Huihuang Chen:

    Thank you for the attachment.  It contains two projects.

    The one named TMS570LS07x_MCAL imports with no problems.  It builds in about a minute.  So that can't be the one with the problem.

    The other project is named TMS570LS07_Sample_Config.  I don't know why, but this one does not import.  I'll try to get with some CCS experts to see what can be done.  But I'm not hopeful that will work.

    Maybe the project got corrupted somewhere along the way.  So, I would appreciate if you would send it again.  Please package it up from scratch.  

    Thanks and regards,

    -George


    TI C/C++ Compiler Forum Moderator
    Please click This Resolved My Issue on the best reply to your question
    The CCS Youtube Channel
     has short how-to videos
    The 
    Compiler Wiki answers most common questions
    Track an issue with SDOWP. Enter your bug id in the Search box.

  • In reply to George Mock:

    Hi George, 
     
    The project is TMS570LS07x_MCAL which under below folder,could you try to reduce this project compiling time?
            Sample_Project_LS07x\TMS570LS07\CCS

  • In reply to Huihuang Chen:

    Huihuang Chen
    The project is TMS570LS07x_MCAL which under below folder,could you try to reduce this project compiling time?

    I tried, and I failed.  It takes about 1 minute to build this project.  I tried a few changes, but the build time stayed the same.

    This project contains 86 source files.  For so many source files, compile time becomes dominated not by the core compilation process, but by all of the file I/O required to compile and link 86 files.  There is nothing I can do to reduce that I/O.  I'm sorry.

    Thanks and regards,

    -George


    TI C/C++ Compiler Forum Moderator
    Please click This Resolved My Issue on the best reply to your question
    The CCS Youtube Channel
     has short how-to videos
    The 
    Compiler Wiki answers most common questions
    Track an issue with SDOWP. Enter your bug id in the Search box.

  • In reply to George Mock:

    Hi George,

    Can we use PCH (precompiled herder) feature in CCS?

    Thanks and Regards,
    QJ Wang

  • In reply to QJ Wang:

    The precompiled header feature of TI compilers is no longer available in recent versions.  That is because it rarely (never?) reduced build time.

    Thanks and regards,

    -George


    TI C/C++ Compiler Forum Moderator
    Please click This Resolved My Issue on the best reply to your question
    The CCS Youtube Channel
     has short how-to videos
    The 
    Compiler Wiki answers most common questions
    Track an issue with SDOWP. Enter your bug id in the Search box.

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.