Uploaded image for project: 'Embedded Software & Tools'
  1. Embedded Software & Tools
  2. EXT_EP-10247

Linker does not choose the best RTS library

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: Not Prioritized Not Prioritized

      The compiler does not ship with RTS libraries that support C++ exceptions. In this use case, a previous build with compiler, then a use of mklib, created these libraries.

      rtsv7R4_A_be_v3D16_eabi_eh.lib
      rtsv7R4_T_be_v3D16_eabi_eh.lib

      These libraries are the same except the first is the ARM variant, and the second is the Thumb variant.

      The attached hello.cpp is a typical hello world program that uses C++ cout.

      In this build ...

      armcl --code_state=16 -mv7r4 --float_support=VFPv3D16 --exceptions hello.cpp -z -o hello.out -m hello.map
      

      Because of --code_state=16, the thumb variant of the library should be chosen. But it is not.

      % findstr rts hello.map | more
                        00000020    000011d4     rtsv7R4_A_be_v3D16_eabi_eh.lib : _scanfi.c.obj (.text:__TI_scanfi)
      

      The ARM variant of the library is chosen.

      To get the Thumb variant, it must be explicitly specified.

      % armcl --code_state=16 -mv7r4 --float_support=VFPv3D16 --exceptions hello.cpp -z -o hello.out -m hello.map -l rtsv7R4_T_be_v3D16_eabi_eh.lib
      

            syncuser TI User
            syncuser TI User
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: