Abstract
Sequence data structures, i.e., data structures that provide operations on an ordered set of items, are heavily used by many applications. For sequence data structures to be efficient in practice, it is important to amortize expensive data-structural operations by chunking a relatively small, constant number of items together, and representing them by using a simple but fast (at least in the small scale) sequence data structure, such as an array or a ring buffer. In this paper, we present chunking techniques, one direct and one based on bootstrapping, that can reduce the practical overheads of sophisticated sequence data structures, such as finger trees, making them competitive in practice with specialpurpose data structures. We prove amortized bounds showing that our chunking techniques reduce runtime by amortizing expensive operations over a user-defined chunk-capacity parameter. We implement our techniques and show that they perform well in practice by conducting an empirical evaluation. Our evaluation features comparisons with other carefully engineered and optimized implementations.
This is a preview of subscription content, log in via an institution.
Buying options
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
Acar, U.A., Charguéraud, A., Rainey, M.: Theory and practice of chunked sequences, http://deepsea.inria.fr/chunkedseq (full version)
Bernardy, J.-P.: The Haskell yi package, http://hackage.haskell.org/package/yi-0.6.2.3/docs/src/Data-Rope.html
Buchsbaum, A.L., Tarjan, R.E.: Confluently persistent deques via data-structural bootstrapping. J. Algorithms 18(3), 513–547 (1995)
Buchsbaum, A.L.: Data-structural bootstrapping and catenable deques. PhD thesis, Princeton University (1993)
Stanford Large Network Dataset Collection. Friendster graph, http://snap.stanford.edu/data/com-Friendster.html
Dietz, P.F.: Maintaining order in a linked list. In: STOC 1982, Baltimore, USA, pp. 122–127. ACM Press (May 1982)
Guibas, L.J., McCreight, E.M., Plass, M.F., Roberts, J.R.: A new representation for linear lists. In: STOC 1977, pp. 49–60. ACM, New York (1977)
Hinze, R., Paterson, R.: Finger trees: a simple general-purpose data structure. JFP 16(2), 197–218 (2006)
Kaplan, H., Tarjan, R.E.: Persistent lists with catenation via recursive slow-down. In: TOC 1995, pp. 93–102. ACM (1995)
Kaplan, H., Tarjan, R.E.: Purely functional representations of catenable sorted lists. In: STOC 1996, pp. 202–211. ACM, New York (1996)
Knuth, D.E.: The Art of Computer Programming: Sorting and Searching, 2nd edn., vol. 3, ch. 6, pp. 481–489. Addison-Wesley (1998)
Leiserson, C.E., Schardl, T.B.: A work-efficient parallel breadth-first search algorithm. In: SPAA 2010, pp. 303–314 (June 2010)
SGI. Stl rope, http://www.sgi.com/tech/stl/Rope.html
Stepanov, A., Lee, M.: The Standard Template Library, volume 1501. HP Laboratories (1995)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2014 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Acar, U.A., Charguéraud, A., Rainey, M. (2014). Theory and Practice of Chunked Sequences. In: Schulz, A.S., Wagner, D. (eds) Algorithms - ESA 2014. ESA 2014. Lecture Notes in Computer Science, vol 8737. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-662-44777-2_3
Download citation
DOI: https://doi.org/10.1007/978-3-662-44777-2_3
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-662-44776-5
Online ISBN: 978-3-662-44777-2
eBook Packages: Computer ScienceComputer Science (R0)