https://github.com/platformlab/perfutils
A collection of eclectic tools for measuring performance using the cycle counter and pinning threads.
https://github.com/platformlab/perfutils
Last synced: 7 months ago
JSON representation
A collection of eclectic tools for measuring performance using the cycle counter and pinning threads.
- Host: GitHub
- URL: https://github.com/platformlab/perfutils
- Owner: PlatformLab
- License: other
- Created: 2015-10-16T22:41:27.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2019-04-16T06:02:53.000Z (almost 7 years ago)
- Last Synced: 2023-08-20T10:10:50.796Z (over 2 years ago)
- Language: C++
- Size: 185 KB
- Stars: 32
- Watchers: 12
- Forks: 15
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Peformance Utilities
PerfUtils is a low-overhead library for doing performance analysis of
highly-performant software systems running on x86\_64.
## How to Use It
1. Clone the repository.
git clone https://github.com/PlatformLab/PerfUtils.git
2. Build the library.
pushd PerfUtils
make
popd
3. Instrument your application, including the header files for the utilities you would like to use, with a PerfUtils prefix.
#include "PerfUtils/TimeTrace.h"
using PerfUtils::TimeTrace;
int main(){
TimeTrace::record("Start of execution");
uint64_t sum = 0;
for (int i = 0; i < (1 << 20); i++) {
sum += i;
}
TimeTrace::record("End of a counting loop");
TimeTrace::record("Hello world");
TimeTrace::print();
}
4. Build and link against PerfUtils.
g++ -o Main -Ipath/to/PerfUtils/include -std=c++0x Main.cc -Lpath/to/PerfUtils/lib -lPerfUtils