Skip to content
This repository has been archived by the owner on Jul 31, 2024. It is now read-only.
Jonathan R. Madsen edited this page Aug 28, 2020 · 4 revisions

Why should I choose timemory instead of X for performance analysis?

Does X have an API? If so, don't think of it as a choice between timemory and X, think of it as timemory being able to provide X in addition to a whole lot of other things. If X is not already provided, create a feature request or a pull request with the implementation.

How do I compare the difference between two runs?

  • If you don't have the first set of results yet, it is often convenient to place them in a known directory, e.g. TIMEMORY_OUTPUT_PATH=baseline
  • Once you have the first set of results, set the environment variable TIMEMORY_INPUT_PATH to the directory containing the results
  • Enable TIMEMORY_TIME_OUTPUT -- this will create another sub-folder with the time-stamp of the run
  • Enable TIMEMORY_DIFF_OUTPUT -- this will instruct timemory to search the input path, load any results found, and compute the difference
  • Run the executable again and when the output is generated, there will be additional outputs reporting the differences.
$ export TIMEMORY_OUTPUT_PATH=baseline
$ ./myexe
$ ls -1 baseline/
wall.txt  
wall.json
wall.jpeg
$ export TIMEMORY_INPUT_PATH=baseline
$ export TIMEMORY_TIME_OUTPUT=ON
$ export TIMEMORY_DIFF_OUTPUT=ON
$ ./myexe
$ ls -1 baseline/
wall.txt  
wall.json 
wall.jpeg
2020-08-27_04.12_PM/
$ ls -1 baseline/2020-08-27_04.12_PM/
wall.txt
wall.json
wall.jpeg
wall.diff.txt
wall.diff.json
wall.diff.jpeg

Wall-clock Baseline Results

baseline/wall.jpeg

Wall-clock Results from 2020-08-27_04.12_PM

baseline/2020-08-27_04.12_PM/wall.jpeg

Wall-clock Difference between Baseline and 2020-08-27_04.12_PM

baseline/2020-08-27_04.13_PM/wall.diff.jpeg

Clone this wiki locally