From ec0512af6bbb8ba05eb13fc1aac7754283dd13aa Mon Sep 17 00:00:00 2001 From: Joshua Bakita Date: Tue, 20 Oct 2020 18:20:39 -0400 Subject: Unify unpaired timing scripts for DIS, TACLe, and SD-VBS Now supports specifying an input generation command for each benchmark - see dis/dis2MbInNames.txt for an example. --- dis/bin/field_2mb | 2 - dis/bin/matrix_2mb | 2 - dis/bin/neighborhood_2mb | 2 - dis/bin/pointer_2mb | 2 - dis/bin/transitive_2mb | 2 - dis/bin/update_2mb | 2 - dis/dis2MbInNames.txt | 6 ++ dis/run_dis.sh | 92 ------------------------ run_all_dis.sh | 70 ------------------ run_bench.sh | 181 ++++++++++++++++++++++++++++++++++++----------- run_dis_cache_vs_wss.sh | 69 ++++++++++++++++++ run_tacle_all.sh | 49 +++++++++++++ run_tacle_rtss20.sh | 48 ------------- 13 files changed, 262 insertions(+), 265 deletions(-) delete mode 100755 dis/bin/field_2mb delete mode 100755 dis/bin/matrix_2mb delete mode 100755 dis/bin/neighborhood_2mb delete mode 100755 dis/bin/pointer_2mb delete mode 100755 dis/bin/transitive_2mb delete mode 100755 dis/bin/update_2mb create mode 100644 dis/dis2MbInNames.txt delete mode 100755 dis/run_dis.sh delete mode 100755 run_all_dis.sh create mode 100755 run_dis_cache_vs_wss.sh create mode 100755 run_tacle_all.sh delete mode 100755 run_tacle_rtss20.sh diff --git a/dis/bin/field_2mb b/dis/bin/field_2mb deleted file mode 100755 index 31f2a8d..0000000 --- a/dis/bin/field_2mb +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -taskset -c 0 ./gen_input.py field inputs/Field/in0 2097152 | ./field $@ diff --git a/dis/bin/matrix_2mb b/dis/bin/matrix_2mb deleted file mode 100755 index 72710ab..0000000 --- a/dis/bin/matrix_2mb +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -taskset -c 0 ./gen_input.py matrix inputs/Matrix/in4 2097152 | ./matrix $@ > /dev/null diff --git a/dis/bin/neighborhood_2mb b/dis/bin/neighborhood_2mb deleted file mode 100755 index 226bd98..0000000 --- a/dis/bin/neighborhood_2mb +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -taskset -c 0 ./gen_input.py neighborhood inputs/Neighborhood/in0 2097152 | ./neighborhood $@ > /dev/null diff --git a/dis/bin/pointer_2mb b/dis/bin/pointer_2mb deleted file mode 100755 index 3ce8f2b..0000000 --- a/dis/bin/pointer_2mb +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -taskset -c 0 ./gen_input.py pointer inputs/Pointer/in0 2097152 | ./pointer $@ diff --git a/dis/bin/transitive_2mb b/dis/bin/transitive_2mb deleted file mode 100755 index b8bcf5a..0000000 --- a/dis/bin/transitive_2mb +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -taskset -c 0 ./gen_input.py transitive inputs/Transitive/in0 2097152 | ./transitive $@ diff --git a/dis/bin/update_2mb b/dis/bin/update_2mb deleted file mode 100755 index 3bc33f4..0000000 --- a/dis/bin/update_2mb +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/bash -taskset -c 0 ./gen_input.py update inputs/Update/in0 2097152 | ./update $@ diff --git a/dis/dis2MbInNames.txt b/dis/dis2MbInNames.txt new file mode 100644 index 0000000..00e6a22 --- /dev/null +++ b/dis/dis2MbInNames.txt @@ -0,0 +1,6 @@ +field ./gen_input.py field inputs/Field/in0 2097152 +matrix ./gen_input.py matrix inputs/Matrix/in0 2097152 +neighborhood ./gen_input.py neighborhood inputs/Neighborhood/in0 2097152 +pointer ./gen_input.py pointer inputs/Pointer/in0 2097152 +transitive ./gen_input.py transitive inputs/Transitive/in0 2097152 +update ./gen_input.py update inputs/Update/in0 2097152 diff --git a/dis/run_dis.sh b/dis/run_dis.sh deleted file mode 100755 index 78745ec..0000000 --- a/dis/run_dis.sh +++ /dev/null @@ -1,92 +0,0 @@ -#!/bin/bash - -core=$1 -maxJobs=$2 -runID=$3 -benchmark=${4,} -template_input=inputs/$4/in0 -wss_settings=inputs/WSSS -cache_settings=inputs/caches - -if [ $# -lt 4 ]; then - echo "Usage $0 [template input] [DIS WSS file] [DIS cache file]" - exit -fi - -if [ $# -gt 4 ]; then - echo "Using alternate input template from $5" - template_input=$5 -fi - -if [ $# -gt 5 ]; then - echo "Using alternate WSS settings from $6" - wss_settings=$6 -fi - -if [ $# -gt 6 ]; then - echo "Using alternate cache settings from $7" - cache_settings=$7 -fi - -echo "Making sure that binary is up to date..." -make $benchmark -echo "Done. Disabling real-time throttling..." - -# Turn off rt throttling -echo -1 > /proc/sys/kernel/sched_rt_runtime_us -echo "Done. Redirecting all interrupts to core 0..." - -# Redirect all interrupts to core 0 -i=0 -for IRQ in /proc/irq/* -do - # Skip default_smp_affinity - if [ -d $IRQ ]; then - irqList[$i]=$(cat $IRQ/smp_affinity_list) - echo 0 2> /dev/null > $IRQ/smp_affinity_list - fi - i=$(( $i + 1 )) -done - -echo "Done. Checking for wbinvd module..." -if [[ ! -f "/proc/wbinvd" ]]; then - echo "ERROR: wbinvd module not loaded. Exiting..." - exit -fi - -# Enable L3 isolation -echo "Done. Enabling L3 isolation..." -mount -t resctrl resctrl /sys/fs/resctrl -mkdir -p /sys/fs/resctrl/benchmarks -echo $1 > /sys/fs/resctrl/benchmarks/cpus_list -# Reset global bandwith control and remove L3 from global -echo "L3:0=ffff;1=ffff;2=ffff;3=0000" > /sys/fs/resctrl/schemata -echo "MB:0=2048;1=2048;2=2048;3=2048" > /sys/fs/resctrl/schemata -# Alloc L3 to benchmark -echo "L3:0=0000;1=0000;2=0000;3=ffff" > /sys/fs/resctrl/benchmarks/schemata -echo "MB:0=2048;1=2048;2=2048;3=2048" > /sys/fs/resctrl/benchmarks/schemata -echo "Done. Beginning benchmarks..." - -# Execute the benchmark for each WSS and cache config -while read j; do - echo $j > /sys/fs/resctrl/benchmarks/schemata - while read i; do - if grep -q "#define LITMUS 1" ../baseline/source/extra.h; then - echo "Using LITMUS-RT!" - ./gen_input.py $benchmark $template_input $i | numactl -m 0 ./$benchmark $benchmark-$i-$j $maxJobs $core $runID 1 - else - ./gen_input.py $benchmark $template_input $i | chrt -r 97 numactl -m 0 taskset -c $core ./$benchmark $benchmark-$i-$j $maxJobs $core $runID 1 - fi - done < $wss_settings -done < $cache_settings - -# Put IRQs back as they were -i=0 -for IRQ in /proc/irq/* -do - if [ -d $IRQ ]; then - echo ${irqList[$i]} 2> /dev/null > $IRQ/smp_affinity_list - fi - i=$(( $i + 1 )) -done - diff --git a/run_all_dis.sh b/run_all_dis.sh deleted file mode 100755 index 5a6b6e1..0000000 --- a/run_all_dis.sh +++ /dev/null @@ -1,70 +0,0 @@ -#!/bin/bash -# Run baselines for all the DIS tasks -if [ "$EUID" -ne 0 ] -then - echo "You need to be root to enable cache way and interrupt isolation!" - exit -fi - -if uname -a | grep -q "mc2"; then - echo "MC^2 detected! Cache isolation will be enabled" - iso="i" -else - echo "MC^2 not detected." - iso="xi" -fi - -datestring=$(date +"%b%d-%H") -if ! grep -q irqaffinity /proc/cmdline; then - /playpen/move_interrupts_off_core15.sh -else - echo "performance" > /sys/devices/system/cpu/cpu15/cpufreq/scaling_governor -fi -WSSS=WSSS_maxstride2mb -caches=caches_all -# Consider re-enabling this only if you're interested in exploring bandwidth effects -#./setup_mem_and_global.sh -if [[ $1 == "--contend" ]]; then - echo "Will run 6 contending tasks" - echo "Files will be named $datestring--c-"$iso".txt" - echo "Please verify the above settings. Press enter to continue..." - read - # Run two contending tasks on each other CCX - taskset -c 1 /playpen/mc2/imx6q-thrasher/thrasher & - taskset -c 2 /playpen/mc2/imx6q-thrasher/thrasher & - taskset -c 5 /playpen/mc2/imx6q-thrasher/thrasher & - taskset -c 6 /playpen/mc2/imx6q-thrasher/thrasher & - taskset -c 9 /playpen/mc2/imx6q-thrasher/thrasher & - taskset -c 10 /playpen/mc2/imx6q-thrasher/thrasher & - ./run_dis.sh 15 10 $datestring-field-c-$iso Field inputs/Field/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-field-c-$iso - ./run_dis.sh 15 10 $datestring-matrix-c-$iso Matrix inputs/Matrix/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-matrix-c-$iso - ./run_dis.sh 15 10 $datestring-neighborhood-c-$iso Neighborhood inputs/Neighborhood/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-neighborhood-c-$iso - ./run_dis.sh 15 10 $datestring-pointer-c-$iso Pointer inputs/Pointer/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-pointer-c-$iso - ./run_dis.sh 15 10 $datestring-transitive-c-$iso Transitive inputs/Transitive/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-transitive-c-$iso - ./run_dis.sh 15 10 $datestring-update-c-$iso Update inputs/Update/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-update-c-$iso - killall thrasher -else - echo "Will run no contending tasks (use --contend for contending tasks)" - echo "Files will be named $datestring--xc-"$iso".txt" - echo "Please verify the above settings. Press enter to continue..." - read - killall thrasher - ./run_dis.sh 15 10 $datestring-field-xc-$iso Field inputs/Field/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-field-xc-$iso - ./run_dis.sh 15 10 $datestring-matrix-xc-$iso Matrix inputs/Matrix/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-matrix-xc-$iso - ./run_dis.sh 15 10 $datestring-neighborhood-xc-$iso Neighborhood inputs/Neighborhood/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-neighborhood-xc-$iso - ./run_dis.sh 15 10 $datestring-pointer-xc-$iso Pointer inputs/Pointer/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-pointer-xc-$iso - ./run_dis.sh 15 10 $datestring-transitive-xc-$iso Transitive inputs/Transitive/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-transitive-xc-$iso - ./run_dis.sh 15 10 $datestring-update-xc-$iso Update inputs/Update/in0 inputs/$WSSS inputs/$caches - ./postproc.sh $datestring-update-xc-$iso -fi diff --git a/run_bench.sh b/run_bench.sh index c5b67b6..4e09faa 100755 --- a/run_bench.sh +++ b/run_bench.sh @@ -1,30 +1,110 @@ #!/bin/bash -core=$1 -maxJobs=$2 -userRunID=$3 -tacleNames=tacleNames.txt +if [ $# -lt 5 ]; then + echo "Usage $0 -m MODE -p CPU -l LOOPS -b FILE [-c] RUN_ID" + echo " -m base|dis Which benchmarking mode to use" + echo " -p CPU Which CPU to run each benchmark on" + echo " -l LOOPS How many loops of each benchmark to do" + echo " -b FILE List of benchmarks to execute. Optional tab-" + echo " delimited 2nd column specifies an input" + echo " generation command (fed to bench via stdin)" + echo " -B Enable background contenders on other CCXes" + echo "Mode base requires no additional options." + echo "Mode dis does not support the 2nd col. of -b and needs:" + echo " -W FILE List of working set sizes to pass gen_input.py" + echo " -T FILE Input template to pass to gen_input.py" + echo " -C FILE List of cache configurations to test" + exit +fi -if [ $# -lt 3 ]; then - echo "Usage $0 [TACLe names file] [--contend]" +# Name options similarly to rtspin +while getopts “m:p:l:b:BW:T:C:” opt; do + case $opt in +# Required + m) mode=$OPTARG ;; + p) core=$OPTARG ;; + l) maxJobs=$OPTARG ;; + b) benchNames=$OPTARG ;; +# Optional + B) contend=1 ;; + W) wss_settings=$OPTARG ;; + T) template_input=$OPTARG ;; + C) cache_settings=$OPTARG ;; + esac +done +# Reset to read operands +shift $((OPTIND -1)) +userRunID=$1 + +# Required argument checking +if [[ "$mode" != "base" ]] && [[ "$mode" != "dis" ]]; then + echo "Invalid argument: MODE must be either 'base' or 'dis'" + exit +fi +if [[ ! -v core ]] || [[ ! -v maxJobs ]] || [[ ! -v benchNames ]]; then + echo "Missing argument: -p, -l, and -b are required" + exit +fi +if [[ ! -f "$benchNames" ]]; then + echo "Invalid argument: $benchNames des not exist" + exit +fi +if [[ ! -v userRunID ]]; then + echo "Missing argument: RUN_ID is required" exit fi -if [ $# -gt 3 ]; then - echo "Using alternate list of TACLe benchmarks from $4" - tacleNames=$4 +# DIS argument checking +if [[ "$mode" == "dis" ]] && [[ ! -v wss_settings || ! -v template_input || -z $cache_settings ]]; then + echo "Missing argument: DIS needs -W FILE -T FILE and -C FILE" + exit +fi +if [[ "$mode" == "dis" ]] && [[ ! -f "$wss_settings" ]]; then + echo "Invalid argument: $wss_settings does not exist" + exit +fi +if [[ "$mode" == "dis" ]] && [[ ! -f "$template_input" ]]; then + echo "Invalid argument: $template_input does not exist" + exit +fi +if [[ "$mode" == "dis" ]] && [[ ! -f "$cache_settings" ]]; then + echo "Invalid argument: $cache_settings does not exist" + exit fi +# Check permissions and update state if [ "$EUID" -ne 0 ] then echo "You need to be root to enable interrupt isolation and real-time execution!" exit fi -echo "Making sure that binaries are up to date..." +echo "Done. Loading benchmark names and input..." + +# Read the names of each benchmark and load input. +# This might look a bit scary, but all it does is +# separate the two fields (1 or more tabs in-between), +# save the benchmark name, and execute the input +# command (storing its output in-memory for later). +j=0 +IFS=$'\r\n' while read i; do - make bin/$i -done < $tacleNames + bench[$j]=$(echo $i | tr -s "\t" | cut -f1) + input[$j]=$(eval $(echo $i | tr -s "\t" | cut -s -f2)) + j=$(( $j + 1 )) +done < $benchNames +echo "Making sure that binaries are up to date..." + +for b in ${bench[@]}; do + make bin/$b + if [[ $? ]]; then + make $b + fi + if [[ ! -f $b && ! -f "./bin/$b" ]]; then + echo "Unable to find benchmark $b" + exit + fi +done echo "Done. Disabling real-time throttling..." # Turn off rt throttling @@ -43,28 +123,20 @@ do i=$(( $i + 1 )) done -# Read the names of each benchmark -j=0 -while read i; do - tacleProg[$j]=$i - j=$(( $j + 1 )) -done < $tacleNames - echo "Done. Checking for wbinvd module..." if [[ ! -f "/proc/wbinvd" ]]; then echo "ERROR: wbinvd module not loaded. Exiting..." exit fi -echo "Done. Setting cores $firstCore and $secondCore to 'performance'..." -echo "performance" > /sys/devices/system/cpu/cpu15/cpufreq/scaling_governor -echo "performance" > /sys/devices/system/cpu/cpu31/cpufreq/scaling_governo +echo "Done. Setting core $core to 'performance'..." +echo "performance" > /sys/devices/system/cpu/cpu$core/cpufreq/scaling_governor # Enable L3 isolation echo "Done. Enabling L3 isolation..." mount -t resctrl resctrl /sys/fs/resctrl mkdir -p /sys/fs/resctrl/benchmarks -echo $1 > /sys/fs/resctrl/benchmarks/cpus_list +echo $core > /sys/fs/resctrl/benchmarks/cpus_list # Reset global bandwith control and remove L3 from global echo "L3:0=ffff;1=ffff;2=ffff;3=0000" > /sys/fs/resctrl/schemata echo "MB:0=2048;1=2048;2=2048;3=2048" > /sys/fs/resctrl/schemata @@ -80,9 +152,9 @@ runID=$(date +"%b%d-%H") # Confirm configuration with user echo "=== Global Config ===" cat /sys/fs/resctrl/schemata -echo "=== Core $1 Config ===" +echo "=== Core $core Config ===" cat /sys/fs/resctrl/benchmarks/schemata -if [[ $5 == "--contend" ]]; then +if [[ -v contend ]]; then if [[ ! -f "/playpen/mc2/imx6q-thrasher/thrasher" ]]; then echo "ERROR: thrasher binary not fonud. Exiting..." exit @@ -99,15 +171,12 @@ else echo "MC^2 not detected." runID=$runID-xi fi -if pwd | grep -qi dis; then - echo "Autodetected DIS. Will use script-level looping." -fi echo "Results will be saved as $runID-$userRunID.txt" echo "Press enter to confirm environment, Ctrl-C to exit..." read # Start contending tasks -if [[ $5 == "--contend" ]]; then +if [[ -v contend ]]; then echo "Done. Starting 6 contending tasks..." # Run two contending tasks on each other CCX taskset -c 1 /playpen/mc2/imx6q-thrasher/thrasher & @@ -120,27 +189,53 @@ fi sleep 1 # Wait for contending tasks to start echo "Done. Beginning benchmarks..." -num_tests=$(wc -l < $tacleNames) -for (( i = 0; i < $num_tests ; i++ )) -do - # If using DIS, we have to iterate in the script as DIS won't do it for us - pwd | grep -qi dis - iters=$(python3 -c "print(int(not "$?")*("$maxJobs"-1))") - for ((k=0;k<=iters;k++)); do +# Output coloring +FAIL_COLOR="\033[0;31m" +GOOD_COLOR="\033[0;32m" +RESET_COLOR="\033[0m" + +num_tests=$(wc -l < $benchNames) +# For each benchmark +for (( i = 0; i < $num_tests ; i++ )); do + if [[ -f ${bench[$i]} ]]; then + binary="${bench[$i]}" + else + binary="./bin/${bench[$i]}" + fi + if [[ "$mode" == "base" ]]; then + # Just run the benchmark if TACLeBench # Check if we're using LITMUS^RT or not - if [[ -f source/extra.h ]] && grep -q "#define LITMUS 1" source/extra.h; then - ./bin/${tacleProg[$i]} ${tacleProg[$i]} $maxJobs $core $runID-$userRunID 1 + if grep -q "#define LITMUS 1" ../extra.h; then + echo "Using LITMUS-RT!" + echo "${input[$i]}" | numactl -m 0 ./bin/$binary ${bench[$i]} $maxJobs $core $runID-$userRunID 1 else # Interleave memory allocations between all nodes (only 1 node w/out MC^2) - chrt -r 97 numactl --interleave=all taskset -c $core ./bin/${tacleProg[$i]} ${tacleProg[$i]} $maxJobs $core $runID-$userRunID 1 -#chrt -r 97 numactl -m 0 taskset -c $core ./bin/${tacleProg[$i]} ${tacleProg[$i]} $maxJobs $core $runID-$userRunID-NOINTERLEAVE 1 + # (this is right because we're testing a task w/out SMT, so it gets both colors) + echo "${input[$i]}" | chrt -r 97 numactl --interleave=all taskset -c $core ./$binary ${bench[$i]} $maxJobs $core $runID-$userRunID 1 fi - done - echo COMPLETE: ${tacleProg[$i]} + elif [[ "$mode" == "dis" ]]; then + # Loop through each WSS and cache config if DIS + while read j; do # For cache setting + echo $j > /sys/fs/resctrl/benchmarks/schemata + while read ii; do # For WSS setting + if grep -q "#define LITMUS 1" ../extra.h; then + echo "Using LITMUS-RT!" + ./gen_input.py ${bench[$i]} inputs/${bench[$i]^}/$template_input $ii | numactl -m 0 ./$binary $bench[$i]}-$ii-$j $maxJobs $core $runID 1 + else + ./gen_input.py ${bench[$i]} $template_input $ii | chrt -r 97 numactl -m 0 taskset -c $core ./$binary ${bench[$i]}-$ii-$j $maxJobs $core $runID 1 + fi + done < $wss_settings + done < $cache_settings + fi + if [[ $? != 0 ]]; then + echo -e ${FAIL_COLOR}FAILED${RESET_COLOR}: ${bench[$i]} + else + echo -e ${GOOD_COLOR}COMPLETE${RESET_COLOR}: ${bench[$i]} + fi done # End contending tasks -if [[ $5 == "--contend" ]]; then +if [[ -v contend ]]; then killall thrasher fi diff --git a/run_dis_cache_vs_wss.sh b/run_dis_cache_vs_wss.sh new file mode 100755 index 0000000..46a12ff --- /dev/null +++ b/run_dis_cache_vs_wss.sh @@ -0,0 +1,69 @@ +#!/bin/bash +# Run baselines for all the DIS tasks +if [ "$EUID" -ne 0 ] +then + echo "You need to be root to enable cache way and interrupt isolation!" + exit +fi + +if uname -a | grep -q "mc2"; then + echo "MC^2 detected! Cache isolation will be enabled" + iso="i" +else + echo "MC^2 not detected." + iso="xi" +fi + +cd dis + +WSSS=WSSS_maxstride2mb +caches=caches_all +# Consider re-enabling this only if you're interested in exploring bandwidth effects +#./setup_mem_and_global.sh +if [[ $1 == "--contend" ]]; then + echo "Will run 6 contending tasks" + echo "Files will be named $datestring--10-c-"$iso".txt" + echo "Please verify the above settings. Press enter to continue..." + read + echo "field" > /tmp/disNames.txt + ../run_bench.sh -p 15 -B -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 field-10 + ./postproc.sh $datestring-field-10-c-$iso + echo "matrix" > /tmp/disNames.txt + ../run_bench.sh -p 15 -B -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 matrix-10 + ./postproc.sh $datestring-matrix-10-c-$iso + echo "neighborhood" > /tmp/disNames.txt + ../run_bench.sh -p 15 -B -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 neighborhood-10 + ./postproc.sh $datestring-neighborhood-10-c-$iso + echo "pointer" > /tmp/disNames.txt + ../run_bench.sh -p 15 -B -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 pointer-10 + ./postproc.sh $datestring-pointer-10-c-$iso + echo "transitive" > /tmp/disNames.txt + ../run_bench.sh -p 15 -B -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 transitive-10 + ./postproc.sh $datestring-transitive-10-c-$iso + echo "update" > /tmp/disNames.txt + ../run_bench.sh -p 15 -B -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 update-10 + ./postproc.sh $datestring-update-10-c-$iso +else + echo "Will run no contending tasks (use --contend for contending tasks)" + echo "Files will be named $datestring--10-xc-"$iso".txt" + echo "Please verify the above settings. Press enter to continue..." + read + echo "field" > /tmp/disNames.txt + ../run_bench.sh -p 15 -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 field-10 + ./postproc.sh $datestring-field-10-xc-$iso + echo "matrix" > /tmp/disNames.txt + ../run_bench.sh -p 15 -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 matrix-10 + ./postproc.sh $datestring-matrix-10-xc-$iso + echo "neighborhood" > /tmp/disNames.txt + ../run_bench.sh -p 15 -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 neighborhood-10 + ./postproc.sh $datestring-neighborhood-10-xc-$iso + echo "pointer" > /tmp/disNames.txt + ../run_bench.sh -p 15 -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 pointer-10 + ./postproc.sh $datestring-pointer-10-xc-$iso + echo "transitive" > /tmp/disNames.txt + ../run_bench.sh -p 15 -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 transitive-10 + ./postproc.sh $datestring-transitive-10-xc-$iso + echo "update" > /tmp/disNames.txt + ../run_bench.sh -p 15 -l 10 -b /tmp/disNames.txt -W WSSS -C caches -T in0 update-10 + ./postproc.sh $datestring-update-10-xc-$iso +fi diff --git a/run_tacle_all.sh b/run_tacle_all.sh new file mode 100755 index 0000000..dd5a443 --- /dev/null +++ b/run_tacle_all.sh @@ -0,0 +1,49 @@ +#!/bin/bash +# Copyright 2020 Joshua Bakita +# This script runs the baselines and Level-A/B and Level-C all_pairs +# for TACLe w/out MC^2 + +if uname -a | grep -q mc2; then + echo "You need to run this without MC^2!" + exit +fi + +if [ "$EUID" -ne 0 ]; then + echo "You need to be root to enable interrupt isolation and real-time execution!" + exit +fi + +echo "This will run the contended and uncontended TACLe baseline, all-pairs, and Level-C micro-benchamarks in non-interactive mode." +echo "Please press enter to confirm (Ctrl-C to abort)..." +read + +echo "performance" > /sys/devices/system/cpu/cpu15/cpufreq/scaling_governor +echo "performance" > /sys/devices/system/cpu/cpu31/cpufreq/scaling_governor + +cd baseline +baseNo=baseline/$(date +"%b%d-%H")-xc-xi-1k.txt +echo "" | ../run_bench.sh -m base -p 15 -l 1001 -b ../all_pairs/tacleNames.txt 1k +baseYes=baseline/$(date +"%b%d-%H")-c-xi-1k.txt +echo "" | ../run_bench.sh -B -m make -p 15 -l 1001 -b ../all_pairs/tacleNames.txt 1k + +cd ../all_pairs +pairsNo=all_pairs/$(date +"%b%d-%H")-xc-xi-1k +echo "" | ./run_all_pairs.sh 15 31 1001 1k ./tacleNames.txt +pairsYes=all_pairs/$(date +"%b%d-%H")-c-xi-1k +echo "" | ./run_all_pairs.sh 15 31 1001 1k ./tacleNames.txt --contend + +cd ../baseline +echo "" | ../smt_analysis_rtss20/run_all_pairs_Level-C_TACLe.sh 15 31 1001 1k ./tacleNames.txt +cNo=all_pairs/$(date +"%b%d-%H")-xc-xi-1k-LC-TACLe.txt +echo "" | ../smt_analysis_rtss20/run_all_pairs_Level-C_TACLe.sh 15 31 1001 1k ./tacleNames.txt --contend +cYes=all_pairs/$(date +"%b%d-%H")-c-xi-1k-LC-TACLe.txt + +echo "==== DONE ===" +echo "Results are in:" +echo "- "$baseNo +echo "- "$baseYes +echo "- "$pairsNo" (A/B)" +echo "- "$pairsYes" (A/B)" +echo "- "$cNo +echo "- "$cYes + diff --git a/run_tacle_rtss20.sh b/run_tacle_rtss20.sh deleted file mode 100755 index 6770c55..0000000 --- a/run_tacle_rtss20.sh +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/bash -# Copyright 2020 Joshua Bakita -# This script runs the baselines and Level-A/B and Level-C all_pairs for TACLe w/out MC^2 - -if uname -a | grep -q mc2; then - echo "You need to run this without MC^2!" - exit -fi - -if [ "$EUID" -ne 0 ]; then - echo "You need to be root to enable interrupt isolation and real-time execution!" - exit -fi - -echo "This will run the contended and uncontended TACLe baseline, all-pairs, and Level-C micro-benchamarks in non-interactive mode." -echo "Please press enter to confirm (Ctrl-C to abort)..." -read - -echo "performance" > /sys/devices/system/cpu/cpu15/cpufreq/scaling_governor -echo "performance" > /sys/devices/system/cpu/cpu31/cpufreq/scaling_governor - -cd baseline -baseNo=baseline/$(date +"%b%d-%H")-xc-xi-1k.txt -echo "" | ./run_baseline.sh 15 1001 1k ../all_pairs/tacleNames.txt -baseYes=baseline/$(date +"%b%d-%H")-c-xi-1k.txt -echo "" | ./run_baseline.sh 15 1001 1k ../all_pairs/tacleNames.txt --contend - -cd ../all_pairs -pairsNo=all_pairs/$(date +"%b%d-%H")-xc-xi-1k -echo "" | ./run_all_pairs.sh 15 31 1001 1k ./tacleNames.txt -pairsYes=all_pairs/$(date +"%b%d-%H")-c-xi-1k -echo "" | ./run_all_pairs.sh 15 31 1001 1k ./tacleNames.txt --contend - -cd ../baseline -echo "" | ../smt_analysis_rtss20/run_all_pairs_Level-C_TACLe.sh 15 31 1001 1k ./tacleNames.txt -cNo=all_pairs/$(date +"%b%d-%H")-xc-xi-1k-LC-TACLe.txt -echo "" | ../smt_analysis_rtss20/run_all_pairs_Level-C_TACLe.sh 15 31 1001 1k ./tacleNames.txt --contend -cYes=all_pairs/$(date +"%b%d-%H")-c-xi-1k-LC-TACLe.txt - -echo "==== DONE ===" -echo "Results are in:" -echo "- "$baseNo -echo "- "$baseYes -echo "- "$pairsNo" (A/B)" -echo "- "$pairsYes" (A/B)" -echo "- "$cNo -echo "- "$cYes - -- cgit v1.2.2