• 0 Posts
  • 204 Comments
Joined 2 years ago
cake
Cake day: June 22nd, 2023

help-circle

















  • Depends on two things

    1. What performance counters your CPU has.
    2. What you consider to be a memory load.

    Tools like perf on Linux can get you access to your processors performance counters and you’ll be able to see how many “events” occur while a process is running.

    What’s an event? Well they can be configured to monitor all sorts of things in the CPU. Instructions executed, Interrupts, page table misses, and on some loads / stores.

    Memory systems on a CPU aren’t straightforward though. They contain multiple levels of cache, each of which reduces the number of accesses which go to the next layer. So depending on which level you measure, you’ll get different numbers.