Making R run Fast - Jan Vitek
Why Hacker News recommends it
HN points to it as the best explanation of why R is so hard to optimize, often paired with talks on Python and used to explain what makes Julia fast.
What it is
Jan Vitek of Northeastern University gives a meetup talk on the challenges of making the R language run fast. He explains what in R's semantics makes it hard to optimize and to build a JIT compiler for.
Recommended by 3 HN commenters across 3 different months, 2017 to 2023.
What Hacker News said
Recommends simonbyrne · 2017-07 · on “Back to the Future: Lisp as a Base for a Statistical Computing System [pdf]”
Another talk on the difficulty of optimising R is this fantastic one by Jan Vitek: [this video] Also, my favourite R trick: foo <- function() {rm(foo, envir=environment(foo))}
Recommends StefanKarpinski · 2018-06 · on “My favorite things that are coming with Julia 1.0”
Perhaps the best way to understand what makes Julia fast is to watch these two videos about Python and R and what makes them so hard to optimize: [LINK] [this video] Take everything mentioned in these videos that make Python and R really hard to optimize and don't do those things :D
Recommends lottin · 2018-10 · on “Faster R with FastR”
I recommend watching this video - Making R run fast [this video] It's a little disappointing, because the conclusion is that R will probably never "run fast", but very interesting nonetheless.
Cites ChrisRackauckas · 2023-02 · on “ML would have advanced faster if another front-end language had been adopted?”
This is disregarding the development of said ecosystems though. The point is that Python has been quite inhibitory to the development of this ecosystem. There are many corpses of automatic differentiation libraries (starting from autograd and tangent and then to things like theano to finally tensorflow and pytorch) and many corpses of JIT compilers and accelerators (Cython, Numba, pypy, and TensorFlow XLA, now PyTorch v2's JIT, etc.). What has been found over the last decade is that a large part of that is due to the design of the languages. Jan Vitek for example has a great talk which describes how difficult it is to write a JIT compiler for R due to certain design choices in the language (