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.

  • Resolved

CCS/AMIC110: Memory Allocation window shows no information.

Part Number: AMIC110

Tool/software: Code Composer Studio

Hello,

I am trying to use Memory Allocation window to check memory footprint of a project but no usable information is displayed. Is this a known issue? I am working with AMIC110 processor, compiler version GNU v6.3.1 so I am using gnu .map file (memory allocation for .xml files generated by C2000 works perfectly fine).

Best regards,

A.Lukasiak

  • Guru 149100 points
    Which version of CCS are you using? Are you building the project from within CCS or outside CCS?
    I tried it with a project built in CCS with GNU tools (but for a different Cortex M4 device, not Cortex A8) and the memory allocation view displayed information as expected.

    ____________________________________________________________________________

    Please click This Resolved My Issue if the reply answers your question.

    Search the wikis for common questions: Compiler, CCSv6, CCSv7
    Track a known bug with SDOWP. Enter the bug id in the "Find Record ID" box

  • In reply to AartiG:

    I am using CCS 7.3.0. Project is build from within CCS:

  • Guru 149100 points

    In reply to ArekLukasiak:

    Would you mind giving the latest CCS v8.0 a try to see if that works differently?

    http://processors.wiki.ti.com/index.php/Download_CCS

    If it shows the same issue, could you zip up the .map file and .out file generated by the project and attach it here?

    ____________________________________________________________________________

    Please click This Resolved My Issue if the reply answers your question.

    Search the wikis for common questions: Compiler, CCSv6, CCSv7
    Track a known bug with SDOWP. Enter the bug id in the "Find Record ID" box

  • In reply to AartiG:

    Hi,

    I am not sure if I can send the files due to export control, I will have to check that. However, my project is based on profinet_slave_RT_MRP_AMIC11x from PRU-ICSS-Profinet_Slave_01.00.02.02 and the issue occurs even for unmodified project, downloaded from TI website. Could you check .map and .out files associated with that?

    In the meantime I will try to migrate to CCS v8.

    Thank you,
    A.Lukasiak
  • In reply to ArekLukasiak:

    Ok, I checked CCS v8 and this issue still occurs.
  • Guru 149100 points

    In reply to ArekLukasiak:

    Hi,

    Thank you for giving CCSv8 a try and for the update. I could try it out with the example project but it may take some time for me to install all the packages required to build this example. If you are able to attach here the unmodified project's .map and .out file, that would save a lot of time, but if not, I will get back to you when I have more information.

    Thanks for your patience.

    ____________________________________________________________________________

    Please click This Resolved My Issue if the reply answers your question.

    Search the wikis for common questions: Compiler, CCSv6, CCSv7
    Track a known bug with SDOWP. Enter the bug id in the "Find Record ID" box

  • Guru 149100 points

    In reply to AartiG:

    I have created and built the profinet_slave_RT_MRP_AMIC11x example and see the same as you in the memory allocation view for that project. I will investigate some more and post an update when I have more information.

    ____________________________________________________________________________

    Please click This Resolved My Issue if the reply answers your question.

    Search the wikis for common questions: Compiler, CCSv6, CCSv7
    Track a known bug with SDOWP. Enter the bug id in the "Find Record ID" box

  • In reply to AartiG:

    Thank you for the trouble you have taken with building an example project, I appreciate that a lot. I am looking forward to hearing from you.

    Best regards,
    A.Lukasiak
  • In reply to AartiG:

    AartiG
    I will investigate some more and post an update when I have more information.

    Looking at CCS 8.0.0.00016 Cortex-A8 project built with GCC v6.3.1 the CCS Memory Allocation view seems to require attributes to be set on the MEMORY regions to be able to parse the memory usage.

    Originally in the linker script there were no attributes set:

    MEMORY
    {
        SRAM :     o = 0x402F0400,  l = 0x0000FC00  /* 64kB internal SRAM */
        L3OCMC0 :  o = 0x40300000,  l = 0x00010000  /* 64kB L3 OCMC SRAM */
        M3SHUMEM : o = 0x44D00000,  l = 0x00004000  /* 16kB M3 Shared Unified Code Space */
        M3SHDMEM : o = 0x44D80000,  l = 0x00002000  /* 8kB M3 Shared Data Memory */
        DDR0 :     o = 0x80000000,  l = 0x40000000  /* 1GB external DDR Bank 0 */
    }

    Which caused the following error to be reported in the Memory Allocation view:

    For the example program used, all sections of the program are placed in the DDR0 memory region. When attributes were added on all but the DDR0 region:

    MEMORY
    {
        SRAM (RWX) :     o = 0x402F0400,  l = 0x0000FC00  /* 64kB internal SRAM */
        L3OCMC0 (RWX) :  o = 0x40300000,  l = 0x00010000  /* 64kB L3 OCMC SRAM */
        M3SHUMEM (RWX) : o = 0x44D00000,  l = 0x00004000  /* 16kB M3 Shared Unified Code Space */
        M3SHDMEM (RWX) : o = 0x44D80000,  l = 0x00002000  /* 8kB M3 Shared Data Memory */
        DDR0           :     o = 0x80000000,  l = 0x40000000  /* 1GB external DDR Bank 0 */
    }

    Then the Memory Usage view displayed the regions with the attributes, of which none are use for the program sections:

    With attributes added to all memory regions:

    MEMORY
    {
        SRAM (RWX)     : o = 0x402F0400,  l = 0x0000FC00  /* 64kB internal SRAM */
        L3OCMC0 (RWX)  : o = 0x40300000,  l = 0x00010000  /* 64kB L3 OCMC SRAM */
        M3SHUMEM (RWX) : o = 0x44D00000,  l = 0x00004000  /* 16kB M3 Shared Unified Code Space */
        M3SHDMEM (RWX) : o = 0x44D80000,  l = 0x00002000  /* 8kB M3 Shared Data Memory */
        DDR0 (RWX)     : o = 0x80000000,  l = 0x40000000  /* 1GB external DDR Bank 0 */
    }

    Then the Memory Usage view then displayed the memory usage for the program, all of which is in the DDR0 memory region:

    I haven't yet tried with the PRU-ICSS-Profinet_Slave_01.00.02.02 example to check that adding attributes to the memory regions will cause the Memory Allocation to be displayed for the example.

  • In reply to ArekLukasiak:

    user5141898
    However, my project is based on profinet_slave_RT_MRP_AMIC11x from PRU-ICSS-Profinet_Slave_01.00.02.02 and the issue occurs even for unmodified project, downloaded from TI website.

    The profinet_slave_RT_MRP_AMIC11x example is a SYS/BIOS project where the memory regions come from the platform ti.platforms.evmAM3359.

    As mentioned in my previous post, for the Memory Allocation view in CCS 8.0.0.00016 to be able to display the memory usage for a program built with the GCC ARM compiler requires attributes to be set on each memory region. One work-around is to add the following to the .cfg file for the program:

    /* If any memory region doesn't have access attributes specified, then set to "RWX".
       Memory region access attributes are required for the Memory Allocation view in CCS 8.0.0.00016 to be able to parse
       the memory usage for a memory region in .map file generated by the GCC ARM linker */
    for (var i=0; i < Program.cpu.memoryMap.length; i++)
    {
        if (Program.cpu.memoryMap[i].access == null)
        {
            Program.cpu.memoryMap[i].access = "RWX"; 
        }
    }

    With this modification made to the amic11x_app_arm.cfg file from the profinet_slave_RT_MRP_AMIC11x example then the CCS Memory Allocation view then displayed the memory usage:

    Using the Edit Platform wizard appears to show that the ti.platforms.evmAM3359 from SYS/BIOS 6.52.00.12 already has attributes (aka "Access") set for the DDR3 memory region, so not sure why the work-around of editing the .cfg file to force attributes to be used was necessary:

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.