AnsweredAssumed Answered

STL code bloat

Question asked by fvpetrov on Oct 28, 2015
Latest reply on Feb 5, 2016 by Kader.M

Hi,

 

using VisualDSP++ 5.1.2 on

Win7 x64 Ultimate, EN

with a C++ project,

Blackfin BF512,

 

the STL library is compiled once per source file.

In this case the code is highly bloated with redundant functions.

 

For example, having this snippet:

#include <string>

void function_x( void )

{

    std::string abc( "abc" );

}

 

included in two C++ files yields to this linker map:

 

Input section  .\Debug\NewProject.doj(program)

__Myptr__Q2_3std6stringFv     std::string::_Myptr()     0xffa10b98     0x22


Input section  .\Debug\test.doj(program)

__Myptr__Q2_3std6stringFv     std::string::_Myptr()     0xffa11124     0x22



Is there any way to get rid of this?


Thanks!

Attachments

Outcomes