Fixed NIC performance monitoring test (#189)
---------
Co-authored-by: David Galiffi <David.Galiffi@amd.com>
[ROCm/rocprofiler-systems commit: b98c3c8b86]
Este cometimento está contido em:
cometido por
GitHub
ascendente
6e4ced65b8
cometimento
4c4fc2bebe
@@ -25,7 +25,7 @@ RUN zypper --non-interactive update -y && \
|
||||
zypper --non-interactive install -y -t pattern devel_basis && \
|
||||
zypper --non-interactive install -y binutils-gold chrpath cmake curl dpkg-devel \
|
||||
gcc-c++ git libdrm-devel libnuma-devel openmpi3-devel python3-pip rpm-build \
|
||||
wget && \
|
||||
wget iproute2 && \
|
||||
python3 -m pip install 'cmake==3.21'
|
||||
|
||||
ARG ROCM_VERSION=0.0
|
||||
|
||||
@@ -29,7 +29,7 @@ RUN zypper --non-interactive update -y && \
|
||||
zypper --non-interactive install -y -t pattern devel_basis && \
|
||||
zypper --non-interactive install -y binutils-gold chrpath cmake curl dpkg-devel \
|
||||
gcc-c++ git libnuma-devel openmpi3-devel papi-devel python3-pip \
|
||||
rpm-build vim wget && \
|
||||
rpm-build vim wget iproute2 && \
|
||||
zypper --non-interactive clean --all && \
|
||||
python3 -m pip install 'cmake==3.21' perfetto
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ ENV LIBRARY_PATH ${LIBRARY_PATH}:/opt/amdgpu/lib64
|
||||
RUN yum groupinstall -y "Development Tools" && \
|
||||
yum install -y epel-release && crb enable && \
|
||||
yum install -y --allowerasing chrpath cmake curl dpkg-devel libdrm-devel numactl-devel \
|
||||
openmpi-devel papi-devel python3-pip texinfo wget which zlib-devel && \
|
||||
openmpi-devel papi-devel python3-pip texinfo wget which zlib-devel iproute && \
|
||||
yum clean all && \
|
||||
python3 -m pip install 'cmake==3.21' && \
|
||||
python3 -m pip install 'perfetto'
|
||||
|
||||
@@ -20,7 +20,7 @@ ARG NJOBS="8"
|
||||
RUN yum groupinstall -y "Development Tools" && \
|
||||
yum install -y epel-release && crb enable && \
|
||||
yum install -y --allowerasing chrpath cmake curl dpkg-devel numactl-devel \
|
||||
openmpi-devel papi-devel python3-pip texinfo wget which vim zlib-devel && \
|
||||
openmpi-devel papi-devel python3-pip texinfo wget which vim zlib-devel iproute && \
|
||||
yum clean all && \
|
||||
python3 -m pip install 'cmake==3.21' perfetto
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@ RUN apt-get update && \
|
||||
apt-get install -y apt-utils autoconf autotools-dev bash-completion bison \
|
||||
build-essential chrpath cmake curl flex gettext git-core gnupg2 libnuma1 libopenmpi-dev \
|
||||
libpapi-dev libpfm4-dev librpm-dev libtool libudev1 lsb-release m4 \
|
||||
python3-pip rpm texinfo wget && \
|
||||
python3-pip rpm texinfo wget iproute2 && \
|
||||
OS_VERSION=$(cat /etc/os-release | grep VERSION_ID | sed 's/=/ /'1 | awk '{print $NF}' | sed 's/"//g') && \
|
||||
if [ "${OS_VERSION}" == "24.04" ]; then \
|
||||
python3 -m pip install --break-system-packages 'cmake==3.21'; \
|
||||
|
||||
@@ -28,7 +28,7 @@ RUN apt-get update && \
|
||||
apt-get install -y autoconf autotools-dev bash-completion bison build-essential \
|
||||
bzip2 chrpath cmake curl environment-modules flex gettext git-core gnupg2 gzip \
|
||||
libiberty-dev libpapi-dev libpfm4-dev libtool locales lsb-release m4 \
|
||||
python3-pip texinfo unzip wget vim zip zlib1g-dev && \
|
||||
python3-pip texinfo unzip wget vim zip zlib1g-dev iproute2 && \
|
||||
apt-get autoclean && \
|
||||
if [ "${OS_VERSION}" == "24.04" ]; then \
|
||||
python3 -m pip install --break-system-packages 'cmake==3.21' perfetto \
|
||||
|
||||
Ficheiro executável
+27
@@ -0,0 +1,27 @@
|
||||
#!/usr/bin/env bash
|
||||
# MIT License
|
||||
#
|
||||
# Copyright (c) 2025 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.
|
||||
|
||||
|
||||
# This script gets the name of the default NIC and writes it to standard output.
|
||||
|
||||
ip r | awk '/default/{print $5}'
|
||||
@@ -26,7 +26,14 @@
|
||||
#
|
||||
# -------------------------------------------------------------------------------------- #
|
||||
|
||||
set(_network_interface "lo")
|
||||
# Get the name of the default NIC and write it to _network_interface.
|
||||
execute_process(
|
||||
COMMAND "${CMAKE_SOURCE_DIR}/tests/get_default_nic.sh"
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
OUTPUT_VARIABLE _network_interface)
|
||||
|
||||
message(STATUS "Default network interface is ${_network_interface}")
|
||||
|
||||
set(_nic_perf_environment
|
||||
"${_base_environment}"
|
||||
"ROCPROFSYS_OUTPUT_PATH=${PROJECT_BINARY_DIR}/rocprof-sys-tests-output/nic-performance"
|
||||
@@ -38,18 +45,20 @@ set(_nic_perf_environment
|
||||
"ROCPROFSYS_USE_ROCM=OFF"
|
||||
"ROCPROFSYS_TIMEMORY_COMPONENTS=wall_clock,papi_array,network_stats"
|
||||
"ROCPROFSYS_NETWORK_INTERFACE=${_network_interface}"
|
||||
"ROCPROFSYS_PAPI_EVENTS=net:::${_network_interface}:tx:byte,net:::${_network_interface}:rx:byte,net:::${_network_interface}:rx:packet,net:::${_network_interface}:tx:packet"
|
||||
)
|
||||
"ROCPROFSYS_PAPI_EVENTS=net:::${_network_interface}:tx:byte net:::${_network_interface}:rx:byte net:::${_network_interface}:rx:packet net:::${_network_interface}:tx:packet"
|
||||
"ROCPROFSYS_SAMPLING_DELAY=0.05")
|
||||
|
||||
# Set _download_url to a large file that will give rocprof-sys-sample time to collect NIC
|
||||
# performance data.
|
||||
set(_download_url
|
||||
"https://github.com/ROCm/rocprofiler-systems/releases/download/rocm-6.3.1/rocprofiler-systems-0.1.0-ubuntu-20.04-ROCm-60200-PAPI-OMPT-Python3.sh"
|
||||
"https://github.com/llvm/llvm-project/releases/download/llvmorg-20.1.0/clang+llvm-20.1.0-armv7a-linux-gnueabihf.tar.gz"
|
||||
)
|
||||
|
||||
# Run the NIC performance test
|
||||
add_test(
|
||||
NAME nic-performance
|
||||
COMMAND $<TARGET_FILE:rocprofiler-systems-sample> -- wget --no-check-certificate
|
||||
--quiet ${_download_url} -O /tmp/rocprofiler-systems-install.sh
|
||||
${_download_url} -O /tmp/rocprofiler-systems.test.bin
|
||||
WORKING_DIRECTORY ${PROJECT_BINARY_DIR})
|
||||
|
||||
set_tests_properties(nic-performance PROPERTIES ENVIRONMENT "${_nic_perf_environment}"
|
||||
|
||||
Criar uma nova questão referindo esta
Bloquear um utilizador