Large Executables with C++

I am getting pretty large executables using the c++ compilers. For a 13kb code the executables is 100Mb.

For testing i compiled the Hello world program here are the results

Source code : 82 bytes
GNU C++ Executable : 13935 bytes
pgCC Executable : 757699 bytes

Any suggestions why this might be happening? is it normal ?
It is a linux Redhat 7.3 system.

Hello World Code

#include <iostream.h>
int main()
{
    cout << "Hello World!\n";
    return 0;
}

This is an unfortunate side effect of the implementation of the STL and is a known issue. We are in the process of revising how our STL is done so this should get better in future releases.

  • Mat