A Catenable, Splittable, Transient Sequence Data Structure
A transient data structure is a combination of an ephemeral data structure, a persistent data structure, and fast conversions between them. We present a transient sequence data structure that supports efficient read and write access at an arbitrary index with worst-case time complexity O ( K log K n ), pushing and popping at either end with complexity O ( K log K n ), and splitting and concatenation with complexity O ( K log K n +log K 2 n ), where K is a user-defined chunk size and n is the length of the sequence. We provide a detailed analysis of this data structure and show that, in many favorable scenarios, it performs much better than these pessimistic bounds might suggest. Furthermore, we describe its implementation, and provide a synthetic benchmark to evaluate the performance of push and pop . We believe that it is a good candidate for a one-size-fits-all, general-purpose sequence data structure.
Authors
- Arthur Charguéraud (ORCID: https://orcid.org/0000-0001-7764-4507)
- François Pottier (ORCID: https://orcid.org/0000-0002-4069-1235)
Institutions
- Centre National de la Recherche Scientifique (FR)
- Institut national de recherche en sciences et technologies du numérique (FR)
- Laboratoire des Sciences de l'Ingénieur, de l'Informatique et de l'Imagerie (FR)
- Université de Strasbourg (FR)
Publication Details
- Journal
- Proceedings of the ACM on Programming Languages
- Published
- 2026-08-17
- DOI
- https://doi.org/10.1145/3828706
- Primary Topic
- Algorithms and Data Compression
- Type
- article
- Field-Weighted Citation Impact
- 0.00
Funders
- Agence Nationale de la Recherche