diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml new file mode 100644 index 0000000000..55f991a628 --- /dev/null +++ b/.github/workflows/cmake.yml @@ -0,0 +1,539 @@ +name: CMake + +on: + push: + branches: [ "amd-staging" ] + pull_request: + branches: [ "amd-staging" ] + +env: + # Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) + BUILD_TYPE: RelWithDebInfo + PREFIX_PATH: "/opt/rocm" + ROCM_PATH: "/opt/rocm" + LD_RUNPATH_FLAG: " -Wl,--enable-new-dtags -Wl,--rpath,/opt/rocm/lib" + GPU_LIST: "gfx900 gfx906 gfx908 gfx90a gfx940 gfx941 gfx942 gfx1030 gfx1100 gfx1101 gfx1102" + +jobs: + build_run_on_mi200: + runs-on: mi200 + steps: + - name: Run on MI200 + run: echo "Running on MI200" + + build_run_on_mi200_ubuntu_22_04: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: mi200 + needs: build_run_on_mi200 + container: + image: localhost:5000/mainline-ubuntu-22.04-stg1 + options: --privileged --ipc=host --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --cap-add CAP_SYS_PTRACE --cap-add CAP_SYS_ADMIN --security-opt seccomp=unconfined + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_ubuntu_22_04 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests, Samples, Documentation, Packages + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests samples doc package + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_ubuntu_22_04 + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + ./run_tests.sh + + - name: Archive production artifacts + uses: actions/upload-artifact@v3 + with: + name: artifacts + path: | + ${{github.workspace}}/build/*.deb + ${{github.workspace}}/build/*.rpm + ${{github.workspace}}/build/*.tgz + + build_run_on_mi200_ubuntu_20_04: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: mi200 + needs: build_run_on_mi200 + container: + image: localhost:5000/mainline-ubuntu-20.04-stg1 + options: --privileged --ipc=host --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --cap-add CAP_SYS_PTRACE --cap-add CAP_SYS_ADMIN --security-opt seccomp=unconfined + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_ubuntu_20_04 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + build_run_on_mi200_sles: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: mi200 + needs: build_run_on_mi200 + container: + image: localhost:5000/mainline-sles-stg1 + options: --privileged --ipc=host --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --cap-add CAP_SYS_PTRACE --cap-add CAP_SYS_ADMIN --security-opt seccomp=unconfined + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_sles + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_sles + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + build_run_on_mi200_rhel_8: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: mi200 + needs: build_run_on_mi200 + container: + image: localhost:5000/mainline-rhel-8.x-stg1 + options: --privileged --ipc=host --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --cap-add CAP_SYS_PTRACE --cap-add CAP_SYS_ADMIN --security-opt seccomp=unconfined + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_rhel_8 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_rhel_8 + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + build_run_on_mi200_rhel_9: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: mi200 + needs: build_run_on_mi200 + container: + image: localhost:5000/mainline-rhel-9.x-stg1 + options: --privileged --ipc=host --device=/dev/kfd --device=/dev/dri --group-add video --cap-add=SYS_PTRACE --cap-add CAP_SYS_PTRACE --cap-add CAP_SYS_ADMIN --security-opt seccomp=unconfined + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_rhel_9 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: mi200_rhel_9 + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + build_run_on_vega20: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: vega20 + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: vega20 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: vega20 + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + build_run_on_navi32: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: navi32 + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: navi32 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: navi32 + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + build_run_on_mi100: + # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # You can convert this to a matrix build if you need cross-platform coverage. + # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + runs-on: mi100 + + steps: + - uses: actions/checkout@v3 + + - name: Restore cached Build + id: cache-build-restore + uses: actions/cache/restore@v3 + with: + path: | + ${{github.workspace}}/build + key: mi100 + + - name: Configure CMake + if: steps.cache-build-restore.outputs.cache-hit != 'false' + # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + - name: Preparing Test Build + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + - name: Build Tests + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + - name: Save Build + id: cache-build-save + uses: actions/cache/save@v3 + with: + path: | + ${{github.workspace}}/build + key: mi100 + + - name: Testing V1 + run: | + cd ${{github.workspace}}/build + ./run.sh + # TODO(aelwazir): Enable this once ctest is fixed + # working-directory: ${{github.workspace}}/build/tests-v2 + # Execute tests defined by the CMake configuration. + # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # TODO(aelwazir): Enable this once ctest is fixed + # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + - name: Testing V2 + run: | + cd ${{github.workspace}}/build + make -j check + + # To be enabled once we have access to navi21 + # build_run_on_navi21: + # # The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac. + # # You can convert this to a matrix build if you need cross-platform coverage. + # # See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix + # runs-on: navi21 + + # steps: + # - uses: actions/checkout@v3 + + # - name: Restore cached Build + # id: cache-build-restore + # uses: actions/cache/restore@v3 + # with: + # path: | + # ${{github.workspace}}/build + # key: navi21 + + # - name: Configure CMake + # if: steps.cache-build-restore.outputs.cache-hit != 'false' + # # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make. + # # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type + # run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DCMAKE_EXPORT_COMPILE_COMMANDS=TRUE -DCMAKE_MODULE_PATH="${{env.ROCM_PATH}}/hip/cmake;${{env.ROCM_PATH}}/lib/cmake" -DCMAKE_PREFIX_PATH="${{env.PREFIX_PATH}}" -DCMAKE_INSTALL_PREFIX="${{env.ROCM_PATH}}" -DCMAKE_SHARED_LINKER_FLAGS="${{env.LD_RUNPATH_FLAG}}" -DCMAKE_INSTALL_RPATH=${{env.ROCM_RPATH}} -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=FALSE -DGPU_TARGETS="${{env.GPU_LIST}}" -DCPACK_PACKAGING_INSTALL_PREFIX=${{env.ROCM_PATH}} -DCPACK_GENERATOR='DEB;RPM;TGZ' -DCPACK_OBJCOPY_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objcopy" -DCPACK_READELF_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-readelf" -DCPACK_STRIP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-strip" -DCPACK_OBJDUMP_EXECUTABLE="${{env.ROCM_PATH}}/llvm/bin/llvm-objdump" + + # - name: Build + # # Build your program with the given configuration + # run: cmake --build ${{github.workspace}}/build --parallel 16 --config ${{env.BUILD_TYPE}} + # - name: Preparing Test Build + # run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 mytest + # - name: Build Tests + # run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -- -j 16 tests + + # - name: Save Build + # id: cache-build-save + # uses: actions/cache/save@v3 + # with: + # path: | + # ${{github.workspace}}/build + # key: navi21 + + # - name: Testing V1 + # run: | + # cd ${{github.workspace}}/build + # ./run.sh + # # TODO(aelwazir): Enable this once ctest is fixed + # # working-directory: ${{github.workspace}}/build/tests-v2 + # # Execute tests defined by the CMake configuration. + # # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail + # # TODO(aelwazir): Enable this once ctest is fixed + # # run: ctest --parallel 16 -C ${{env.BUILD_TYPE}} + + # - name: Testing V2 + # run: | + # cd ${{github.workspace}}/build + # make -j check diff --git a/.github/workflows/pull.yml b/.github/workflows/pull.yml new file mode 100644 index 0000000000..71a78e9885 --- /dev/null +++ b/.github/workflows/pull.yml @@ -0,0 +1,19 @@ +name: "Pull from Gerrit" +on: + schedule: + - cron: "* */23 * * *" + +jobs: + pull: + runs-on: mi200 + steps: + - name: Adding Gerrit Remote + run: git remote add gerrit ssh://aelwazir@gerrit-git.amd.com:29418/compute/ec/rocprofiler + - name: Fetching Gerrit + run: git fetch --all + - name: Checking out amd-staging + run: git checkout amd-staging + - name: Merging staging branches + run: git merge gerrit/amd-staging + - name: Pushing to amd-staging + run: git push origin amd-staging \ No newline at end of file diff --git a/.github/workflows/pull_latest_dockers.yml b/.github/workflows/pull_latest_dockers.yml new file mode 100644 index 0000000000..6944ecb0e0 --- /dev/null +++ b/.github/workflows/pull_latest_dockers.yml @@ -0,0 +1,137 @@ +name: Get Latest Dockers + +on: + schedule: + - cron: "* */23 * * *" + +jobs: + getting_latest_docker_mi200: + runs-on: mi200 + + steps: + - uses: actions/checkout@v3 + - name: pull_the_latest_images + run: | + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 + + - name: tag_the_latest_docker + run: | + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 localhost:5000/mainline-sles-stg1:latest + docker push localhost:5000/mainline-sles-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 localhost:5000/mainline-rhel-9.x-stg1:latest + docker push localhost:5000/mainline-rhel-9.x-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 localhost:5000/mainline-rhel-8.x-stg1:latest + docker push localhost:5000/mainline-rhel-8.x-stg1:latest + + getting_latest_docker_mi100: + runs-on: mi100 + + steps: + - uses: actions/checkout@v3 + - name: pull_the_latest_images + run: | + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 + + - name: tag_the_latest_docker + run: | + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 localhost:5000/mainline-sles-stg1:latest + docker push localhost:5000/mainline-sles-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 localhost:5000/mainline-rhel-9.x-stg1:latest + docker push localhost:5000/mainline-rhel-9.x-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 localhost:5000/mainline-rhel-8.x-stg1:latest + docker push localhost:5000/mainline-rhel-8.x-stg1:latest + + getting_latest_docker_vega20: + runs-on: vega20 + + steps: + - uses: actions/checkout@v3 + - name: pull_the_latest_images + run: | + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 + + - name: tag_the_latest_docker + run: | + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 localhost:5000/mainline-sles-stg1:latest + docker push localhost:5000/mainline-sles-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 localhost:5000/mainline-rhel-9.x-stg1:latest + docker push localhost:5000/mainline-rhel-9.x-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 localhost:5000/mainline-rhel-8.x-stg1:latest + docker push localhost:5000/mainline-rhel-8.x-stg1:latest + + + getting_latest_docker_navi32: + runs-on: navi32 + + steps: + - uses: actions/checkout@v3 + - name: pull_the_latest_images + run: | + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 + docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 + + - name: tag_the_latest_docker + run: | + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-22.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker push localhost:5000/mainline-ubuntu-20.04-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 localhost:5000/mainline-sles-stg1:latest + docker push localhost:5000/mainline-sles-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 localhost:5000/mainline-rhel-9.x-stg1:latest + docker push localhost:5000/mainline-rhel-9.x-stg1:latest + docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 localhost:5000/mainline-rhel-8.x-stg1:latest + docker push localhost:5000/mainline-rhel-8.x-stg1:latest + + # getting_latest_docker_navi21: + # runs-on: navi21 + + # steps: + # - uses: actions/checkout@v3 + # - name: pull_the_latest_images + # run: | + # docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 + # docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 + # docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 + # docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 + # docker pull compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 + + # - name: tag_the_latest_docker + # run: | + # docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-22.04-stg1 localhost:5000/mainline-ubuntu-22.04-stg1:latest + # docker push localhost:5000/mainline-ubuntu-22.04-stg1:latest + # docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-ubuntu-20.04-stg1 localhost:5000/mainline-ubuntu-20.04-stg1:latest + # docker push localhost:5000/mainline-ubuntu-20.04-stg1:latest + # docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-sles-stg1 localhost:5000/mainline-sles-stg1:latest + # docker push localhost:5000/mainline-sles-stg1:latest + # docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-9.x-stg1 localhost:5000/mainline-rhel-9.x-stg1:latest + # docker push localhost:5000/mainline-rhel-9.x-stg1:latest + # docker tag compute-artifactory.amd.com:5000/rocm-plus-docker/compute-rocm-dkms-no-npi-hipclang:$(wget -qO- "http://rocm-ci.amd.com/job/compute-rocm-dkms-no-npi-hipclang/lastSuccessfulBuild/buildNumber")-rhel-8.x-stg1 localhost:5000/mainline-rhel-8.x-stg1:latest + # docker push localhost:5000/mainline-rhel-8.x-stg1:latest diff --git a/build.sh b/build.sh index fffceef6d8..d2e6dedd25 100755 --- a/build.sh +++ b/build.sh @@ -104,11 +104,10 @@ MAKE_OPTS="-j -C $ROCPROFILER_ROOT/$BUILD_DIR" cmake --build "$BUILD_DIR" -- $MAKE_OPTS cmake --build "$BUILD_DIR" -- $MAKE_OPTS mytest -cmake --build "$BUILD_DIR" -- $MAKE_OPTS tests if [ "$RUN_TEST" = "no" ] ; then - cmake --build "$BUILD_DIR" -- $MAKE_OPTS doc - cmake --build "$BUILD_DIR" -- $MAKE_OPTS samples - cmake --build "$BUILD_DIR" -- $MAKE_OPTS package + cmake --build "$BUILD_DIR" -- $MAKE_OPTS tests samples doc package +else + cmake --build "$BUILD_DIR" -- $MAKE_OPTS tests fi exit 0