Re:The "C is Efficient" Language Fallacy
by tptacek on Monday May 04, 2009 @05:43PM
(#593139)
Another classic HLL vs. C argument: the anecdotal slow C program. Clearly, of these, there are many great examples. Unfortunately, it's a crappy argument, because there are also a zillion incredibly slow HLL programs.
[ Parent
| on HN ]
I don't think stcredzero meant that as an argument that C is worse than HLL -- it was just a warning that, as with any tool, it can be improperly used.
Re:The "C is Efficient" Language Fallacy
by stcredzero on Monday May 04, 2009 @06:33PM
(#593222)
I'm certainly not against C. I've just used C to write an embedded controller for doing real-time mixing of PWM control signals and laser gyroscope data for a model tilt-wing aircraft. (Which should be able to convert between horizontal and vertical modes in-flight.) I wouldn't use Smalltalk for that. (Yet. If I had 10X more CPU to burn, maybe.) Likewise, I'm not going to write my next Commodities Trading app in C.
That is a false dilemma tho'. No-one in the Python world has anything invested in a 100% Python solution to anything. Doing the compute-intensive bits in C is in fact expected and encouraged! The same is true in the Tcl camp. Maybe some HLL communities (Java?) like to be "pure" but I've not ever encountered that.
Re:The "C is Efficient" Language Fallacy
by robin_reala on Tuesday May 05, 2009 @07:55AM
(#593950)
No-one in the Python world has anything invested in a 100% Python solution to anything
That's not for production use, tho'.
Java communities typically favor portability (and easy deployment) over what you can gain in terms of speed. A lot of libraries/frameworks actually even advertise themselves as "100% pure java", whereas one might expect "expensive bits optimized in C" as attractive as well (but you rarely see it).
> whereas one might expect "expensive bits optimized in C"
There is no important difference in performance between C and Java according to http://shootout.alioth.debian.org/
That all depends on the kind of code, of course.