by hacknat · 10y ago · 0 comments
I think we know now that tailoring a processor to a particular language isn't particularly efficient (though the opposite i.e. assembly is).
And yet, given the way C exploits have plagued the industry, Intel, ARM, CHERI are actually adding tagged instructions that allow C compilers to generate code that validates array and pointer accesses at hardware level.
Just like the language specific processors that you state as not being efficient.
Early on there were efforts to build custom Lisp machines, etc. which were abandoned when CPUs became good enough and general purpose enough. Using a stack processor as a stack language target seems natural until you see all the inefficient stack gymnastics that go on at the lowest level.
Even I that usually bash C here, do use it when customers or a specific project requires it. I just try to follow all best practices to make it as safe as I can, ignoring third party code.
However I can convinced that Lisp Machines, Xerox PARC and Burroughs micro-architectures, Rational Ada Machines, i432, could have been much better.
Many times technology solutions fail not because they aren't good, rather the people aren't willing to invest the time they require to become good enough.
For example JavaScript JITs, if it wasn't for the research money that Google and other vendors are willing to invest, no one would believe they would achieve the execution speed they have nowadays.
I also remember when Z80 coders could easily outperform C, Pascal, Basic and Modula compilers for 8 bit micros.