db-tu-dresden / PCM-Setup-Example

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PCM-Setup-Example

Compile PCM

Build the resources in the thridParty/pcm directory according to the repository's README. Ensure a file named 'libpcm.so' can be found thirdParty/pcm/build/lib. Otherwise, the linker information in the CMakeLists.txt needs to be adjusted.

Compile the PCM-Benchmark

First, make sure that you have cmake 3.10 (or newer) installed on your system and configure the CMakeLists.txt to meet your needs. Check if the right compiler flags are set for your system and don't forget to link the libpcm.so library to your executable (target_link_libraries(<excetutable-name> libpcm.so)).

Execute the below command to initialze cmake.

cmake .

And build your executable. The important linker information (to find pcm) are automatically set by cmake.

cmake --build . --target <executable-name>

The compiled programm can be found in the diectory bin.

Execute the PCM-Benchmark

Before executing the excecutable, make sure execute

sudo modprobe msr

PCM needs to root-access to work properly. So you need to run the exceutable as root.

sudo bin/<executable-name>

About

License:GNU General Public License v3.0


Languages

Language:C++ 94.7%Language:CMake 3.7%Language:Python 1.3%Language:C 0.4%