← Back to all sparks
Q

quickr

INFRA · APIS
Velocity0.0

quickr's R-to-Fortran compiler now handles matrices, closures and OpenMP.

compilersfortranlinear-algebraparallelismr-package
Current state
quickr compiles a subset of R to Fortran and calls it back from R, so numerical code can run without hand-writing C or Fortran. Version 0.3.0 is the release where that subset stops being small: matrix and linear algebra operations lower to the same BLAS/LAPACK that R uses, local closures and sapply() are supported with copy-on-modify semantics preserved, and for loops and sapply() calls can be marked for OpenMP parallelism via declare(parallel()).
Where it's heading
The first two releases filled in language basics, control flow, arithmetic operators, multiple return values. Version 0.3.0 shifts to the constructs real numerical code is actually written in, and the compiler work underneath it, nested compilation scopes and block-scoped temporaries, is aimed at large functions and heap-versus-stack control for big temporaries. Toolchain work points the same way: LLVM flang is used on macOS when present, and the minimum R version was lowered to 4.3.0 to widen who can install it.
Prediction
Expect the next releases to keep extending the compilable subset toward the remaining apply-family functions and to build out the parallelism story that declare(parallel()) opens.

Recent moves

  1. 3mo ago

    Linear algebra, local closures and OpenMP land in quickr

    ⚡ SPARK

    The release that moves quickr from compiling toy numeric loops to compiling the shape of code people actually write. It also carries the first breaking change, restricting vector-matrix recycling to the first axes.

    View source ↗
  2. 8mo ago

    Negation, unary operators and multi-array returns compile

    Adds unary operators and lets compiled functions return several arrays in a named list. Language-basics work of the kind 0.3.0 then built on top of.

    View source ↗
  3. 11mo ago

    Loops, modular arithmetic and RNG integration reach the compiler

    Brings while, repeat, break and next, the modulo operators, and runif() wired into R's own RNG, alongside dimension helpers and a set of correctness fixes. The control-flow groundwork the later releases depend on.

    View source ↗