Commit f2b5471d authored by Ondrej Vysocky's avatar Ondrej Vysocky
Browse files

ENH default environment source script updated to be more general #11

parent 21972528
#!/bin/bash
# version TAURUS
# bash script to load modules and set environment varibles to run MERIC test
# parametres:
# script for loading default settings for MERIC and to show current settings
# the script must be sourced to be able change the environment
#
# parameters:
# -t = optional, doesn't change the environment only prints a list of MERIC variables, that are set
###############################################################################
# MACHINE DEPENDET SECTION
### MODULES ### TAURUS ###
modules()
{
module purge
module load intel
module load mpirt
module load papi
module load cpufrequtils
}
###############################################################################
# FUNCTIONS
################################################################################
### PRINT LIST OF ENV VARIABLES ###
variables()
......@@ -33,9 +19,9 @@ variables()
done
}
###############################################################################
################################################################################
# test if script is in interactive mode
### TEST IF THE SCRIPT HAS BEEN SOURCED ###
if [[ $- != *i* ]]
then
echo "WARNING: source this script to set environment. List of set variables only."
......@@ -44,29 +30,30 @@ then
exit 1
fi
# test options only
### TEST OPTIONS ONLY ###
if [[ $1 == "-t" ]]
then
variables
return 0
fi
### ENVIRONMENT VARIABLES ###
export MERIC_FREQUENCY=25
export MERIC_UNCORE_FREQUENCY=30
export MERIC_NUM_THREADS=0
export MERIC_COUNTERS=papi #perfevent, papi
export MERIC_MODE=3 #enum {hdeem=0, rapl=1, both=2, run=3, jetson=4, thunder=5}
export MERIC_AGGREGATE=1
export MERIC_CONTINUAL=1
# export MERIC_DETAILED=1
# export MERIC_DEBUG=1
# export MERIC_SAMPLES=1
# export MERIC_BARRIERS=all #all, mpi, omp, none
# export MERIC_OUTPUT_DIR=
# export MERIC_OUTPUT_FILENAME=
################################################################################
### SPECIFY MERIC SETTINGS ###
export MERIC_FREQUENCY=0 # no DVFS
export MERIC_UNCORE_FREQUENCY=0 # no UFS
export MERIC_NUM_THREADS=0 # non-OpenMP application
export MERIC_COUNTERS=papi # perfevent, papi
export MERIC_MODE=3 # {hdeem=0, rapl=1, both=2, run=3, jetson=4, thunder=5, davide=6, time=7}
export MERIC_AGGREGATE=1 # aggregated data from all the nodes
export MERIC_CONTINUAL=1 # energy read at the end of the runtime
# export MERIC_DETAILED=1 # detailed information about the system
# export MERIC_DEBUG=0 # HDEEM debug mode off
# export MERIC_SAMPLES=0 # do not store power samples
# export MERIC_BARRIERS=all # {all, mpi, omp, none}
# export MERIC_OUTPUT_DIR=mericMeasurement
# export MERIC_OUTPUT_FILENAME=log.csv
# export MERIC_REGION_OPTIONS=region.options
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment