In software engineering, when we profile our code, we dynamically analyse it (by running it) by gathering metrics and inferring results from these metrics. For instance, one key use of profiling is to identify which parts of our program consume a large amount of CPU time, so that we can optimise and improve it’s performance.

Why even do this? So that we identify where is the best place to spend our time optimising.

Profiling can take a wide range of analytics, including time metrics (runtime, latency), space (memory usage, bandwidth), code metrics (loop/recursion depth), and hardware metrics (cache hits/misses, number of interrupts).1

See also

Footnotes

  1. From this blog post by Alex Dzyoba.