55 строки
2.1 KiB
Bash
Исполняемый файл
55 строки
2.1 KiB
Bash
Исполняемый файл
#!/bin/sh
|
|
|
|
################################################################################
|
|
# Copyright (c) 2018 Advanced Micro Devices, Inc. All rights reserved.
|
|
#
|
|
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
# of this software and associated documentation files (the "Software"), to deal
|
|
# in the Software without restriction, including without limitation the rights
|
|
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
# copies of the Software, and to permit persons to whom the Software is
|
|
# furnished to do so, subject to the following conditions:
|
|
#
|
|
# The above copyright notice and this permission notice shall be included in
|
|
# all copies or substantial portions of the Software.
|
|
#
|
|
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
|
# THE SOFTWARE.
|
|
################################################################################
|
|
|
|
# enable tools load failure reporting
|
|
export HSA_TOOLS_REPORT_LOAD_FAILURE=1
|
|
# test trace
|
|
export ROC_TEST_TRACE=1
|
|
|
|
# kernels loading iterations
|
|
export ROCP_KITER=1
|
|
# kernels dispatching iterations per kernel load
|
|
# dispatching to the same queue
|
|
export ROCP_DITER=1
|
|
# GPU agents number
|
|
export ROCP_AGENTS=1
|
|
# host threads number
|
|
# each thread creates a queue pre GPU agent
|
|
export ROCP_THRS=1
|
|
|
|
# paths to ROC profiler and oher libraries
|
|
export LD_LIBRARY_PATH=$PWD
|
|
# ROC profiler library loaded by HSA runtime
|
|
export HSA_TOOLS_LIB="test/libtracer_tool.so libroctracer64.so"
|
|
export LD_PRELOAD="$HSA_TOOLS_LIB"
|
|
|
|
#eval ./test/hsa/ctrl
|
|
HCC_PROFILE=1 LD_PRELOAD=$HCC_HOME/lib/libmcwamp_hsa.so ./test/MatrixTranspose
|
|
|
|
#valgrind --leak-check=full $tbin
|
|
#valgrind --tool=massif $tbin
|
|
#ms_print massif.out.<N>
|
|
|
|
exit 0
|