Exact analysis of the cache behavior of nested loops
The DOI matches its Crossref record; 41 of the 41 references it cites were found in a registry or an index.
Abstract
We develop from first principles an exact model of the behavior of loop nests executing in a memory hicrarchy, by using a nontraditional classification of misses that has the key property of composability. We use Presburger formulas to express various kinds of misses as well as the state of the cache at the end of the loop nest. We use existing tools to simplify these formulas and to count cache misses. The model is powerful enough to handle imperfect loop nests and various flavors of non-linear array layouts based on bit interleaving of array indices. We also indicate how to handle modest levels of associativity, and how to perform limited symbolic analysis of cache behavior. The complexity of the formulas relates to the static structure of the loop nest rather than to its dynamic trip count, allowing our model to gain efficiency in counting cache misses by exploiting repetitive patterns of cache behavior. Validation against cache simulation confirms the exactness of our formulation. Our method can serve as the basis for a static performance predictor to guide program and data transformations to improve performance.
Overview
The claims and statistics of this paper haven’t been checked yet.
Free: it reads the open-access text and checks the first 5 claims that cite a source we can check. Create a free account to check every claim.
Integrity signals
Registry
Cites
Statistics
Verification
Claims the paper makes
The claims and statistics of this paper haven’t been checked yet.
Free: it reads the open-access text and checks the first 5 claims that cite a source we can check. Create a free account to check every claim.
Self-check
Percentages, sums and reported differences re-computed from the paper’s own numbers.
The self-check needs the paper’s full text.
Citations
Cites
Lecture Notes in Computer Science 1205
(1999) · Industrial Robot: An International Journal · doi:10.1108/ir.1999.04926fae.001 · Cited by 38,662
Introduction to automata theory, languages and computation
(1981) · Mathematics and Computers in Simulation · doi:10.1016/0378-4754(81)90068-9 · Cited by 10,699
Introduction to automata theory, languages, and computation
(1980) · Computer Languages · doi:10.1016/0096-0551(80)90011-9 · Cited by 6,824 · cited 1×
“Presburger arithmetic [31] is the subset of first order logic corresponding to the theory of integers with addition.”
BackgroundA data locality optimizing algorithm
Wolf, M. E., & Lam, M. S. (1991) · Proceedings of the ACM SIGPLAN 1991 conference on Programming language design and implementation - PLDI '91 · doi:10.1145/113445.113449 · Cited by 1,331 · cited 1×
“However, models of the expected performance gains of performing a given loop transformation are less well-developed [19, 38, 45, 48, 50, 51, 61].”
BackgroundATOM: a system for building customized program analysis tools
Srivastava, A., & Eustace, A. (1994) · ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI) · doi:10.1145/178243.178260 · Cited by 981
The cache performance and optimizations of blocked algorithms
Lam, M. D., Rothberg, E. E., & Wolf, M. E. (1991) · Proceedings of the fourth international conference on Architectural support for programming languages and operating systems - ASPLOS-IV · doi:10.1145/106972.106981 · Cited by 921 · cited 4×
“For example, tiling requires the choice of tile sizes, and the performance of a loop nest is typically a non-smooth function of the extents of the loop bounds, the tile sizes, and the cache parameters [13, 29, 7].”
BackgroundInfluentialEvaluating associativity in CPU caches
Hill, M. D., & Smith, A. J. (1989) · IEEE Transactions on Computers · doi:10.1109/12.40842 · Cited by 606 · cited 3×
“The structure of a single level of a memory hierarchy—a cache— is generally characterized by three parameters [30]: Associativity, Block size, and Capacity.”
BackgroundInfluentialDataflow analysis of array and scalar references
Feautrier, P. (1991) · International Journal of Parallel Programming · doi:10.1007/bf01407931 · Cited by 567
Wolfe, M. (1989) · Proceedings of the 1989 ACM/IEEE conference on Supercomputing - Supercomputing '89 · doi:10.1145/76263.76337 · Cited by 429 · cited 1×
“Loop transformations such as iteration space tiling [62] are a major source of performance benefits.”
BackgroundTile size selection using cache organization and data layout
Coleman, S., & McKinley, K. S. (1995) · Proceedings of the ACM SIGPLAN 1995 conference on Programming language design and implementation · doi:10.1145/207110.207162 · Cited by 402 · cited 2×
“For example, tiling requires the choice of tile sizes, and the performance of a loop nest is typically a non-smooth function of the extents of the loop bounds, the tile sizes, and the cache parameters [13, 29, 7].”
Background
Cited by
Self-Adapting Linear Algebra Algorithms and Software
Demmel, J., Dongarra, J., Eijkhout, V., Fuentes, E., Petitet, A., Vuduc, R., Whaley, R. C., & Yelick, K. (2005) · Proceedings of the IEEE · doi:10.1109/jproc.2004.840848 · Cited by 204
“For example, CSR storage prevents automatically tiling accesses to x for either registers or caches, as might be done in the dense case [40], [41], [42], [43].”
BackgroundProgram locality analysis using reuse distance
Zhong, Y., Shen, X., & Ding, C. (2009) · ACM Transactions on Programming Languages and Systems · doi:10.1145/1552309.1552310 · Cited by 166
“There are a number of compiler techniques that estimate the miss rate of a program [Porter.eld 1989; Ferrante et al. 1991; Ghosh et al. 1999; Chatterjee et al. 2001; Xue and Vera 2004].”
BackgroundA comparison of empirical and model-driven optimization
Yotov, K., Li, X., Ren, G., Cibulskis, M., DeJong, G., Garzaran, M., Padua, D., Pingali, K., Stodghill, P., & Wu, P. (2003) · ACM SIGPLAN Notices · doi:10.1145/780822.781140 · Cited by 165
Estimating cache misses and locality using stack distances
CaΒcaval, C., & Padua, D. A. (2003) · Proceedings of the 17th annual international conference on Supercomputing · doi:10.1145/782814.782836 · Cited by 163
“[6] use Presburger formulas to express various kinds of misses as well as the state of the cache at the beginning and at the end of a loop.”
Method(2002) · doi:10.5555/762761.762822 · Cited by 115
Performance Optimizations and Bounds for Sparse Matrix-Vector Multiply
Vuduc, R., Demmel, J. W., Yelick, K. A., Kamil, S., Nishtala, R., & Lee, B. (2002) · ACM/IEEE SC 2002 Conference (SC'02) · doi:10.1109/sc.2002.10025 · Cited by 66
“A variety of sophisticated static models have been developed, each with the goal of providing a compiler with sufficiently precise models for selecting memory hierarchy transformations and parameters such as tile sizes [8, 11, 22, 7, 32].”
Background
Metadata
- Authors
- Chatterjee, S., Parker, E., Hanlon, P. J., & Lebeck, A. R.
- Venue
- Proceedings of the ACM SIGPLAN 2001 conference on Programming language design and implementation
- Publisher
- ACM
- Published
- 2001-05
- Pages
- 286-297
- ISSN
- 1531-7102 (ISSN-L)
- OpenAlex
- W2065705265
- Cited by
- 163
- References
- 41
- FWCI
- 11.28
- Type
- conference paper
- Language
- en
- Open access
- closed
About these checks
Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.
Statistics and arithmetic are recomputed, not judged.
Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.
What counts as a claim ›How we measure confidence ›How we check this ›
Are you an author, or do you see a problem with this page? Request a review
Data sources
Bibliographic data: Semantic Scholar, OpenAlex, Crossref.
Contains information from the Semantic Scholar Academic Graph Datasets, made available under the ODC Attribution License (ODC-BY 1.0).
Semantic Scholar’s data is described in: Kinney, R., et al. (2023). The Semantic Scholar Open Data Platform. arXiv:2301.10140.