Use concurrency in GitHub Actions + remove cancelling (#77)

* Use concurrency + remove cancelling

* Combined ubuntu-focal-external with ubuntu-focal-external-rocm

* Update workflow names and README

* Update ubuntu-focal name

* More tweaks to the name

* Change names in formatting workflow
Этот коммит содержится в:
Jonathan R. Madsen
2022-06-29 11:06:52 -05:00
коммит произвёл GitHub
родитель 22bcc2efd9
Коммит 9b800c028b
10 изменённых файлов: 165 добавлений и 169 удалений
-20
Просмотреть файл
@@ -1,20 +0,0 @@
name: cancel-builds-on-update
on:
workflow_run:
workflows: ['formatting', 'ubuntu-bionic', 'ubuntu-focal-external-rocm', 'ubuntu-focal-external', 'ubuntu-focal', 'opensuse', 'cpack-ubuntu', 'cpack-opensuse']
types: ['requested']
jobs:
cancel-duplicate-workflow-runs:
name: "Cancel duplicate ${{ github.event.workflow_run.id }} workflow runs"
runs-on: ubuntu-latest
steps:
- uses: potiuk/cancel-workflow-runs@master
name: "Cancel duplicate ${{ github.event.workflow_run.id }} workflow runs"
with:
cancelMode: duplicates
cancelFutureDuplicates: true
token: ${{ secrets.GITHUB_TOKEN }}
sourceRunId: ${{ github.event.workflow_run.id }}
notifyPRCancel: false
skipEventTypes: '["schedule"]'
+4
Просмотреть файл
@@ -5,6 +5,10 @@ on:
branches: [releases/**]
tags: []
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
GIT_DISCOVERY_ACROSS_FILESYSTEM: 1
+4
Просмотреть файл
@@ -5,6 +5,10 @@ on:
branches: [releases/**]
tags: []
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
GIT_DISCOVERY_ACROSS_FILESYSTEM: 1
+7 -5
Просмотреть файл
@@ -1,5 +1,3 @@
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: formatting
@@ -9,8 +7,12 @@ on:
pull_request:
branches: [ main, develop ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
python-formatting:
python:
runs-on: ubuntu-20.04
strategy:
matrix:
@@ -31,7 +33,7 @@ jobs:
run: |
black --diff --check .
cmake-format:
cmake:
runs-on: ubuntu-20.04
steps:
@@ -54,7 +56,7 @@ jobs:
exit 1
fi
clang-format:
source:
runs-on: ubuntu-20.04
steps:
+5 -1
Просмотреть файл
@@ -1,4 +1,4 @@
name: opensuse
name: OpenSUSE 15.2, 15.3 (Python)
on:
push:
@@ -6,6 +6,10 @@ on:
pull_request:
branches: [ main, develop ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
BUILD_TYPE: Release
OMNITRACE_VERBOSE: 1
+5 -1
Просмотреть файл
@@ -1,4 +1,4 @@
name: ubuntu-bionic
name: Ubuntu 18.04 (GCC, MPICH, Python)
on:
push:
@@ -6,6 +6,10 @@ on:
pull_request:
branches: [ main, develop ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
BUILD_TYPE: Release
ELFUTILS_DOWNLOAD_VERSION: 0.183
-136
Просмотреть файл
@@ -1,136 +0,0 @@
name: ubuntu-focal-external-rocm
on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main, develop ]
env:
BUILD_TYPE: MinSizeRel
OMNITRACE_VERBOSE: 1
OMNITRACE_CI: ON
OMNITRACE_OUTPUT_PATH: omnitrace-tests-output
OMNITRACE_OUTPUT_PREFIX: "%argt%/"
jobs:
ubuntu-focal-external-rocm:
runs-on: ubuntu-20.04
container:
image: jrmadsen/omnitrace-ci:ubuntu-20.04
strategy:
matrix:
compiler: ['g++']
rocm_version: ['4.3', '4.5', 'debian']
steps:
- uses: actions/checkout@v2
- name: Install Packages
timeout-minutes: 5
run:
apt-get update &&
apt-get install -y software-properties-common wget gnupg2 &&
wget -q -O - https://repo.radeon.com/rocm/rocm.gpg.key | apt-key add - &&
echo "deb [arch=amd64] https://repo.radeon.com/rocm/apt/${{ matrix.rocm_version }}/ ubuntu main" | tee /etc/apt/sources.list.d/rocm.list &&
apt-get update &&
apt-get install -y build-essential m4 autoconf libtool python3-pip clang libomp-dev ${{ matrix.compiler }} libudev-dev libnuma-dev rocm-dev rocm-utils roctracer-dev rocprofiler-dev hip-base hsa-amd-aqlprofile hsa-rocr-dev hsakmt-roct-dev libpapi-dev libopenmpi-dev curl &&
python3 -m pip install --upgrade pip &&
python3 -m pip install 'cmake==3.16.3' &&
for i in 6 7 8 9; do /opt/conda/envs/py3.${i}/bin/python -m pip install numpy perfetto dataclasses; done
- name: Configure Env
run:
echo "CC=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')" >> $GITHUB_ENV &&
echo "CXX=${{ matrix.compiler }}" >> $GITHUB_ENV &&
echo "CMAKE_PREFIX_PATH=/opt/dyninst:/opt/elfutils:${CMAKE_PREFIX_PATH}" >> $GITHUB_ENV &&
echo "/opt/omnitrace/bin:/opt/dyninst/bin:/opt/elfutils/bin:${HOME}/.local/bin" >> $GITHUB_PATH &&
echo "LD_LIBRARY_PATH=/opt/omnitrace/lib:/opt/dyninst/lib:/opt/elfutils/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Configure CMake
timeout-minutes: 10
run:
git config --global --add safe.directory ${PWD} &&
cmake --version &&
cmake -B build
-DCMAKE_C_COMPILER=${CC}
-DCMAKE_CXX_COMPILER=${CXX}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/omnitrace
-DOMNITRACE_BUILD_TESTING=OFF
-DOMNITRACE_BUILD_DEVELOPER=ON
-DOMNITRACE_BUILD_EXTRA_OPTIMIZATIONS=OFF
-DOMNITRACE_BUILD_LTO=OFF
-DOMNITRACE_USE_MPI=OFF
-DOMNITRACE_USE_MPI_HEADERS=ON
-DOMNITRACE_USE_HIP=ON
-DOMNITRACE_MAX_THREADS=64
-DOMNITRACE_USE_SANITIZER=OFF
-DOMNITRACE_USE_PAPI=OFF
-DOMNITRACE_INSTALL_PERFETTO_TOOLS=ON
- name: Build
timeout-minutes: 45
run:
cmake --build build --target all --parallel 2 -- VERBOSE=1
- name: Install
run:
cmake --build build --target install --parallel 2
- name: Test
timeout-minutes: 45
run:
cd build &&
ldd ./omnitrace &&
./omnitrace --help &&
ctest -V -N -O omnitrace-ctest-${{ github.job }}-commands.log &&
ctest -V --output-log omnitrace-ctest-${{ github.job }}.log --stop-on-failure
- name: Test Install
timeout-minutes: 10
run: |
set -v
traced --background
export OMNITRACE_DEBUG=ON
export OMNITRACE_PERFETTO_BACKEND=system
which omnitrace-avail
ldd $(which omnitrace-avail)
omnitrace-avail --help
omnitrace-avail -a
which omnitrace-critical-trace
ldd $(which omnitrace-critical-trace)
which omnitrace
ldd $(which omnitrace)
omnitrace --help
omnitrace -e -v 1 -o ls.inst --simulate -- ls
omnitrace -e -v 1 --simulate -- ls
omnitrace -e -v 1 -o ls.inst -- ls
perfetto --out ls-perfetto-trace.proto --txt -c omnitrace.cfg
./ls.inst
omnitrace -e -v 1 -- ls
du -m ls-perfetto-trace.proto
- name: Test User API
timeout-minutes: 10
run: |
set -v
./scripts/test-find-package.sh --install-dir /opt/omnitrace
- name: CTest Artifacts
if: success() || failure()
uses: actions/upload-artifact@v2
with:
name: ctest-${{ github.job }}-log
path: |
build/*.log
- name: Data Artifacts
if: success() || failure()
uses: actions/upload-artifact@v2
with:
name: data-${{ github.job }}-files
path: |
omnitrace-tests-output/**/*.txt
build/omnitrace-tests-output/**/*.txt
build/omnitrace-tests-output/**/*-instr*.json
+131 -1
Просмотреть файл
@@ -1,4 +1,4 @@
name: ubuntu-focal-external
name: Ubuntu 20.04 (GCC, Python, ROCm)
on:
push:
@@ -6,6 +6,10 @@ on:
pull_request:
branches: [ main, develop ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
OMNITRACE_VERBOSE: 1
OMNITRACE_CI: ON
@@ -163,3 +167,129 @@ jobs:
path: |
build/omnitrace-tests-output/**/*.txt
build/omnitrace-tests-output/**/*-instr*.json
ubuntu-focal-external-rocm:
runs-on: ubuntu-20.04
container:
image: jrmadsen/omnitrace-ci:ubuntu-20.04
strategy:
matrix:
compiler: ['g++']
rocm_version: ['4.3', '4.5', 'debian']
env:
BUILD_TYPE: MinSizeRel
OMNITRACE_OUTPUT_PATH: omnitrace-tests-output
OMNITRACE_OUTPUT_PREFIX: "%argt%/"
steps:
- uses: actions/checkout@v2
- name: Install Packages
timeout-minutes: 5
run:
apt-get update &&
apt-get install -y software-properties-common wget gnupg2 &&
wget -q -O - https://repo.radeon.com/rocm/rocm.gpg.key | apt-key add - &&
echo "deb [arch=amd64] https://repo.radeon.com/rocm/apt/${{ matrix.rocm_version }}/ ubuntu main" | tee /etc/apt/sources.list.d/rocm.list &&
apt-get update &&
apt-get install -y build-essential m4 autoconf libtool python3-pip clang libomp-dev ${{ matrix.compiler }} libudev-dev libnuma-dev rocm-dev rocm-utils roctracer-dev rocprofiler-dev hip-base hsa-amd-aqlprofile hsa-rocr-dev hsakmt-roct-dev libpapi-dev libopenmpi-dev curl &&
python3 -m pip install --upgrade pip &&
python3 -m pip install 'cmake==3.16.3' &&
for i in 6 7 8 9; do /opt/conda/envs/py3.${i}/bin/python -m pip install numpy perfetto dataclasses; done
- name: Configure Env
run:
echo "CC=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')" >> $GITHUB_ENV &&
echo "CXX=${{ matrix.compiler }}" >> $GITHUB_ENV &&
echo "CMAKE_PREFIX_PATH=/opt/dyninst:/opt/elfutils:${CMAKE_PREFIX_PATH}" >> $GITHUB_ENV &&
echo "/opt/omnitrace/bin:/opt/dyninst/bin:/opt/elfutils/bin:${HOME}/.local/bin" >> $GITHUB_PATH &&
echo "LD_LIBRARY_PATH=/opt/omnitrace/lib:/opt/dyninst/lib:/opt/elfutils/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Configure CMake
timeout-minutes: 10
run:
git config --global --add safe.directory ${PWD} &&
cmake --version &&
cmake -B build
-DCMAKE_C_COMPILER=${CC}
-DCMAKE_CXX_COMPILER=${CXX}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/omnitrace
-DOMNITRACE_BUILD_TESTING=OFF
-DOMNITRACE_BUILD_DEVELOPER=ON
-DOMNITRACE_BUILD_EXTRA_OPTIMIZATIONS=OFF
-DOMNITRACE_BUILD_LTO=OFF
-DOMNITRACE_USE_MPI=OFF
-DOMNITRACE_USE_MPI_HEADERS=ON
-DOMNITRACE_USE_HIP=ON
-DOMNITRACE_MAX_THREADS=64
-DOMNITRACE_USE_SANITIZER=OFF
-DOMNITRACE_USE_PAPI=OFF
-DOMNITRACE_INSTALL_PERFETTO_TOOLS=ON
- name: Build
timeout-minutes: 45
run:
cmake --build build --target all --parallel 2 -- VERBOSE=1
- name: Install
run:
cmake --build build --target install --parallel 2
- name: Test
timeout-minutes: 45
run:
cd build &&
ldd ./omnitrace &&
./omnitrace --help &&
ctest -V -N -O omnitrace-ctest-${{ github.job }}-commands.log &&
ctest -V --output-log omnitrace-ctest-${{ github.job }}.log --stop-on-failure
- name: Test Install
timeout-minutes: 10
run: |
set -v
traced --background
export OMNITRACE_DEBUG=ON
export OMNITRACE_PERFETTO_BACKEND=system
which omnitrace-avail
ldd $(which omnitrace-avail)
omnitrace-avail --help
omnitrace-avail -a
which omnitrace-critical-trace
ldd $(which omnitrace-critical-trace)
which omnitrace
ldd $(which omnitrace)
omnitrace --help
omnitrace -e -v 1 -o ls.inst --simulate -- ls
omnitrace -e -v 1 --simulate -- ls
omnitrace -e -v 1 -o ls.inst -- ls
perfetto --out ls-perfetto-trace.proto --txt -c omnitrace.cfg
./ls.inst
omnitrace -e -v 1 -- ls
du -m ls-perfetto-trace.proto
- name: Test User API
timeout-minutes: 10
run: |
set -v
./scripts/test-find-package.sh --install-dir /opt/omnitrace
- name: CTest Artifacts
if: success() || failure()
uses: actions/upload-artifact@v2
with:
name: ctest-${{ github.job }}-log
path: |
build/*.log
- name: Data Artifacts
if: success() || failure()
uses: actions/upload-artifact@v2
with:
name: data-${{ github.job }}-files
path: |
omnitrace-tests-output/**/*.txt
build/omnitrace-tests-output/**/*.txt
build/omnitrace-tests-output/**/*-instr*.json
+5 -1
Просмотреть файл
@@ -1,4 +1,4 @@
name: ubuntu-focal
name: Ubuntu 20.04 (GCC, MPICH, OpenMPI)
on:
push:
@@ -6,6 +6,10 @@ on:
pull_request:
branches: [ main, develop ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
ELFUTILS_DOWNLOAD_VERSION: 0.186
OMNITRACE_VERBOSE: 1
+4 -4
Просмотреть файл
@@ -1,9 +1,9 @@
# Omnitrace: Application Profiling, Tracing, and Analysis
[![Ubuntu 18.04 (GCC 7, 8, MPICH)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-bionic.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-bionic.yml)
[![Ubuntu 20.04 (GCC 7, 8, 9, 10)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal-external.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal-external.yml)
[![Ubuntu 20.04 (GCC 9, MPICH, OpenMPI)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal.yml)
[![Ubuntu 20.04 (GCC 9, MPICH, OpenMPI, ROCm 4.3, 4.5, 5.0)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal-external-rocm.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal-external-rocm.yml)
[![Ubuntu 18.04 with GCC and MPICH](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-bionic.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-bionic.yml)
[![Ubuntu 20.04 with GCC and ROCm](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal-external.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal-external.yml)
[![Ubuntu 20.04 with GCC and MPI](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/ubuntu-focal.yml)
[![OpenSUSE 15.x with GCC](https://github.com/AMDResearch/omnitrace/actions/workflows/opensuse.yml/badge.svg)](https://github.com/AMDResearch/omnitrace/actions/workflows/opensuse.yml)
> ***[Omnitrace](https://github.com/AMDResearch/omnitrace) is an AMD open source research project and is not supported as part of the ROCm software stack.***