c++ - hello world program too large
- Can (3/3) Jul 31 2008 hello,
- Heinz Saathoff (19/22) Aug 08 2008 Depends on your program and what library you use.
hello, i am compiling a simple hello world program with optimizations but .exe file is about 370 kb . is it normal?
Jul 31 2008
Can wrote...hello, i am compiling a simple hello world program with optimizations but .exe file is about 370 kb . is it normal?Depends on your program and what library you use. For example, this program #include <stdio.h> int main() { printf("Hello World\n"); return 0; } copiles to an .EXE of approx. 40 kB This one #include <iostream> int main() { std::cout << "Hello World" << std::endl; return 0; } compiles to an EXE that is 10 times larger. It's the overhad in the statically linked STLPORT lib. - Heinz
Aug 08 2008