3 ms·
Sure, but of course if you want raw speed you would write assembly. Most people move up the food chain to C to get some basic level of correctness. I think the
by swannodette 16y ago
Sure, but of course if you want raw speed you would write assembly. Most people move up the food chain to C to get some basic level of correctness.
I think the history of production oriented PLs has revolved around balancing correctness/performance. And it's always a question of diminishing return (I've written enough C/C++/Objective-C++ to know this). Every sizeable application I've written in a lower level language eventually approaches some kind of wacky manual memory management scheme to preserve performance w/o sacrificing correctness. I think Clojure's solution is a step in the right direction.
But no, if I was writing a real-time system with extremely limited memory constraints I would not write in the Clojure. But I don't think that's what this thread is about.
- lukev 16y agoThere is a large class of problems that aren't worth writing in assembly but for which Clojure is (currently) still too slow. Sometimes you just need something at Java's (or preferably Scala's) position on the power/performance spectrum. That said, the way Clojure is improving, I think it will continue to asymptotically approach Java's speed anyway.