[cfe-dev] linking and stripping compared to GCC 4.4
Luc Bourhis
luc_j_bourhis at mac.com
Mon Nov 29 14:33:05 PST 2010
> Any reason why demo.cpp is 952 bytes for clang and 902 bytes for gcc?
Different hard drives. They are the same file, I swear.
> Also, it looks like you're comparing Mac OS X to Linux.
I ran gcc 4.4 on Linux and clang on MacOS X indeed.
> The binary format on each is very different.
Fair enough. I did not take the time to install gcc 4.4 on my MacOS X machine indeed. Nevertheless, this begs the question: is clang++ hampered by MacOS X binary format to such an extent that the -s stripping option has no effect whatsoever? Whereas g++ 4.4 on Linux is able with the same option to significantly reduce the binary size thanks to the superior ELF 64-bit format? Or could clang++ do better as a linker driver on MacOS X here?
Luc Bourhis
More information about the cfe-dev
mailing list