arXiv:2610.33889cs.DSOct 2026

Manuscript Offprint

arXiv:2610.33889

Engineering Lightweight Burrows-Wheeler Transform Construction on the GPU via Prefix-Free Parsing

Florian Kurpicz, Maximilian Paris

Abstract

The Burrows–Wheeler transform (BWT) is the core of many compressed full-text indexes and most read aligners. The fastest BWT constructions on GPUs need about 20 bytes of device memory per character, which severely limits the texts that can be processed there. For example, on our GPU with 24 GB device memory, this is only about 1 200 MiB. Prefix-free parsing (PFP) can be used to reduce the memory requirements of BWT construction algorithms in main memory. But, it uses hash tables and inverted lists which are not suited for GPUs. We show that PFP-based BWT construction can work with only sorting, scanning, or simple data-parallel procedures. This results in our GPU construction gpupfpbwt that on an NVIDIA RTX 3090, reduces the peak memory on an English text to 11.9 bytes per character. There, it can processes 2 108 MiB input files, which is 1.8 times larger than what the current state of the art libcubwt can handle. It is faster than or on par with libcubwt on eight of nine repetitive texts but 2.0 to 3.2 times slower on five of six non-repetitive ones, i.e., it provides a trade-off between required device memory and throughput.

2012 ACM Subject Classification Theory of computation → Data compression; Theory of computation → Sorting and searching

Keywords and phrases Burrows–Wheeler transform, prefix-free parsing, GPU, suffix sorting, memory-efficient algorithms

Related Version Based on M. Paris' Master's thesis [96].

Supplementary Material https://codeberg.org/kurpicz/gpupfpbwt (source code)

1 Introduction

The Burrows–Wheeler transform (BWT) [18] of a text is the sequence of the characters that precede the text’s suffixes in lexicographic order. It is reversible and used in compression [18, 77]. A BWT consists of rr maximal runs of equal characters, which can be stored in O(r)O(r) words. Here, each run is represented by its character and length. This makes rr a common measure of the compressibility of a text. Since the BWT supports pattern matching in compressed form, it is the core of compressed full-text indexes such as the FM-index [30], the r-index [39], and the move data structure [85]. These indexes are used read aligners such as Bowtie [64], BWA [68], and SOAP2 [69] (FM-index) and pangenome indexes such as MONI [102] (r-index), Movi [110], and Movi 2 [111] (move data structure).

The BWT can be construed by sorting all suffixes of the text, a data-parallel task that suits GPUs. The fastest GPU BWT construction, libcubwt [42], needs about 20 bytes of device memory per character. On a consumer GPU with 24 GB of memory, this limits libcubwt to texts of about 1 200 MiB, far below the size of the string collections and pangenomes that BWT-based indexes are built for. In main memory, PFP-BWT, the construction based on prefix-free parsing (PFP) [16], reduces the required working memory.

Engineering Lightweight BWT Construction on the GPU via Prefix-Free Parsing

Our Contributions. We port prefix-free parsing to the GPU. Our key observation is that some structures, e.g., the hash tables and inverted lists of the original unnecessary. If all phrase occurrences are kept instead of the distinct phrases, we can obtain all necessary information just by sorting. Every step of our algorithm thus becomes a sort, a scan, or a simple data-parallel kernel. After the preliminaries (Section 2), related work (Section 3), and the original PFP-BWT algorithm (Section 4), we present

■ a formulation of PFP-BWT that consists of sorts and scans only (Section 5),

■ memory levels that need less memory than libcubwt (Sections 6.1 and 6.2.1),

■ two sorting cores and a space-saving configuration (Sections 6.3–6.5), and

■ an extensive experimental evaluation (Section 7).

References (100)

Couldn't load all references. Reload the page to try again.