4 ms·
I liked this article, but at the end, it seems like the author conflates dynamic and interpreted languages: > Interpreted languages like Ruby, Python, Perl, an
by zck 17y ago
I liked this article, but at the end, it seems like the author conflates dynamic and interpreted languages:
> Interpreted languages like Ruby, Python, Perl, and yes, even PHP, are now replacing compiled languages...Yes I am aware Ruby, Python, Perl, and PHP can now be compiled, but they will always retain their dynamic heritage.
As far as I know, it's only historical accident and ease of programming that has made them correlate.
- jordanb 17y agoYou have to include a lot more in a binary to make a dynamic language compilable to machine language. So there's some natural fit to running a dynamic language on a virtual machine. That said, you're completely correct that you can compile dynamic languages to machine language, and that static languages (hello Java) run great on virtual machines. His "history" of languages is pretty warped too. The original IBM Fortran compiler could produce code as efficient as assembler. That was a design requirement. The issue in the early days was that -- for those who were capable -- writing machine language was quicker than having to go through the additional step (on batch processing machines) of getting the code compiled. Furthermore, the original FORTRAN compiler was designed to turn algebra-like expressions into 704 machine code. What really made HLLs take off was the idea that you could abstract away the particulars of the machine. This decoupled programs written in HLLs from particular machines, it also made the abstraction layer much thicker than existed in FORTRAN I. For a long time, there was performance gap between code written with contemporary HLLs and hand-tuned machine code. If you had a particularly tight loop of a program, it might make sense to write it in assembly for at least some of the supported platforms, to avoid the gap. Actually that gap still exists in some situations, but compilers have gotten better and Moore's Law has reduced the effect. He seems to think that there was some fundamental cultural shift at work -- when in fact it was a matter of a slow evolution of compiler and machine technology which eventually changed the engineering calculation such that hand-writing assembler code has become a very rare activity.
- mahmud 17y agoHow would you classify Forth in terms of typing, and runtime binary size? :-) The only reason dynamic languages need to do more to run on stock hardware is that mainstream processor design has been about optimizing for Fortran evaluation. Algolish languages generate small binaries because their necessary runtimes are already pre-wired into the x86 :-)