MojoFrame: Dataframe Library in Mojo Language

Read full text
Authors: Shengya Huang, Zhaoheng Li, Derek Werner, Yongjoo Park
Cited by: 0
References: 134

Abstract

Mojo is an emerging programming language built on MLIR (Multi-Level Intermediate Representation) and supports JIT (Just-in-Time) compilation. It enables transparent hardware-specific optimizations (e.g., for CPUs and GPUs), while allowing users to express their logic using Python-like user-friendly syntax. Mojo has demonstrated strong performance on tensor operations; however, its capabilities for relational operations (e.g., filtering, join, and group-by aggregation) common in data science workflows, remain unexplored. To date, no dataframe implementation exists in the Mojo ecosystem. In this paper, we introduce the first Mojo-native dataframe library, called MojoFrame, that supports core relational operations and user-defined functions (UDFs). MojoFrame is built on top of Mojo's tensor to achieve fast operations on numeric columns, while utilizing a cardinality-aware approach to effectively integrate non-numeric columns for flexible data representation. To achieve high efficiency, MojoFrame takes significantly different approaches than existing libraries. We show that MojoFrame supports all operations for TPC-H queries and a selection of TPC-DS queries with promising performance, achieving up to 4.60x speedup versus existing dataframe libraries in other programming languages. Nevertheless, there remain optimization opportunities for MojoFrame (and the Mojo language), particularly in in-memory data representation and dictionary operations.

Fields of Study & Subjects

Advanced Database Systems and Queries Scientific Computing and Data Management Parallel Computing and Optimization Techniques

Publication details

Journal / source
2026 IEEE 42nd International Conference on Data Engineering (ICDE)
Publisher
IEEE
Pages
1391–1405
Publication date
1 May 2026
Language
EN