Get the latest tech news

My Ideal Array Language


2025-07-20 What do I think the ideal array language should look like? - My Ideal Array Language - Why does this matter? - User-Extensible Rank Polymorphism - Value Semantics and Automatic Bufferization - Compilation Step - SIMT and Automatic Parallelization - Array-Aware Type System - Syntax - Conclusion - Bonus: Comparing Parallel Functional Array Languages Why does this matter? The fundamental units of computation available to users today are not the same as they were 20 years ago. When users had at most a few cores on a single CPU, it made complete sense that every program was written with the assumption that it would only run on a single core.

If you then turn the optimization level up to-O3 by changing the compiler flags in the top-right, you can search for the pass OptimizedBufferization which leverages the language semantics to reduce and reuse memory in the program, and you’ll notice that the temporary array is no longer present in the IR. An ideal array language should be able to represent this kind of dynamic shape information in the type system and leave space for the compiler to perform these sorts of optimizations. This is why I am still so interested in Fortran even though it is largely a procedural language - the Flang compiler is able to represent programs in an unbufferized array-oriented SSA intermediate representation, which lends itself so well to optimization.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Ideal Array Language

Ideal Array Language