An efficient profile-analysis framework for data-layout optimizations

  • Authors:
  • Shai Rubin;Rastislav Bodík;Trishul Chilimbi

  • Affiliations:
  • University of Wisconsin-Madison, Madison, WI;University of Wisconsin-Madison, Madison, WI;Microsoft Research, Redmond, WA

  • Venue:
  • POPL '02 Proceedings of the 29th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
  • Year:
  • 2002

Quantified Score

Hi-index 0.00

Visualization

Abstract

Data-layout optimizations rearrange fields within objects, objects within objects, and objects within the heap, with the goal of increasing spatial locality. While the importance of data-layout optimizations has been growing, their deployment has been limited, partly because they lack a unifying framework. We propose a parameterizable framework for data-layout optimization of general-purpose applications. Acknowledging that finding an optimal layout is not only NP-hard, but also poorly approximable, our framework finds a good layout by searching the space of possible layouts, with the help of profile feedback. The search process iteratively prototypes candidate data layouts, evaluating them by "simulating" the program on a representative trace of memory accesses. To make the search process practical, we develop space-reduction heuristics and optimize the expensive simulation via memoization. Equipped with this iterative approach, we can synthesize layouts that outperform existing non-iterative heuristics, tune application-specific memory allocators, as well as compose multiple data-layout optimizations.