mshah.ioCourse ScheduleCourse Information


Module 13 - Locality and the Cache (Zhong) - 2025-Oct-06

Overview

In this module we learn about the importance of undersetanding hardware for performance.

  • Locality
  • Caches

Slides and Class Content

Please note: Your in-class activity is graded. Your first attempt will be graded. You can use your notes and slides if you like. You have 1 week from the date of this module opening to complete the in-class activity. In-class activities are completed individually.

Audio/Video Recording

Note: Audio/Video recordings are made in a best effort in case you have to miss class or you would otherwise like to re-watch a portion of lecture. Occassional recording errors (e.g. missing sound, corrupted video, etc.) may occur, and I apologize in advance if a recording is not able to be made available.

Readings

    Please use the following resources to supplement this lecture. You may choose to read 1 or more of these before/during/after the lecture to fully immerse into the material.

  1. Local (arena) Memory Allocators - John Lakos [ACCU 2017]
    • Video on memory allocators with some segments explaining basics of caching
  2. code::dive conference 2014 - Scott Meyers: Cpu Caches and Why You Care]
    • Video on memory allocators with some segments explaining basics of caching
  3. CppCon 2016: Timur Doumler 'Want fast C++? Know your hardware!
    • Video on caching
  4. Caches, Video 6: Code optimization for caches
    • Video on Cache miss analysis
  5. Cache-Oblivious Algorithms and Data Structures
    • Cache Oblvious Algorithms by Erik Demaine
  6. The Working Set Model for Program by Peter J. Denning
    • Paper describing that the amount of resources we need as related to cache in the 'working set'
Please do not redistribute or host any materials without e-mailing me first. Thank you for your time!