Created 07/12/23 by A.Kibats Introduction: This README serves as a guide behind the scripts and how to utlise them as well as explain the naming convention of the raw data. If making a directory for the first time use: git clone https://github.com/ukri-netzero-energetic/benchmarks-and-scripts Please follow README in benchmarks-and-scripts/HPC-by-UCL/nextgenio/SGEMM/ to create a working build before utlising the scripts. All the scripts for measuring energy will be located in /benchmarks-and-scripts/measurement_scripts Scripts used: -amdRAPL.sh //is used to monitor CPU energy and outputs the socket energy in the terminal. -sample_amdFPGA_power.sh //is used to monitor the FPGA power at the polling the user inputs and is output to a file that the user names. (requires unique file name) -launchExe_amdRAPL_sample_amdFPGA_power.sh //is used to call both previous scripts at the same time so energy is accurate. -calcEnergy.c //is compiled into a .exe using gcc -O0 calcEnergy.c -o calcEnergy-O0.exe -calcEnergy.exe // Once compiled from calcEnergy.c, this .exe is used on output files from sample_amdFPGA_power.sh, this will calculate total FPGA energy and output to terminal. Set-up and examples of utlisiations: If the scripts have remained in the original directories syntax would be as follows: /[YOUR DIRECTORY TO]/benchmarks-and-scripts/measurement_scripts/launchEXE_amdRAPL_sample_amdFPGA_power.sh [ENTER POLLING IN MS] [ENTER FILE NAME] ./RunHardware.exe [N][K][M] hw [on/off] An example of this that was used for tests would be: /home/nx08/nx08/akibats/benchmarks-and-scripts/measurement_scripts/launchExe_amdRAPL_sample_amdFPGA_power.sh 500 4k_500_L_1.dat ./RunHardware.exe 4096 4096 4096 hw off | tee 4k_500_L_1.out In this case FPGA energy would be measured at every 500ms, output to 4k_500_L_1.dat and all the terminal output would be in 4k_500_L_1.out which includes the CPU energy and Kernal/Runtimes. To get the FPGA energy simply use : /[YOUR DIRECTORY TO]/calcEnergy.exe [FILENAME.dat] To reset the card use xbutil reset --device [Device ID as given by Xbutil examine] Raw data: The naming convention of the raw data is a follows [matrixsize]_[polling rate]_[Reset/Loaded]_[Test#].[dat if FPGA energy][out if terminal output]. So 4k_500_L_1.dat would be 4k matrix, 500ms polling, Loaded bit stream, test #1, FPGA energy.