3 ms·
> Before writing compilers, I think it's best to understand computer architectures, and what needs to be generated by the compiler to yield the most efficient m
by sabas123 3y ago
> Before writing compilers, I think it's best to understand computer architectures, and what needs to be generated by the compiler to yield the most efficient machine code.
In my opinion one of the biggest industry advancements we have had is that compilers are now available without such level of low-level detail.
There is still so much work to be done on a compiler level that really shouldn't concern themselves with the (micro)-architectural level of computers.
- mgaunard 3y agoIt seems the trend is in increased diversity of hardware, with the dominance of x86 being reconsidered with smartphones, energy-optimal cloud, GPU computing, and ML accelerators. LLVM allows hardware manufacturers to more easily provide mainstream language support for their platform than before, but the problem here was mostly that GCC was hostile to modular design, not really theoretical advances. In terms of frontends, I guess we're seeing more languages reach C-level performance thanks to LLVM again. But in terms of optimizations driven by theory? There were some significant advancements in generic auto-parallelization for imperative languages, about a decade ago I think. And it it doesn't magically solve the codegen problem, and remains hampered by language semantics that are not always parallelization-friendly. There were a bunch of improvements which were driven by making languages more hardware-aware, e.g. the concurrent C++ model in 2011 which was widely copied to other low-level programming languages. We're also seeing more and more libraries that are specifically designed to target hardware features better. So ultimately it looks like most of the advances are driven by better integration of how the hardware works throughout the compiler, language and community.
- shrimp_emoji 3y ago> I guess we're seeing more languages reach C-level performance thanks to LLVM again. If they made JavaScript as fast as C, the software industry will become a cheap perversion of what it once was, and I'm picking up my toys and going home.