skip to main content
10.1145/1250662.1250709acmconferencesArticle/Chapter ViewAbstractPublication PagesiscaConference Proceedingsconference-collections
Article

Adaptive insertion policies for high performance caching

Published:09 June 2007Publication History

ABSTRACT

The commonly used LRU replacement policy is susceptible to thrashing for memory-intensive workloads that have a working set greater than the available cache size. For such applications, the majority of lines traverse from the MRU position to the LRU position without receiving any cache hits, resulting in inefficient use of cache space. Cache performance can be improved if some fraction of the working set is retained in the cache so that at least that fraction of the working set can contribute to cache hits.

We show that simple changes to the insertion policy can significantly reduce cache misses for memory-intensive workloads. We propose the LRU Insertion Policy (LIP) which places the incoming line in the LRU position instead of the MRU position. LIP protects the cache from thrashing and results in close to optimal hitrate for applications that have a cyclic reference pattern. We also propose the Bimodal Insertion Policy (BIP) as an enhancement of LIP that adapts to changes in the working set while maintaining the thrashing protection of LIP. We finally propose a Dynamic Insertion Policy (DIP) to choose between BIP and the traditional LRU policy depending on which policy incurs fewer misses. The proposed insertion policies do not require any change to the existing cache structure, are trivial to implement, and have a storage requirement of less than two bytes. We show that DIP reduces the average MPKI of the baseline 1MB 16-way L2 cache by 21%, bridging two-thirds of the gap between LRU and OPT.

References

  1. L. A. Belady. A study of replacement algorithms for a virtual-storage computer. In IBM Systems journal, pages 78--101, 1966.Google ScholarGoogle Scholar
  2. W. fen Lin et al. Reducing dram latencies with an integrated memory hierarchy design. In HPCA-7, pages 301--312, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. A. Gonzalez, C. Aliagas, and M. Valero. A data cache with multiple caching strategies tuned to different types of locality. In ICS-9, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. F. Guo and Y. Solihin. An analytical model for cache replacement policy performance. SIGMETRICS Perform. Eval. Rev., 34(1):228--239, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. E. G. Hallnor and S. K. Reinhardt. A fully associative software-managed cache design. In ISCA-27, 2000. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. T. L. Johnson. Run-time adaptive cache management. PhD thesis, University of Illinois, Urbana, IL, May 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. S. Kaxiras et al. Cache decay: exploiting generational behavior to reduce cache leakage power. In ISCA-28, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. A. Lai, C. Fide, and B. Falsafi. Dead-block prediction & dead-block correlating prefetchers. In ISCA-28, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. W. Lin and S. Reinhardt. Predicting last-touch references under optimal replacement. In Technical Report CSE-TR-447-02, University of Michigan, 2002.Google ScholarGoogle Scholar
  10. S. McFarling. Cache replacement with dynamic exclusion. In ISCA-19, pages 191--200, 1992. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. N. Megiddo and D. S. Modha. ARC: A self-tuning, low overhead replacement cache. In Proceeding of the 2nd USENIX Conference on File and Storage Technologies, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. E. Perelman et al. Using simpoint for accurate and efficient simulation. SIGMETRICS Perform. Eval. Rev., 31(1):318--319, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. M. K. Qureshi, D. N. Lynch, O. Mutlu, and Y. N. Patt. A case for MLP-aware cache replacement. In ISCA-33, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. M. K. Qureshi, D. Thompson, and Y. N. Patt. The V-Way Cache: Demand Based Associativity via Global Replacement. In ISCA-32, pages 544--555, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. J. T. Robinson and M. V. Devarakonda. Data cache management using frequency-based replacement. In SIGMETRICS '90, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. S. Ross. A First Course in Probability. Pearson Prentice Hall, 2006.Google ScholarGoogle Scholar
  17. Y. Smaragdakis et al. The EELRU adaptive replacement algorithm. Performance Evaluation, 53(2):93--123, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. R. Subramanian et al. Adaptive caches: Effective shaping of cache behavior to workloads. In MICRO-39, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. G. Tyson, M. Farrens, J. Matthews, and A. R. Pleszkun. A modified approach to data cache management. In MICRO-28, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Z. Wang et al. Using the compiler to improve cache replacement decisions. In PACT, page 199, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. W. A. Wong and J.-L. Baer. Modified LRU policies for improving second-level cache behavior. In HPCA-6, 2000.Google ScholarGoogle Scholar

Index Terms

  1. Adaptive insertion policies for high performance caching

    Recommendations

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in
    • Published in

      cover image ACM Conferences
      ISCA '07: Proceedings of the 34th annual international symposium on Computer architecture
      June 2007
      542 pages
      ISBN:9781595937063
      DOI:10.1145/1250662
      • General Chair:
      • Dean Tullsen,
      • Program Chair:
      • Brad Calder
      • cover image ACM SIGARCH Computer Architecture News
        ACM SIGARCH Computer Architecture News  Volume 35, Issue 2
        May 2007
        527 pages
        ISSN:0163-5964
        DOI:10.1145/1273440
        Issue’s Table of Contents

      Copyright © 2007 ACM

      Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

      Publisher

      Association for Computing Machinery

      New York, NY, United States

      Publication History

      • Published: 9 June 2007

      Permissions

      Request permissions about this article.

      Request Permissions

      Check for updates

      Qualifiers

      • Article

      Acceptance Rates

      Overall Acceptance Rate543of3,203submissions,17%

      Upcoming Conference

      ISCA '24

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader