Optimizing Layout of Recursive Datatypes with Marmoset (Artifact)

Authors Vidush Singhal , Chaitanya Koparkar , Joseph Zullo , Artem Pelenitsyn , Michael Vollmer , Mike Rainey , Ryan Newton , Milind Kulkarni



PDF
Thumbnail PDF

Artifact Description

DARTS.10.2.21.pdf
  • Filesize: 0.65 MB
  • 10 pages

Document Identifiers

Author Details

Vidush Singhal
  • Purdue University, West Lafayette, IN, USA
Chaitanya Koparkar
  • Indiana University, Bloomington, IN, USA
Joseph Zullo
  • Purdue University, West Lafayette, IN, USA
Artem Pelenitsyn
  • Purdue University, West Lafayette, IN, USA
Michael Vollmer
  • University of Kent, UK
Mike Rainey
  • Carnegie Mellon University, Pittsburgh, PA, USA
Ryan Newton
  • Purdue University, West Lafayette, IN, USA
Milind Kulkarni
  • Purdue University, West Lafayette, IN, USA

Acknowledgements

This work was supported in part by NSF CCF-1908504, CCF-1919197, CCF-2216978, CCF-2119352, CCF-1909862 and EPSRC EP/X021173/1.

Cite AsGet BibTex

Vidush Singhal, Chaitanya Koparkar, Joseph Zullo, Artem Pelenitsyn, Michael Vollmer, Mike Rainey, Ryan Newton, and Milind Kulkarni. Optimizing Layout of Recursive Datatypes with Marmoset (Artifact). In Special Issue of the 38th European Conference on Object-Oriented Programming (ECOOP 2024). Dagstuhl Artifacts Series (DARTS), Volume 10, Issue 2, pp. 21:1-21:10, Schloss Dagstuhl – Leibniz-Zentrum für Informatik (2024)
https://doi.org/10.4230/DARTS.10.2.21

Artifact

Artifact Evaluation Policy

The artifact has been evaluated as described in the ECOOP 2024 Call for Artifacts and the ACM Artifact Review and Badging Policy.

Abstract

While programmers know that memory representation of data structures can have significant effects on performance, compiler support to optimize the layout of those structures is an under-explored field. Prior work has optimized the layout of individual, non-recursive structures without considering how collections of those objects in linked or recursive data structures are laid out. This work introduces Marmoset, a compiler that optimizes the layouts of algebraic datatypes, with a special focus on producing highly optimized, packed data layouts where recursive structures can be traversed with minimal pointer chasing. Marmoset performs an analysis of how a recursive ADT is used across functions to choose a global layout that promotes simple, strided access for that ADT in memory. It does so by building and solving a constraint system to minimize an abstract cost model, yielding a predicted efficient layout for the ADT. Marmoset then builds on top of Gibbon, a prior compiler for packed, mostly-serial representations, to synthesize optimized ADTs. We show experimentally that Marmoset is able to choose optimal layouts across a series of microbenchmarks and case studies, outperforming both Gibbon’s baseline approach, as well as MLton, a Standard ML compiler that uses traditional pointer-heavy representations.

Subject Classification

ACM Subject Classification
  • Software and its engineering → Compilers
  • Software and its engineering → Software performance
  • Information systems → Data layout
Keywords
  • Tree traversals
  • Compilers
  • Data layout optimization
  • Dense data layout

Metrics

References

  1. Creative commons attribution 4.0 international license. https://creativecommons.org/licenses/by/4.0/. Accessed: 2024-07-12.
  2. Shirley Browne, Jack Dongarra, Nathan Garner, George Ho, and Phil Mucci. A portable programming interface for performance evaluation on modern processors. The International Journal of High Performance Computing Applications, 14(3):189-204, 2000-09 2000. URL: https://doi.org/10.1177/109434200001400303.
  3. Dirk Merkel. Docker: lightweight linux containers for consistent development and deployment. Linux journal, 2014(239):2, 2014. Google Scholar
  4. Vidush Singhal, Chaitanya Koparkar, Joseph Zullo, Artem Pelenitsyn, Michael Vollmer, Mike Rainey, Ryan Newton, and Milind Kulkarni. Optimizing layout of recursive datatypes with marmoset, 2024. URL: https://arxiv.org/abs/2405.17590.
  5. Michael Vollmer, Chaitanya Koparkar, Mike Rainey, Laith Sakka, Milind Kulkarni, and Ryan R. Newton. Local: a language for programs operating on serialized data. In Proceedings of the 40th ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI 2019, pages 48-62, New York, NY, USA, 2019. Association for Computing Machinery. URL: https://doi.org/10.1145/3314221.3314631.
  6. Michael Vollmer, Sarah Spall, Buddhika Chamith, Laith Sakka, Chaitanya Koparkar, Milind Kulkarni, Sam Tobin-Hochstadt, and Ryan R. Newton. Compiling Tree Transforms to Operate on Packed Representations. In Peter Müller, editor, 31st European Conference on Object-Oriented Programming (ECOOP 2017), volume 74 of Leibniz International Proceedings in Informatics (LIPIcs), pages 26:1-26:29, Dagstuhl, Germany, 2017. Schloss Dagstuhl - Leibniz-Zentrum für Informatik. URL: https://doi.org/10.4230/LIPIcs.ECOOP.2017.26.
Questions / Remarks / Feedback
X

Feedback for Dagstuhl Publishing


Thanks for your feedback!

Feedback submitted

Could not send message

Please try again later or send an E-mail