Return
cuJSON: A Highly Parallel JSON Parser for GPUs
DOI:10.1145/3760250.3762222.png)
Abstract
En 中文
JSON (JavaScript Object Notation) data is widely used in modern computing, yet its parsing performance can be a major bottleneck. Conventional wisdom suggests that GPUs are ill-suited for parsing due to the branch-heavy nature of parsing algorithms. This work challenges that notion by presenting cuJSON, a novel JSON parser built on a new parsing algorithm, specifically tailored for GPU architectures with minimal branching and maximal parallelism. cuJSON offloads three main phases of JSON parsing to the GPU, including (i) UTF validation, (ii) tokenization, and (iii) nesting structure recognition. Each phase is powered by a parallel algorithm optimized for GPUs, leveraging intrinsic GPU functions and high-performance CUDA libraries for acceleration. To maximize parsing speed, cuJSON's output format is also designed to facilitate parallel construction. Finally, cuJSON can break key dependencies in the parsing process, enabling parallel parsing of a single large JSON file effectively. Evaluation shows that cuJSON not only outper-forms highly optimized CPU-based parsers like simdjson and Pison but also surpasses existing GPU-based parsers like cuDF and GPJSON, in terms of both functionality and performance. The source code of cuJSON is available at https://github.com/AutomataLab/cuJSON.
Keywords:
JSON
Parsing
GPU
Parallel Parsing
GPU-based Parsing
UTF Validation
Tokenization

