NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Compile Time Prediction of Cache Reuse for Array Applications with Multiple Loop Nests

Abdur Razzak, Yehia Arafa, Nishant Panda, Abdel‐Hameed A. BadawyProceedings of the International Symposium on Memory Systems 2025

Abstract

Efficient memory access patterns play a crucial role in determining the overall performance of applications by exploiting temporal and spatial locality, thus maximizing cache locality. The Reuse Distance Histogram (RDH) is a widely used metric to quantify temporal locality, measuring the distance between consecutive accesses to the same memory location. Traditionally, calculating RDH requires program execution and memory trace collection to obtain dynamic memory access behavior. This trace collection is often time-consuming, resource-intensive, and unsuitable for early-stage optimization or large-scale applications. Static prediction, on the other hand, offers a significant speedup in estimating RDH and cache hit rates. However, these approaches often lack accuracy, as predictions are made without executing the program or observing the complete memory access pattern. Specifically, when arrays are used inside nested loops, predicting the access patterns of array references without observing their exact execution sequence presents a significant challenge. This paper presents a novel static analysis framework for predicting the reuse profiles of array references in programs with nested loop structures, independent of runtime information. By analyzing loop bounds, access patterns in smaller problem sizes, and predictive equations, our method predicts array access patterns and estimates reuse distances and cache hit rates at compile time. This paper extends our previous study by incorporating a deeper analysis and improving prediction by addressing previously unhandled reuse patterns. We evaluated our technique against a widely accepted traditional trace-driven profiling tool, Parallel Reuse Distance Analysis (PARDA). The results demonstrate that our static predictor achieves comparable accuracy while offering orders-of-magnitude improvement in analysis speed, excluding setup time. This work presents a practical alternative to dynamic reuse profiling for array applications with multiple loops, paving the way for integration into compilers and static performance modeling tools.
BibTeX
@inproceedings{razzak2025compile,
  author = {Abdur Razzak and Yehia Arafa and Nishant Panda and Abdel‐Hameed A. Badawy},
  title = {{Compile Time Prediction of Cache Reuse for Array Applications with Multiple Loop Nests}},
  booktitle = {Proceedings of the International Symposium on Memory Systems},
  year = {2025},
  doi = {10.1145/3767110.3767128},
}

Loading related content...

Figure