Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 13 additions & 9 deletions linpack/linpack_extra/run_linpack.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

TOOLS_BIN="/"
source $TOOLS_BIN/helpers.inc
max_threads=0
threads_to_do=0
iterations=5
Expand All @@ -33,6 +33,8 @@ NUMB_SOCKETS=""
reduce_only=0
test_name="linpack"
test_version="1.0"
start_time=""
end_time=""

out_dir=`pwd`/linpack_results
if [[ -d "$out_dir" ]]; then
Expand Down Expand Up @@ -85,6 +87,10 @@ execute_ht()
socket_mappings=`cat /tmp/socket_mappings`
sockets=1
ht_config="ht_yes_1_socket_hyp"
#
# For now the whole run time will be save in the csv file.
#
start_time=$(retrieve_time_stamp)
for cpu_list in $socket_mappings; do
nh_threads=`grep -o ',' <<<"$cpu_list" | grep -c .`
let "nh_threads=$nh_threads+1"
Expand All @@ -111,6 +117,7 @@ execute_ht()
execute_linpack
fi
done
end_time=$(retrieve_time_stamp)
}

execute_non_ht()
Expand Down Expand Up @@ -173,8 +180,7 @@ process_summary()
iters=0
input="/tmp/linpack_temp"

$TOOLS_BIN/test_header_info --front_matter --results_file results.csv $to_configuration --sys_type $to_sys_type --tuned $to_tuned_setting --results_version $test_version --test_name $test_name
echo ht_config:sockets:threads:unit:"MB/sec:cpu_affin" >> results.csv
$TOOLS_BIN/test_header_info --front_matter --results_file results.csv $to_configuration --sys_type $to_sys_type --tuned $to_tuned_setting --results_version $test_version --test_name $test_name --field_header "ht_config,sockets,threads,unit,MB/sec,cpu_affin,Start_time,End_time"

while IFS= read -r lin_file
do
Expand All @@ -197,7 +203,7 @@ process_summary()
do
if [[ $have_cpus == "0" ]]; then
have_cpus=1
cpu_affin=`echo $data | cut -d' ' -f3`
cpu_affin=`echo $data | cut -d' ' -f3 | sed "s/,/./g"`
fi
if [[ $data == *"Size"* ]]; then
unit=`echo $data | cut -d' ' -f 5`
Expand All @@ -219,7 +225,9 @@ process_summary()
done < "$input1"
if [[ $avg != "" ]]; then
test_results="Ran"
echo $ht_setting:$sockets:$threads:$unit:$avg:$cpu_affin >> results.csv
data_string=$(build_data_string "$ht_setting" "$sockets" "$threads" "$unit" "$avg" "$cpu_affin")

echo "$data_string" >> results.csv
fi
done < "$input"

Expand Down Expand Up @@ -254,7 +262,6 @@ usage()
echo " -i: value: number of iterationsto run"
echo " -n: numactl interleave"
echo " -s: sanity run"
echo " -T: Tools bin to find test_header_info in"
echo " -t: max threads: maximum number of threads"
exit 1
}
Expand Down Expand Up @@ -287,9 +294,6 @@ while getopts "RC:ci:t:h:P:s:u:oS:n:T:" opt; do
R)
reduce_only=1
;;
T)
TOOLS_BIN=${OPTARG}
;;
t)
threads_list=${OPTARG}
;;
Expand Down
45 changes: 38 additions & 7 deletions linpack/linpack_run
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
# This script automates the execution of linpack. It will determine the
# set of default run parameters based on the system configuration.
#

error_exit()
{
echo $1
Expand Down Expand Up @@ -131,6 +132,7 @@ fi

${curdir}/test_tools/gather_data ${curdir}
source test_tools/general_setup "$@"
export TOOLS_BIN

execute_via_shell()
{
Expand All @@ -155,16 +157,16 @@ execute_via_shell()
test_config=`echo "${linpack_ops}" | cut -d':' -f 1`
config="${to_configuration}_${test_config}"
cd $run_dir/${test_name}
echo ./run_linpack.sh -T $TOOLS_BIN -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave
./run_linpack.sh -T $TOOLS_BIN -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave >> $out_file
echo ./run_linpack.sh -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave
./run_linpack.sh -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave >> $out_file
if [ $? -ne 0 ]; then
error_exit "run_linpack.sh failed" 1
fi
done < "$file"
else
cd $run_dir/${test_name}
echo ./run_linpack.sh -T $TOOLS_BIN -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave
./run_linpack.sh -T $TOOLS_BIN -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave >> $out_file
echo ./run_linpack.sh -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave
./run_linpack.sh -u \"$to_user\" -h $to_home_root -C $to_configuration -i $to_times_to_run -P $to_tuned_setting -s $to_sysname -n $interleave >> $out_file
if [ $? -ne 0 ]; then
error_exit "run_linpack.sh failed" 1
fi
Expand Down Expand Up @@ -253,14 +255,43 @@ do
# and log the iteration's result

if [[ $to_use_pcp -eq 1 ]]; then
echo "Send result to PCP archive"
echo ${iteration}
result2pcp iteration_number ${iteration}
linpack_data=`mktemp /tmp/linpack_data.XXXXX`
results2pcp_add_value "iteration:${iteration}"
grep ^ht linpack_results/results.csv | grep -v cpu_affin > $linpack_data
while IFS= read -r line
do
value=`echo $line | cut -d: -f1`
#
# Note: If we ever get to having more then 2 hyperthreads in the future, this
# will need to be updated. For now value of 1 indicates 2 hyperthreads.
#
if [[ $value == *"yes"* ]]; then
results2pcp_add_value "hyper_thread:1"
else
results2pcp_add_value "hyper_thread:0"
fi
value=`echo $line | cut -d, -f2`
results2pcp_add_value "num_sockets:$value"
value=`echo $line | cut -d, -f3`
results2pcp_add_value "numthreads:$value"
value=`echo $line | cut -d, -f5`
results2pcp_add_value "gflops:$value"
#
# Commit the metrics
#
results2pcp_add_value_commit
done < "${linpack_data}"
rm $linpack_data
#
# Reset metrics
#
reset_pcp_om
stop_pcp_subset
fi
done

if [[ $to_use_pcp -eq 1 ]]; then
stop_pcp
shutdown_pcp
fi

Expand Down
9 changes: 9 additions & 0 deletions linpack/openmetrics_linpack_reset.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
iteration 0
running 0
numthreads 0
runtime NaN
throughput NaN
latency NaN
hyper_thread NaN
num_sockets NaN
gflops NaN