Skip to content

Commit

Permalink
Robustify parse_LLNL.sh script a bit
Browse files Browse the repository at this point in the history
This patch adds some error checking to the parse_LLNL.sh script, and
avoids parsing `ls` output when looking for the results file.
  • Loading branch information
jtb20 committed Jun 21, 2024
1 parent 754539b commit f48ea60
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions bin/rocm-test/scripts/parse_LLNL.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,14 @@ testname_regex='.*(test_\S*)'
compile_regex='Compilation.*failed'
runtime_regex='Running.+\.\.\.\s+([A-Z]*[a-z]*)'

cd "$aompdir/test/LLNL/openmp5.0-tests"
infile=`ls | grep "LLNL.run.log"`
cd "$aompdir/test/LLNL/openmp5.0-tests" || exit 1
declare -a infiles
infiles=( LLNL.run.log* )
if [ "${#infiles[@]}" -ne 1 ]; then
echo "Expected to find a single result file, bailing out" >&2
exit 1
fi
infile=${infiles[0]}

# Clean up before parsing
if [ -e passing-tests.txt ]; then
Expand Down

0 comments on commit f48ea60

Please sign in to comment.