* Continuous integration

* linux-ci on

* fix for parallel-overhead

* Updated CMAKE_INSTALL_PREFIX

* Updated installed boost libraries

* Dyninst updates fixing TBB install

* timemory + dyninst submodule updates

- fixes some timemory package option handling
- fixes dyninst libiberty handling

* Update dyninst submodule with libiberty fix

* dyninst submodule update with TBB internal build fixes

* Updated linux-ci + tests + timemeory + dyninst

- updated timemory submodule
- update dyninst submodule
- delay OnLoad implementation
- DYNINST_RT_API handling improvement
- CI for ubuntu-bionic in addition to focal
- CTest in CI

* Update TBB handling in CI

* Update dyninst with symLite fix

* Update dyninst submodule with ElfUtils-External fix

* Dyninst::ElfUtils fix

* Modified dyninst submodule TPL install

* Update dyninst submodule with improved interface libraries

* Fix to Dyninst::ElfUtils in dyninst submodule

* Updated CI build matrix + test install

* Updated CI

* CI stage updates

* Tweak

* Dyninst updates + RPATH for hosttrace exe

- hosttrace will rpath to dyninst
- Dyninst will statically link to boost by default
- Fixes to double init w/ MPI + runtime instrumentation
- minor cleanup to hosttrace
- hosttrace help exits with zero
- CI updates

* Dyninst + CI updates

* Removed ELFUTILS_BUILD_STATIC option in Dyninst

* Dyninst + visibility + roctracer + tests

- Dyninst submodule updates with dynamic pcontrol lib
- hosttrace visibility is hidden
- improved handling of DYNINST_API_RT in hosttrace
- roctracer::tear_down in finalize fixes issues with timemory
- throw error if cannot create perfetto output file
- roctracer_default_pool() safety guards
- resume calling roctracer_close_pool()
- fixed working dir of tests
- fixed env of tests (cmake and CI)
- simplified CI

* Removed stray CI if condition

* Disable hidden visibility for now

* ifdef for roctracer::tear_down + reenable hidden

* Better CI environment handling + dyninst packaging

* Fix for dyninst-package CI

* Fixes for cmake 3.15 issues with aliasing imported lib

* Fix to ubuntu-focal-dyninst-package

* Dyninst updates for packaging

- fixes issues with hard-coded paths to libraries after relocation via package installer

* Restrict CI to main and develop branches
Bu işleme şunda yer alıyor:
Jonathan R. Madsen
2021-09-15 16:45:49 -05:00
işlemeyi yapan: GitHub
ebeveyn ea60acc4b6
işleme 35ab6b0110
14 değiştirilmiş dosya ile 838 ekleme ve 275 silme
+20
Dosyayı Görüntüle
@@ -0,0 +1,20 @@
name: cancel-builds-on-update
on:
workflow_run:
workflows: ['linux-ci', 'formatting']
types: ['requested']
jobs:
cancel-duplicate-workflow-runs:
name: "Cancel duplicate workflow runs"
runs-on: ubuntu-latest
steps:
- uses: potiuk/cancel-workflow-runs@master
name: "Cancel duplicate workflow runs"
with:
cancelMode: duplicates
cancelFutureDuplicates: true
token: ${{ secrets.GITHUB_TOKEN }}
sourceRunId: ${{ github.event.workflow_run.id }}
notifyPRCancel: true
skipEventTypes: '["schedule"]'
+39
Dosyayı Görüntüle
@@ -0,0 +1,39 @@
# 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
on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main, develop ]
jobs:
formatting:
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: |
DISTRIB_CODENAME=$(cat /etc/lsb-release | grep DISTRIB_CODENAME | awk -F '=' '{print $NF}')
sudo apt-get update
sudo apt-get install -y software-properties-common wget curl
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
echo "deb http://apt.llvm.org/${DISTRIB_CODENAME}/ llvm-toolchain-${DISTRIB_CODENAME}-11 main" | sudo tee -a /etc/apt/sources.list.d/llvm-toolchain.list
echo "deb-src http://apt.llvm.org/${DISTRIB_CODENAME}/ llvm-toolchain-${DISTRIB_CODENAME}-11 main" | sudo tee -a /etc/apt/sources.list.d/llvm-toolchain.list
sudo apt-get update
sudo apt-get install -y clang-format-11
- name: clang-format
run: |
set +e
FILES=$(find include src examples -type f | egrep '\.hpp$|\.cpp$|\.cpp\.in$')
FORMAT_OUT=$(clang-format-11 -output-replacements-xml ${FILES})
RET=$(echo ${FORMAT_OUT} | grep -c '<replacement ')
if [ "${RET}" -ne 0 ]; then
echo -e "\nError! Code not formatted. Detected ${RET} lines\n"
clang-format-11 -i ${FILES}
git diff
exit ${RET}
fi
+327
Dosyayı Görüntüle
@@ -0,0 +1,327 @@
name: linux-ci
on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main, develop ]
env:
BUILD_TYPE: Release
ELFUTILS_DOWNLOAD_VERSION: 0.183
jobs:
ubuntu-focal:
runs-on: ubuntu-20.04
strategy:
matrix:
compiler: ['g++']
mpi: [ '', 'libmpich-dev mpich', 'libopenmpi-dev openmpi-bin libfabric-dev' ]
steps:
- uses: actions/checkout@v2
- name: Install Packages
run:
sudo apt-get update &&
sudo apt-get install -y build-essential python3-pip libtbb-dev libboost-{atomic,system,thread,date-time,filesystem,timer}-dev ${{ matrix.compiler }} ${{ matrix.mpi }} &&
python3 -m pip install --upgrade pip &&
python3 -m pip install 'cmake==3.15.3'
- name: Configure Env
run:
echo "CC=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')" >> $GITHUB_ENV &&
echo "CXX=${{ matrix.compiler }}" >> $GITHUB_ENV &&
echo "/opt/hosttrace/bin:${HOME}/.local/bin" >> $GITHUB_PATH &&
echo "LD_LIBRARY_PATH=/opt/hosttrace/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Configure CMake
run:
cmake --version &&
if [ -z "${{ matrix.mpi }}" ]; then USE_MPI=OFF; else USE_MPI=ON; fi &&
cmake -B ${{ github.workspace }}/build
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/hosttrace
-DHOSTTRACE_USE_MPI=${USE_MPI}
-DHOSTTRACE_USE_ROCTRACER=OFF
-DHOSTTRACE_BUILD_DYNINST=ON
-DDYNINST_BUILD_ELFUTILS=ON
-DDYNINST_BUILD_LIBIBERTY=ON
-DDYNINST_BUILD_SHARED_LIBS=ON
-DDYNINST_BUILD_STATIC_LIBS=OFF
- name: Build
run:
cmake --build ${{ github.workspace }}/build --target all --parallel 2 -- VERBOSE=1
- name: Install
run:
cmake --build ${{ github.workspace }}/build --target install --parallel 2
- name: Test
working-directory: ${{ github.workspace }}/build
run:
ctest -V --output-log ${{ github.workspace }}/build/hosttrace-ctest.log
- name: Test Install
run:
hosttrace --help &&
hosttrace -- sleep 1 &&
hosttrace -o sleep.inst -- sleep &&
./sleep.inst 1 &&
rm ./sleep.inst
- name: Artifacts
uses: actions/upload-artifact@v2
with:
name: ctest-log
path: |
${{ github.workspace }}/build/hosttrace-ctest.log
ubuntu-bionic:
runs-on: ubuntu-18.04
strategy:
matrix:
compiler: ['g++-7', 'g++-8']
mpi: [ '', 'libmpich-dev mpich', 'libopenmpi-dev openmpi-bin libfabric-dev' ]
steps:
- uses: actions/checkout@v2
- name: Install Packages
run:
sudo apt-get update &&
sudo apt-get install -y build-essential python3-pip ${{ matrix.compiler }} ${{ matrix.mpi }} &&
python3 -m pip install --upgrade pip &&
python3 -m pip install 'cmake==3.15.3'
- name: Configure Env
run:
echo "CC=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')" >> $GITHUB_ENV &&
echo "CXX=${{ matrix.compiler }}" >> $GITHUB_ENV &&
echo "/opt/hosttrace/bin:${HOME}/.local/bin" >> $GITHUB_PATH &&
echo "LD_LIBRARY_PATH=/opt/hosttrace/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Configure CMake
run:
cmake --version &&
if [ -z "${{ matrix.mpi }}" ]; then USE_MPI=OFF; else USE_MPI=ON; fi &&
cmake -B ${{ github.workspace }}/build
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/hosttrace
-DHOSTTRACE_USE_MPI=${USE_MPI}
-DHOSTTRACE_USE_ROCTRACER=OFF
-DHOSTTRACE_BUILD_DYNINST=ON
-DDYNINST_BUILD_TBB=ON
-DDYNINST_BUILD_BOOST=ON
-DDYNINST_BUILD_ELFUTILS=ON
-DDYNINST_BUILD_LIBIBERTY=ON
- name: Build
run:
cmake --build ${{ github.workspace }}/build --target all --parallel 2 -- VERBOSE=1
- name: Install
run:
cmake --build ${{ github.workspace }}/build --target install --parallel 2
- name: Test
working-directory: ${{ github.workspace }}/build
run:
ctest -V --output-log ${{ github.workspace }}/build/hosttrace-ctest.log
- name: Test Install
run:
hosttrace --help &&
hosttrace -- sleep 1 &&
hosttrace -o sleep.inst -- sleep &&
./sleep.inst 1 &&
rm ./sleep.inst
- name: Artifacts
uses: actions/upload-artifact@v2
with:
name: ctest-log
path: |
${{ github.workspace }}/build/hosttrace-ctest.log
ubuntu-focal-external:
runs-on: ubuntu-20.04
strategy:
matrix:
compiler: ['g++-7', 'g++-8', 'g++-9', 'g++-10']
steps:
- uses: actions/checkout@v2
- name: Install Packages
run:
sudo apt-get update &&
sudo apt-get install -y build-essential python3-pip libboost-{atomic,system,thread,date-time,filesystem,timer}-dev libtbb-dev libiberty-dev ${{ matrix.compiler }} &&
sudo python3 -m pip install --upgrade pip &&
python3 -m pip install 'cmake==3.15.3'
- 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/opt/dyninst:/opt/elfutils:${CMAKE_PREFIX_PATH}" >> $GITHUB_ENV &&
echo "/opt/hosttrace/bin:/opt/dyninst/bin:/opt/elfutils/bin:${HOME}/.local/bin" >> $GITHUB_PATH &&
echo "LD_LIBRARY_PATH=/opt/hosttrace/lib:/opt/dyninst/lib:/opt/elfutils/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Install ElfUtils
run:
pushd external &&
wget https://sourceware.org/elfutils/ftp/${ELFUTILS_DOWNLOAD_VERSION}/elfutils-${ELFUTILS_DOWNLOAD_VERSION}.tar.bz2 &&
tar xjf elfutils-${ELFUTILS_DOWNLOAD_VERSION}.tar.bz2 &&
pushd elfutils-${ELFUTILS_DOWNLOAD_VERSION} &&
CFLAGS="-g -O2" ./configure --enable-install-elfh --prefix=/opt/elfutils --disable-libdebuginfod --disable-debuginfod &&
make -j2 &&
make install -j2 &&
popd &&
rm -rf elfutils*
- name: Install Dyninst
run:
cmake --version &&
git submodule update --init external/dyninst &&
cd external/dyninst &&
cmake -B build
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/dyninst &&
cmake --build build --target all --parallel 2 &&
cmake --build build --target install --parallel 2 &&
rm -rf build
- name: Configure CMake
run:
cmake --version &&
cmake -B ${{ github.workspace }}/build
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/hosttrace
-DHOSTTRACE_USE_MPI=OFF
-DHOSTTRACE_USE_ROCTRACER=OFF
- name: Build
run:
cmake --build ${{ github.workspace }}/build --target all --parallel 2 -- VERBOSE=1
- name: Install
run:
cmake --build ${{ github.workspace }}/build --target install --parallel 2
- name: Test
working-directory: ${{ github.workspace }}/build
run:
ldd ./hosttrace &&
./hosttrace --help &&
ctest -V --output-log ${{ github.workspace }}/build/hosttrace-ctest.log
- name: Test Install
run:
ldd $(which hosttrace) &&
hosttrace --help &&
hosttrace -- sleep 1 &&
hosttrace -o sleep.inst -- sleep &&
./sleep.inst 1 &&
rm ./sleep.inst
- name: Artifacts
uses: actions/upload-artifact@v2
with:
name: ctest-log
path: |
${{ github.workspace }}/build/hosttrace-ctest.log
ubuntu-focal-dyninst-package:
runs-on: ubuntu-20.04
strategy:
matrix:
compiler: ['g++']
steps:
- uses: actions/checkout@v2
- name: Install Packages
run:
sudo apt-get update &&
sudo apt-get install -y build-essential python3-pip ${{ matrix.compiler }} &&
sudo python3 -m pip install --upgrade pip &&
python3 -m pip install 'cmake==3.15.3'
- 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/opt/dyninst:${CMAKE_PREFIX_PATH}" >> $GITHUB_ENV &&
echo "/opt/hosttrace/bin:/opt/dyninst/bin:${HOME}/.local/bin" >> $GITHUB_PATH &&
echo "LD_LIBRARY_PATH=/opt/hosttrace/lib:/opt/dyninst/lib:${LD_LIBRARY_PATH}" >> $GITHUB_ENV
- name: Install Dyninst
run:
cmake --version &&
git submodule update --init external/dyninst &&
cd external/dyninst &&
cmake -B build
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/external/dyninst-install
-DBUILD_TBB=ON
-DBUILD_BOOST=ON
-DBUILD_ELFUTILS=ON
-DBUILD_LIBIBERTY=ON &&
cmake --build build --target package --parallel 4 &&
mkdir /opt/dyninst &&
./build/Dyninst-*-Linux.sh --prefix=/opt/dyninst --exclude-subdir --skip-license &&
rm -rf build
- name: Configure CMake
run:
cmake --version &&
cmake -B ${{ github.workspace }}/build
-DCMAKE_C_COMPILER=$(echo '${{ matrix.compiler }}' | sed 's/+/c/g')
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }}
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
-DCMAKE_INSTALL_PREFIX=/opt/hosttrace
-DHOSTTRACE_USE_MPI=OFF
-DHOSTTRACE_USE_ROCTRACER=OFF
- name: Build
run:
cmake --build ${{ github.workspace }}/build --target all --parallel 2 -- VERBOSE=1
- name: Install
run:
cmake --build ${{ github.workspace }}/build --target install --parallel 2
- name: Test
working-directory: ${{ github.workspace }}/build
run:
ldd ./hosttrace &&
./hosttrace --help &&
ctest -V --output-log ${{ github.workspace }}/build/hosttrace-ctest.log
- name: Test Install
run:
ldd $(which hosttrace) &&
hosttrace --help &&
hosttrace -- sleep 1 &&
hosttrace -o sleep.inst -- sleep &&
./sleep.inst 1 &&
rm ./sleep.inst
- name: Artifacts
uses: actions/upload-artifact@v2
with:
name: ctest-log
path: |
${{ github.workspace }}/build/hosttrace-ctest.log