Skip to content

[amdsmi] set clang++ to default compiler #2495

[amdsmi] set clang++ to default compiler

[amdsmi] set clang++ to default compiler #2495

name: rocprofiler-systems Ubuntu 22.04 (GCC, Python, ROCm)
run-name: ubuntu-jammy
on:
push:
branches:
- develop
paths:
- '.github/workflows/rocprofiler-systems-ubuntu-jammy.yml'
- 'projects/rocprofiler-systems/**'
- '!**/*.md'
- '!**/*.rtf'
- '!**/*.rst'
- '!**/.markdownlint-ci2.yaml'
- '!**/.readthedocs.yaml'
- '!**/.spellcheck.local.yaml'
- '!**/.wordlist.txt'
- '!projects/rocprofiler-systems/docs/**'
- '!projects/rocprofiler-systems/source/docs/**'
- '!projects/rocprofiler-systems/source/python/gui/**'
- '!projects/rocprofiler-systems/docker/**'
- '!projects/rocprofiler-systems/CMakePresets.json'
pull_request:
paths:
- '.github/workflows/rocprofiler-systems-ubuntu-jammy.yml'
- 'projects/rocprofiler-systems/**'
- '!**/*.md'
- '!**/*.rtf'
- '!**/*.rst'
- '!**/.markdownlint-ci2.yaml'
- '!**/.readthedocs.yaml'
- '!**/.spellcheck.local.yaml'
- '!**/.wordlist.txt'
- '!projects/rocprofiler-systems/docs/**'
- '!projects/rocprofiler-systems/source/docs/**'
- '!projects/rocprofiler-systems/source/python/gui/**'
- '!projects/rocprofiler-systems/docker/**'
- '!projects/rocprofiler-systems/CMakePresets.json'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
ROCPROFSYS_CI: ON
ROCPROFSYS_TMPDIR: "%env{PWD}%/testing-tmp"
jobs:
ubuntu-jammy
runs-on: ubuntu-latest

Check failure on line 50 in .github/workflows/rocprofiler-systems-ubuntu-jammy.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/rocprofiler-systems-ubuntu-jammy.yml

Invalid workflow file

You have an error in your yaml syntax on line 50
container:
image: dgaliffiamd/rocprofiler-systems:ci-base-ubuntu-22.04
strategy:
fail-fast: false
matrix:
compiler: ['g++']
rocm: ['ON']
python: ['ON']
strip: ['OFF']
hidden: ['ON']
build-type: ['Release']
mpi-headers: ['OFF']
build-dyninst: ['ON']
rocm-version: ['6.3', '6.4', '7.0', '7.1', '7.2']
env:
OMPI_ALLOW_RUN_AS_ROOT: 1
OMPI_ALLOW_RUN_AS_ROOT_CONFIRM: 1
ROCPROFSYS_CI: 'ON'
steps:
- uses: actions/checkout@v4
with:
sparse-checkout: projects/rocprofiler-systems/
- name: Install Packages
timeout-minutes: 25
uses: nick-fields/retry@v3
with:
retry_wait_seconds: 30
timeout_minutes: 25
max_attempts: 5
command: |
cd projects/rocprofiler-systems/
apt-get update &&
apt-get upgrade -y &&
apt-get install -y libomp-dev libopenmpi-dev ${{ matrix.compiler }} &&
apt-get autoclean
- name: Install ROCm Packages
timeout-minutes: 25
uses: nick-fields/retry@v3
with:
retry_wait_seconds: 30
timeout_minutes: 25
max_attempts: 5
shell: bash
command: |
cd projects/rocprofiler-systems/
ROCM_VERSION=${{ matrix.rocm-version }}
ROCM_MAJOR=$(echo ${ROCM_VERSION} | sed 's/\./ /g' | awk '{print $1}')
ROCM_MINOR=$(echo ${ROCM_VERSION} | sed 's/\./ /g' | awk '{print $2}')
ROCM_VERSN=$(( (${ROCM_MAJOR}*10000)+(${ROCM_MINOR}*100) ))
echo "ROCM_MAJOR=${ROCM_MAJOR} ROCM_MINOR=${ROCM_MINOR} ROCM_VERSN=${ROCM_VERSN}"
wget -q https://repo.radeon.com/amdgpu-install/${{ matrix.rocm-version }}/ubuntu/jammy/amdgpu-install_${ROCM_MAJOR}.${ROCM_MINOR}.${ROCM_VERSN}-1_all.deb
apt-get install -y ./amdgpu-install_${ROCM_MAJOR}.${ROCM_MINOR}.${ROCM_VERSN}-1_all.deb
apt-get update
apt-get install -y rocm-dev rocdecode-dev libavformat-dev libavcodec-dev
apt-get autoclean
echo "/opt/rocm/bin" >> $GITHUB_PATH
echo "ROCM_PATH=/opt/rocm" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=/opt/rocm/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
/opt/rocm/bin/hipcc -O3 -c ./examples/transpose/transpose.cpp -o /tmp/transpose.o
- name: Test Environment Modules
timeout-minutes: 15
shell: bash
working-directory: projects/rocprofiler-systems/
run: |
set -v
source /usr/share/modules/init/$(basename ${SHELL})
module avail
- name: Configure Env
working-directory: projects/rocprofiler-systems/
run: |
echo "CC=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')" >> $GITHUB_ENV
echo "CXX=${{ matrix.compiler }}" >> $GITHUB_ENV
- name: Configure, Build, and Test
timeout-minutes: 115
shell: bash
working-directory: projects/rocprofiler-systems/
run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
git config --global --add safe.directory ${PWD}
echo "CMake version: $(cmake --version | head -n 1)"
echo "Compiler version: $(${{ matrix.compiler }} --version | head -n 1)"
echo "ROCm version: ${{ matrix.rocm-version }}"
TAG=""
append-tagname() { if [ "${1}" == "ON" ]; then TAG="${TAG}-${2}"; fi; }
append-tagname ${{ matrix.rocm }} rocm-${{ matrix.rocm-version }}
append-tagname ${{ matrix.python }} python
append-tagname ${{ matrix.mpi-headers }} mpip
append-tagname ${{ matrix.build-dyninst }} internal-dyninst
append-tagname ${{ matrix.strip }} strip
append-tagname ${{ matrix.hidden }} hidden-viz
python3 ./scripts/run-ci.py -B build \
--name ${{ github.repository_owner }}-${{ github.ref_name }}-ubuntu-jammy-${{ matrix.compiler }}${TAG} \
--build-jobs 2 \
--site GitHub \
-- \
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g') \
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }} \
-DCMAKE_BUILD_TYPE=${{ matrix.build-type }} \
-DCMAKE_INSTALL_PREFIX=/opt/rocprofiler-systems-dev \
-DROCPROFSYS_BUILD_TESTING=ON \
-DROCPROFSYS_USE_PYTHON=${{ matrix.python }} \
-DROCPROFSYS_USE_MPI_HEADERS=${{ matrix.mpi-headers }} \
-DROCPROFSYS_BUILD_DYNINST=${{ matrix.build-dyninst }} \
-DROCPROFSYS_BUILD_BOOST=${{ matrix.build-dyninst }} \
-DROCPROFSYS_BUILD_TBB=${{ matrix.build-dyninst }} \
-DROCPROFSYS_BUILD_ELFUTILS=${{ matrix.build-dyninst }} \
-DROCPROFSYS_BUILD_LIBIBERTY=${{ matrix.build-dyninst }} \
-DROCPROFSYS_BUILD_HIDDEN_VISIBILITY=${{ matrix.hidden }} \
-DROCPROFSYS_PYTHON_PREFIX=/opt/conda/envs \
-DROCPROFSYS_PYTHON_ENVS="py3.7;py3.8;py3.9;py3.10;py3.11" \
-DROCPROFSYS_STRIP_LIBRARIES=${{ matrix.strip }} \
-DROCPROFSYS_MAX_THREADS=64 \
-DROCPROFSYS_DISABLE_EXAMPLES="transpose;rccl;openmp-target;openmp-vv;videodecode;jpegdecode;network" \
-DROCPROFSYS_BUILD_NUMBER=${{ github.run_attempt }} \
-DUSE_CLANG_OMP=OFF \
-- \
-LE "transpose|rccl|videodecode|jpegdecode|network"
- name: Check for Leftover Buffered Files
timeout-minutes: 5
working-directory: projects/rocprofiler-systems/
run: |
set -v
if find /tmp -maxdepth 1 -name 'buffered*' -print -quit | grep -q .; then
echo "Error: Found leftover buffered storage files in /tmp:"
ls -lh /tmp/buffered*
exit 1
else
echo "✓ No buffered storage files found in /tmp"
fi
- name: Test Clean Up
timeout-minutes: 10
working-directory: projects/rocprofiler-systems/
run: |
set -v
du /tmp -d 1 -h
du build/rocprof-sys-tests-output -d 1 -h
df -h
rm -fr /tmp/* build/rocprof-sys-tests-output/*
- name: Install
timeout-minutes: 10
working-directory: projects/rocprofiler-systems/
run: |
cmake --build build --target install --parallel 2
rm -fr /opt/rocprofiler-systems-dev/
- name: CPack and Install
working-directory: projects/rocprofiler-systems/
run: |
cd build
cpack -G STGZ
mkdir -p /opt/rocprofiler-systems
./rocprofiler-systems-*.sh --prefix=/opt/rocprofiler-systems --exclude-subdir --skip-license
- name: Test Install with Modulefile
timeout-minutes: 15
shell: bash
working-directory: projects/rocprofiler-systems/
run: |
set -v
source /usr/share/modules/init/$(basename ${SHELL})
module use /opt/rocprofiler-systems/share/modulefiles
module avail
module load rocprofiler-systems
./scripts/test-install.sh --test-rocprof-sys-{instrument,avail,sample,python,rewrite,runtime}=1
- name: Test User API
timeout-minutes: 10
working-directory: projects/rocprofiler-systems/
run: |
set -v
./scripts/test-find-package.sh --install-dir /opt/rocprofiler-systems
- name: CTest Artifacts
if: failure()
continue-on-error: True
uses: actions/upload-artifact@v4
with:
name: ctest-${{ github.job }}-${{ strategy.job-index }}-log
path: |
projects/rocprofiler-systems/build/*.log
- name: Data Artifacts
if: failure()
continue-on-error: True
uses: actions/upload-artifact@v4
with:
name: data-${{ github.job }}-${{ strategy.job-index }}-files
path: |
projects/rocprofiler-systems/build/rocprofsys-tests-config/*.cfg
projects/rocprofiler-systems/build/rocprofsys-tests-output/**/*.txt
projects/rocprofiler-systems/build/rocprofsys-tests-output/**/*-instr*.json
ubuntu-jammy-codecov:
runs-on: ubuntu-latest
container:
image: dgaliffiamd/rocprofiler-systems:ci-base-ubuntu-22.04
options: --cap-add CAP_SYS_ADMIN
env:
ROCPROFSYS_VERBOSE: 2
ROCPROFSYS_CAUSAL_BACKEND: perf
ROCPROFSYS_CI: 'ON'
steps:
- uses: actions/checkout@v4
with:
sparse-checkout: projects/rocprofiler-systems/
- name: Install Packages
timeout-minutes: 25
uses: nick-fields/retry@v3
with:
retry_wait_seconds: 30
timeout_minutes: 25
max_attempts: 5
command: |
cd projects/rocprofiler-systems/
apt-get update &&
apt-get upgrade -y &&
apt-get install -y libomp-dev libmpich-dev mpich &&
apt-get autoclean
- name: Install ROCm Packages
timeout-minutes: 25
uses: nick-fields/retry@v3
with:
retry_wait_seconds: 30
timeout_minutes: 25
max_attempts: 5
shell: bash
command: |
cd projects/rocprofiler-systems/
ROCM_VERSION=7.2
ROCM_MAJOR=$(echo ${ROCM_VERSION} | sed 's/\./ /g' | awk '{print $1}')
ROCM_MINOR=$(echo ${ROCM_VERSION} | sed 's/\./ /g' | awk '{print $2}')
ROCM_VERSN=$(( (${ROCM_MAJOR}*10000)+(${ROCM_MINOR}*100) ))
echo "ROCM_MAJOR=${ROCM_MAJOR} ROCM_MINOR=${ROCM_MINOR} ROCM_VERSN=${ROCM_VERSN}"
wget -q https://repo.radeon.com/amdgpu-install/${ROCM_VERSION}/ubuntu/jammy/amdgpu-install_${ROCM_MAJOR}.${ROCM_MINOR}.${ROCM_VERSN}-1_all.deb
apt-get install -y ./amdgpu-install_${ROCM_MAJOR}.${ROCM_MINOR}.${ROCM_VERSN}-1_all.deb
apt-get update
apt-get install -y rocm-dev
apt-get autoclean
echo "/opt/rocm/bin" >> $GITHUB_PATH
echo "ROCM_PATH=/opt/rocm" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=/opt/rocm/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Configure Env
run:
echo "${HOME}/.local/bin" >> $GITHUB_PATH
- name: Configure, Build, and Test
timeout-minutes: 115
shell: bash
working-directory: projects/rocprofiler-systems/
env:
GIT_DISCOVERY_ACROSS_FILESYSTEM: 1
run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
git config --global --add safe.directory ${PWD}
echo "CMake version: $(cmake --version | head -n 1)"
echo "Compiler version: $(gcc --version | head -n 1)"
python3 ./scripts/run-ci.py -B build \
--name ${{ github.repository_owner }}-${{ github.ref_name }}-ubuntu-jammy-codecov-mpi-python-ompt-papi \
--build-jobs 2 \
--site GitHub \
--coverage \
-- \
-DCMAKE_INSTALL_PREFIX=/opt/rocprofiler-systems \
-DROCPROFSYS_BUILD_CI=OFF \
-DROCPROFSYS_BUILD_TESTING=ON \
-DROCPROFSYS_BUILD_DYNINST=ON \
-DROCPROFSYS_BUILD_BOOST=ON \
-DROCPROFSYS_BUILD_TBB=ON \
-DROCPROFSYS_BUILD_ELFUTILS=ON \
-DROCPROFSYS_BUILD_LIBIBERTY=ON \
-DROCPROFSYS_BUILD_DEBUG=OFF \
-DROCPROFSYS_BUILD_HIDDEN_VISIBILITY=OFF \
-DROCPROFSYS_USE_MPI=ON \
-DROCPROFSYS_USE_PYTHON=ON \
-DROCPROFSYS_MAX_THREADS=64 \
-DROCPROFSYS_DISABLE_EXAMPLES="transpose;rccl;videodecode;jpegdecode;openmp" \
-DROCPROFSYS_BUILD_NUMBER=${{ github.run_attempt }} \
-- \
-LE "transpose|rccl|videodecode|jpegdecode|network"