• Resolved

MSP430FR5992: MSP430 GCC memory model

Genius 9205 points

Part Number: MSP430FR5992

Customer will stay with MSP430 GCC and wants to know:

 

  With the "large" memory model for data and code (option -mlarge) the code will be about 20% larger than the "small" memory model (option -msmall).

  This is unusable for us.

  With a "large" memory model only for code, and "small" model for data, the code would be about 5% larger. This is acceptable.

  Is there an option to have "large" model for code and "small" model for data ?

  If no, is it planned to have such possibility in the near future ?

 

Regards, Bernd

  • You'd have to ask the GCC developers.

    As far as I know, nothing like this is planned.
  • Genius 9205 points

    In reply to Clemens Ladisch:

    According to the latest MSP430 GCC Users Guide www.ti.com/lit/SLAU646 we support that

    Whom can I contact?

    Regards, Bernd

  • In reply to BO:

    GCC has nothing but the "-msmall" and "-mlarge" options. The msp430 target code makes no effort whatsoever to distinguish between code and data accesses.

    The actual support is done by Somnium.
  • Genius 9205 points

    In reply to Clemens Ladisch:

    Clemens,

    meanwhile I found the TI-internal supporter.
    But anyway thank you for the hint with www.somniumtech.com/news/somnium-partner-texas-instruments

    Regards, Bernd

  • In reply to Clemens Ladisch:

    I apologize for the delay.  I can confirm the following is correct ...

    Clemens Ladisch
    GCC has nothing but the "-msmall" and "-mlarge" options. The msp430 target code makes no effort whatsoever to distinguish between code and data accesses.

    Documentation on the entire GCC compiler (all targets it supports!) can be found at https://gcc.gnu.org/onlinedocs/ .  Search it for the section titled MSP430 Options.  The only options related to memory model are -mshort and -mlarge.  The description of these options is very short.  To see what they do, build an example source file and inspect it like this ...

    % ofd430 --obj_display=none,battrs file.o
    
    OBJECT FILE:  file.o
    
     Build Attributes in ".MSP430.attributes"
    
        Format Version:  'A'
    
        <0>  Vendor Name:  "mspabi" (ABI for the Texas Instruments MSP430 Architecture)
    
             Tag_File:
                Attributes:
                 Tag_ISA         2  (MSPX)
                 Tag_Code_Model  1  (small code)
                 Tag_Data_Model  1  (small data)

    The utility ofd430 is from the TI compiler toolset.  But you can use it on object files built with the GCC compiler.  You will see that all you can get are small code and small data, or large code and large data.  No other combinations are supported.  The TI compiler supports several other combinations and variations.

    The GCC MSP430 compiler is in maintenance only mode.  No new work is planned.

    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.