Towards Formalizing the Semantics of Lifting Argument Frames When Evaluating Remora Expressions
Based on APL, Remora is a rank-polymorphic language designed to simplify the task of writing efficient, GPU-aware code. As such, it avoids using iteration (including loops and recursion) by defining a "lifting" mechanism that automatically runs a function that expects an argument of a given dimension over all matching parts of a higher-dimension argument. In simple cases, this is straightforward; e.g., calling ABS on a vector performs an implicit MAP, so it returns a new vector with the absolute value of each of its elements. More generally, the exact mechanics of this lifting process are quite complicated, as they depend on all arguments to the function, which need only partially match in shape. In this paper, we describe a methodology that we follow to reason about the behavior of lifting primitive operations over compatible arguments.
- arXiv
- 2612.05775
- Authors
- Ruben Gamboa
- Categories
- cs.LO · cs.PL