Dosyalar
rocm-systems/bin/hipexamine2.sh
T
Evgeny Mankov bcbbc32fa6 [HIPIFY] Add hipconvertinplace2.sh and hipexamine2.sh scripts for hipify-clang.
The differences from the similar scripts for hipify.pl:
1. CSV file with extended statistics is produced.
2. scripts' arguments are changed a bit:
DIRNAME [hipify options] [--] [clang options]

where -- is a delimiter; all the arguments are optional, except DIRNAME.

Usage example:
./hipexamine2.sh ./tmp -o-stats ./tmp/stats.csv -- -I/usr/local/cuda-7.5/include -I/usr/local/hipify-clang/hipblas/include 2>&1 | tee log
2016-12-23 22:06:20 +03:00

23 satır
486 B
Bash

#!/bin/bash
#usage : hipexamine2.sh DIRNAME [hipify options] [--] [clang options]
# Generate CUDA->HIP conversion statistics for all the code files in the specified directory.
SCRIPT_DIR=`dirname $0`
SEARCH_DIR=$1
hipify_args=''
while (( "$#" )); do
shift
if [ "$1" != "--" ]; then
hipify_args="$hipify_args $1"
else
shift
break
fi
done
clang_args="$@"
$SCRIPT_DIR/hipify-clang -examine $hipify_args `$SCRIPT_DIR/findcode.sh $SEARCH_DIR` -- -x cuda $clang_args