News for hackers. Stuff that matters.
Re:Comparing C and C++ usage and performance with a real wor... by ausjke on Sunday September 03, 2017 @01:09PM (#15162540)
In general there is no way a C program(apple to apple, comparing to its similar c++ version) will be larger than C++, be it static, shared libraries included, or whatever.
Re:Comparing C and C++ usage and performance with a real wor... by astrodust on Sunday September 03, 2017 @01:44PM (#15162722)
Today, sure, but there's no assurance that this will be true in the future. If more compiler-friendly extensions are added to C++ to help it generate tighter, more nimble machine code because it's given more leeway in optimizations, then the C++ code could be substantially smaller. C doesn't seem as interested in adopting some of the C++ paradigms that could make optimization better, tools like formalized iterators and such.

There's been various attempts at pre-compiling the headers over the years, but the results have always been, for various reasons, less than perfect.