News for hackers. Stuff that matters.
Re:On the evolution of programming style: How far C++ has mo... by greyfade on Monday March 26, 2012 @01:13PM (#3757633)
No, the majority of that overhead is from the use of `iostream`s (which are known to be pretty bloated compared to `printf` and friends), the use of exceptions (try/catch is a morass of stack-unwinding code), and the added bloat of class information (RTTI and symbols in particular).

If it were compiled with full optimizations and the final binaries stripped, they'd be much closer in size. Moreso if exceptions are disabled or if the class is replaced with a simple function taking/returning tuples.

Re:On the evolution of programming style: How far C++ has mo... by alextgordon on Monday March 26, 2012 @07:11PM (#3759086)
Not only is iostream bloated, but it often injects a static constructor into every translation unit (which visibly angers the – usually calm – LLVM style guide[1]). Oh and it's really godawfully slow unless you turn off a magic flag somewhere[2].

Friends don't let friends use iostream.

[1]: http://llvm.org/docs/CodingStandards.html#ll_iostream

[2]: http://stackoverflow.com/questions/9371238/why-is-reading-li...

Re:On the evolution of programming style: How far C++ has mo... by Suncho on Tuesday March 27, 2012 @03:55AM (#3760527)
There's a huge difference between using exceptions and littering your code with a bunch of try/catch blocks. When exceptions are used properly, you see very little error handling code.