C++ is the only language I'm aware of where every extension made to the language is careful to only affect compilation time/complexity, while preserving the speed and operational semantics of the code at runtime. This makes it perfect for some domains, e.g. console game development, where the speeds required are only attainable by dicking around with pointers in C, but people want to use better abstractions than C is…
Has C++ jumped the shark?
21–30 of 69 posts
Re: Has C++ jumped the shark?
#22I've written in C++ professionally almost 12 years (17 years counting College), and in my opinion it is a shame how the language has not evolved properly. Unsolved things: - Unified C++ ABI call for making shared libraries without worrying about compiler manufacturer or version. - Massive bloat. Take a look to the Boost libraries and cry. - Poor debugging tools for templates (debugging templates it is crazy, and the…
"Massive bloat. Take a look to the Boost libraries and cry." Aside from your tears, what is the evidence that boost is bloated? Too slow? Too much source code? Too many files? I've been using Boost for nearly a decade. It does a ton of useful stuff (from template metaprogramming to fast matrix algebra), it's loosely coupled, and it's insanely fast. Given it's scope, it's the least bloated library of which I know. C++…
With gcc 4.4.5 and -O2, this one small file takes 22 seconds (!) to compile and produces a 14MB output file.
I guess that's... tolerable. But it isn't "lean" in any meaningful sense.
Re: Has C++ jumped the shark?
#23Re: Has C++ jumped the shark?
#24C++ is the only language I'm aware of where every extension made to the language is careful to only affect compilation time/complexity, while preserving the speed and operational semantics of the code at runtime. This makes it perfect for some domains, e.g. console game development, where the speeds required are only attainable by dicking around with pointers in C, but people want to use better abstractions than C is…
C++ takes a very simplistic view of runtime performance, however. Generics are implemented using templates; which instantiates the code for every type you use. Naively, this preserves the performance of simply writing the same code for each type (which is what you did before templates). However, that might not be the best performing way to implement generics at runtime. (Edit: Small change to make meaning clearer)
Note also the ability to extern templates added in C++0x, which allow you to collapse common instantiations to a single object file.
Re: Has C++ jumped the shark?
#25Earlier quoted context omitted.
"Massive bloat. Take a look to the Boost libraries and cry." Aside from your tears, what is the evidence that boost is bloated? Too slow? Too much source code? Too many files? I've been using Boost for nearly a decade. It does a ton of useful stuff (from template metaprogramming to fast matrix algebra), it's loosely coupled, and it's insanely fast. Given it's scope, it's the least bloated library of which I know. C++…
There is bloat and there is bloat. I'm currently playing with a 200-line file that is mostly a wrapper around a subset of boost::polygon (basically it's a single-type specialization wrapped in a simpler API). With gcc 4.4.5 and -O2, this one small file takes 22 seconds (!) to compile and produces a 14MB output file. I guess that's... tolerable. But it isn't "lean" in any meaningful sense.
Re: Has C++ jumped the shark?
#26Languages are tools. Da Vinci with a mop and a bucket of mud would be a better painter than me. In fact I recently saw a video where Kelly Slater surfed a door and a coffee table as impressively as most weekend warriors surf on $700 custom shaped boards. Focus on your skill not the tools. Surfing is more about timing, fitness and knowledge of waves than it is about the board. Likewise coding is more about RAM, CPUs,…
My coding is primarily about managing complexity through good abstractions, and sometimes doing optimizations. Different languages are better suited to good abstractions. Kelly Slater might use a coffee table for fun one time, but he won't use one for his next competition.
Re: Has C++ jumped the shark?
#27Languages are tools. Da Vinci with a mop and a bucket of mud would be a better painter than me. In fact I recently saw a video where Kelly Slater surfed a door and a coffee table as impressively as most weekend warriors surf on $700 custom shaped boards. Focus on your skill not the tools. Surfing is more about timing, fitness and knowledge of waves than it is about the board. Likewise coding is more about RAM, CPUs,…
It's like saying "famous author X used pen and paper, hence complaining that Word 2010 doesn't handle Y properly is silly - focus on your writing!" (Worse even, as for pure writing, the speedup between pen/typewriter/Word is probably less pronounced than between programming languages.)
Re: Has C++ jumped the shark?
#28Re: Has C++ jumped the shark?
#29Languages are tools. Da Vinci with a mop and a bucket of mud would be a better painter than me. In fact I recently saw a video where Kelly Slater surfed a door and a coffee table as impressively as most weekend warriors surf on $700 custom shaped boards. Focus on your skill not the tools. Surfing is more about timing, fitness and knowledge of waves than it is about the board. Likewise coding is more about RAM, CPUs,…
I saw a table tennis player all excited about his new carbon fiber paddle. Then one of the club champs picked up the box the new paddle had come in and, using the box as a paddle, proceeded to defeat the player with the carbon paddle.
Re: Has C++ jumped the shark?
#30I've written in C++ professionally almost 12 years (17 years counting College), and in my opinion it is a shame how the language has not evolved properly. Unsolved things: - Unified C++ ABI call for making shared libraries without worrying about compiler manufacturer or version. - Massive bloat. Take a look to the Boost libraries and cry. - Poor debugging tools for templates (debugging templates it is crazy, and the…
"Massive bloat. Take a look to the Boost libraries and cry." Aside from your tears, what is the evidence that boost is bloated? Too slow? Too much source code? Too many files? I've been using Boost for nearly a decade. It does a ton of useful stuff (from template metaprogramming to fast matrix algebra), it's loosely coupled, and it's insanely fast. Given it's scope, it's the least bloated library of which I know. C++…
It's actually not all that fast in a lot of cases. Boost's matrix manipulation support is particularly slow:
http://eigen.tuxfamily.org/index.php?title=Benchmark-August2...
Also a lot of the template aerobatics generate a ginormous number of symbols which massively increase the binary size and cache pressure. In a former life I ripped out a pile of heavily templated code using Boost and replaced it with a well placed virtual function or three and dramatically reduced the cache misses in the application.
I've always seen Boost (and to a large extent the STL) as a demo library to show off what's possible with templates rather than something to be used in everyday code and have worked on a number of projects which forbade both.
There's a large rift in the C++ world between what I generally label Qt and Boost camps. The Boost people see the Qt folks as Java-esque dimwits that can't be bothered to learn the full extent of C++'s power and the Qt folks see the Boost following as unpragmatic architecture astronauts.